History log of /src/usr.bin/make/filemon/
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base netbsd-10-1-RELEASE perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base
1.6 15-Dec-2021 rillig

make: remove redundant comments for multiple-inclusion guards


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
1.5 19-Jan-2021 rillig

make(1): remove do-not-format markers from comments

These markers had been used inconsistently. Furthermore the source code
had not been formatted automatically before 2020 at all, otherwise there
wouldn't have been any trailing whitespace left.


1.4 29-Nov-2020 rillig

make(1): use space instead of tab for preprocessor directives


1.3 18-Oct-2020 rillig

make(1): use consistent include guard for headers


Revision tags: phil-wifi-20200421 phil-wifi-20200411 is-mlppp-base phil-wifi-20200406
1.2 22-Jan-2020 sjg

branches: 1.2.4;
Rename guard to avoid that already used by Linux filemon.h

Reviewed by: riastradh


1.1 19-Jan-2020 riastradh

Per sjg's suggestion, split filemon API into separate back ends.

By default we use the ktrace back end, but the /dev/filemon back end
is available as a compile-time option, by setting USE_FILEMON=dev in
make. sjg raised concerns about ktrace performance and would like to
continue using /dev/filemon on FreeBSD (which has seen more
maintenance kernel-side) without forking make.


Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base netbsd-10-1-RELEASE perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base
1.9 04-Mar-2022 sjg

Fix some unused warnings


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
1.8 01-Feb-2021 rillig

make: indent preprocessor directives consistently

As seen in share/misc/style.


1.7 19-Jan-2021 rillig

make(1): remove do-not-format markers from comments

These markers had been used inconsistently. Furthermore the source code
had not been formatted automatically before 2020 at all, otherwise there
wouldn't have been any trailing whitespace left.


1.6 29-Nov-2020 rillig

make(1): use space instead of tab for preprocessor directives


1.5 23-Nov-2020 rillig

make(1): use comparisons in boolean expressions

The generated code stays exactly the same.


1.4 05-Nov-2020 rillig

make(1): remove redundant parentheses from sizeof operator

The parentheses are only needed if the argument is a type, not an
expression.


1.3 10-Jul-2020 sjg

Use O_CLOEXEC and save a syscall.

Reviewed by: riastradh


1.2 10-Jul-2020 sjg

filemon_dev:filemon_open need FD_CLOEXEC

We need to mark the fd for filemon FD_CLOEXEC
so that when we call filemon_close() the device is
closed and unflushed data written to our temp file.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 is-mlppp-base phil-wifi-20200406
1.1 19-Jan-2020 riastradh

branches: 1.1.4;
Per sjg's suggestion, split filemon API into separate back ends.

By default we use the ktrace back end, but the /dev/filemon back end
is available as a compile-time option, by setting USE_FILEMON=dev in
make. sjg raised concerns about ktrace performance and would like to
continue using /dev/filemon on FreeBSD (which has seen more
maintenance kernel-side) without forking make.


Revision tags: perseant-exfatfs-base-20250801 netbsd-11-base netbsd-10-1-RELEASE perseant-exfatfs-base-20240630 perseant-exfatfs-base netbsd-10-0-RELEASE netbsd-10-0-RC6 netbsd-10-0-RC5 netbsd-10-0-RC4 netbsd-10-0-RC3 netbsd-10-0-RC2 netbsd-10-0-RC1 netbsd-10-base
1.15 31-Jul-2021 rillig

make: fix lint warnings

The string functions from str.h are declared as 'static __unused' when
compiled with GCC, but lint explicitly undefines __GCC__ during
preprocessing. Therefore, make those functions inline, to prevent
warnings that they are unused.

The macro UNCONST is used in a few places, and (again) since lint
undefines __GCC__, that macro expanded to a simple type cast, which lint
warned about. To prevent this warning, implement UNCONST as a function
that works everywhere and hides the type cast.

In filemon_open, the code for closing F->in was obviously unreachable.

No functional change.


Revision tags: cjep_sun2x-base1 cjep_sun2x-base cjep_staticlib_x-base1 cjep_staticlib_x-base
1.14 01-Feb-2021 rillig

make: document the syscalls that are not monitored by filemon_ktrace


1.13 19-Jan-2021 rillig

make(1): remove do-not-format markers from comments

These markers had been used inconsistently. Furthermore the source code
had not been formatted automatically before 2020 at all, otherwise there
wouldn't have been any trailing whitespace left.


1.12 10-Jan-2021 rillig

make(1): make a few more bool expressions more precise

The previous version of lint(1) from a few hours ago didn't catch all
occurrences. And even the current one doesn't catch everything.
Function arguments and return types still need some work. The "return
quietly" from shouldDieQuietly still implicitly converts from int to
_Bool.

No functional change.


1.11 10-Jan-2021 rillig

make(1): consistently use boolean expressions in conditions

Most of the make code already followed the style of explicitly writing
(ptr != NULL) instead of the shorter (ptr) in conditions.

The remaining 50 instances have been found by an experimental,
unpublished check in lint(1) that treats bool expressions as
incompatible to any other scalar type, just as in Java, C#, Pascal and
several other languages.

The only unsafe operation on Boolean that is left over is (flags &
FLAG), for an enum implementing a bit set. If Boolean is an ordinary
integer type (the default), some high bits may get lost. But if Boolean
is the same as _Bool (by compiling with -DUSE_C99_BOOLEAN), C99 6.3.1.2
defines that a conversion from any scalar to the type _Bool acts as a
comparison to 0, which cannot lose any bits.


1.10 09-Jan-2021 rillig

make(1): fix lint warnings


1.9 31-Dec-2020 rillig

make(1): replace pointers in controlling conditions with booleans


1.8 29-Nov-2020 rillig

make(1): use space instead of tab for preprocessor directives


1.7 28-Nov-2020 rillig

make(1): remove unused label


1.6 23-Nov-2020 rillig

make(1): use comparisons in boolean expressions

The generated code stays exactly the same.


1.5 23-Nov-2020 rillig

make(1): align end-of-line comments with tabs


1.4 05-Nov-2020 rillig

make(1): remove redundant parentheses from sizeof operator

The parentheses are only needed if the argument is a type, not an
expression.


1.3 18-Oct-2020 rillig

make(1): prepare for WARNS=6

The FD_* macros from sys/sys/fd_set.h use signed integers on NetBSD 8
and thus produce conversion errors. On NetBSD 9, these macros are fixed
to use 1U instead of 1.


Revision tags: phil-wifi-20200421 phil-wifi-20200411 is-mlppp-base phil-wifi-20200406
1.2 19-Jan-2020 riastradh

branches: 1.2.4;
Missed a spot -- define _KERNTYPES to get register_t.


1.1 19-Jan-2020 riastradh

Per sjg's suggestion, split filemon API into separate back ends.

By default we use the ktrace back end, but the /dev/filemon back end
is available as a compile-time option, by setting USE_FILEMON=dev in
make. sjg raised concerns about ktrace performance and would like to
continue using /dev/filemon on FreeBSD (which has seen more
maintenance kernel-side) without forking make.