#
fdafd315 |
| 24-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remov
sys: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
show more ...
|
Revision tags: release/14.0.0 |
|
#
685dc743 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
#
4d846d26 |
| 10-May-2023 |
Warner Losh <imp@FreeBSD.org> |
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause.
Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
show more ...
|
Revision tags: release/13.2.0, release/12.4.0, release/13.1.0 |
|
#
b84ed4e7 |
| 03-Feb-2022 |
Mark Johnston <markj@FreeBSD.org> |
filemon: Reject FILEMON_SET_FD commands when the fd is a kqueue
When FILEMON_SET_FD is used, the filemon handle effectively wraps the passed file. In particular, the handle may be inherited by a ch
filemon: Reject FILEMON_SET_FD commands when the fd is a kqueue
When FILEMON_SET_FD is used, the filemon handle effectively wraps the passed file. In particular, the handle may be inherited by a child process, or transferred over a unix domain socket, so we must verify that the backing file permits this.
Reported by: syzbot+36e6be9e02735fe66ca8@syzkaller.appspotmail.com Reviewed by: emaste MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D34128
show more ...
|
Revision tags: release/12.3.0, release/13.0.0, release/12.2.0, release/11.4.0, release/12.1.0, release/11.3.0, release/12.0.0 |
|
#
14b841d4 |
| 11-Aug-2018 |
Kyle Evans <kevans@FreeBSD.org> |
MFH @ r337607, in preparation for boarding
|
#
bbd7a929 |
| 04-Aug-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r336870 through r337285, and resolve conflicts.
|
#
bc0d7285 |
| 03-Aug-2018 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Fix some filemon path logging issues.
- Properly handle snprintf return value for truncation and avoid overflowing the later write with the bogus length. - Increase the msgbufr size to handle a re
Fix some filemon path logging issues.
- Properly handle snprintf return value for truncation and avoid overflowing the later write with the bogus length. - Increase the msgbufr size to handle a rename of 2 full files.
The larger allocation causes a slight performance hit which will be mitigated in the future. A rewrite with sbufs will likely be done as well.
Reported by: Ilja Van Sprundel <ivansprundel@ioactive.com> MFC after: 2 weeks Approved by: so (gtetlow) Reviewed by: kib Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D16098
show more ...
|
Revision tags: release/11.2.0 |
|
#
cbd92ce6 |
| 09-May-2018 |
Matt Macy <mmacy@FreeBSD.org> |
Eliminate the overhead of gratuitous repeated reinitialization of cap_rights
- Add macros to allow preinitialization of cap_rights_t.
- Convert most commonly used code paths to use preinitialized c
Eliminate the overhead of gratuitous repeated reinitialization of cap_rights
- Add macros to allow preinitialization of cap_rights_t.
- Convert most commonly used code paths to use preinitialized cap_rights_t. A 3.6% speedup in fstat was measured with this change.
Reported by: mjg Reviewed by: oshogbo Approved by: sbruno MFC after: 1 month
show more ...
|
#
6469bdcd |
| 06-Apr-2018 |
Brooks Davis <brooks@FreeBSD.org> |
Move most of the contents of opt_compat.h to opt_global.h.
opt_compat.h is mentioned in nearly 180 files. In-progress network driver compabibility improvements may add over 100 more so this is close
Move most of the contents of opt_compat.h to opt_global.h.
opt_compat.h is mentioned in nearly 180 files. In-progress network driver compabibility improvements may add over 100 more so this is closer to "just about everywhere" than "only some files" per the guidance in sys/conf/options.
Keep COMPAT_LINUX32 in opt_compat.h as it is confined to a subset of sys/compat/linux/*.c. A fake _COMPAT_LINUX option ensure opt_compat.h is created on all architectures.
Move COMPAT_LINUXKPI to opt_dontuse.h as it is only used to control the set of compiled files.
Reviewed by: kib, cem, jhb, jtl Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D14941
show more ...
|
#
718cf2cc |
| 27-Nov-2017 |
Pedro F. Giffuni <pfg@FreeBSD.org> |
sys/dev: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error
sys/dev: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task.
The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts.
show more ...
|
Revision tags: release/10.4.0, release/11.1.0, release/11.0.1, release/11.0.0 |
|
#
27067774 |
| 16-Aug-2016 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r303250 through r304235.
|
#
569e9018 |
| 13-Aug-2016 |
Enji Cooper <ngie@FreeBSD.org> |
MFhead @ r304038
|
#
f566b25e |
| 12-Aug-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Avoid taking PROC_LOCK in syscalls if not being traced.
MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
|
#
6c37a3d4 |
| 05-Jun-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Cleanup COMPAT_FREEBSD32 support.
This is a NOP.
The COMPAT_IA32 was renamed in r205014 to COMPAT_FREEBSD32 and COMPAT_ARCH32 does not seem to have existed. Also remove some leftovers from the sys
Cleanup COMPAT_FREEBSD32 support.
This is a NOP.
The COMPAT_IA32 was renamed in r205014 to COMPAT_FREEBSD32 and COMPAT_ARCH32 does not seem to have existed. Also remove some leftovers from the sysent rework in r301404. Include freebsd32_util.h for the freebsd32_sysent prototype.
X-MFC-With: r301404 Reported by: kib MFC after: 3 days Sponsored by: EMC / Isilon Storage Division
show more ...
|
#
33094a87 |
| 28-May-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Rename function to be less generic.
MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
|
#
f14fbe72 |
| 28-May-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
exec: Cease tracing if credentials will change with the new image.
This also prevents tracing to a P_INEXEC process since it could race with other processes attaching to it in filemon_event_process_
exec: Cease tracing if credentials will change with the new image.
This also prevents tracing to a P_INEXEC process since it could race with other processes attaching to it in filemon_event_process_exec() due to the filemon_get_proc() race of incrementing ref and then locking the filemon. With the no-P_INEXEC invariant in place the p_filemon may only be the same or NULL when trying to drop it in filemon_event_process_exec().
MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D6545
show more ...
|
#
d6084013 |
| 05-Apr-2016 |
Glen Barber <gjb@FreeBSD.org> |
MFH
Sponsored by: The FreeBSD Foundation
|
Revision tags: release/10.3.0 |
|
#
37338975 |
| 25-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Remove unneeded return left from refactoring.
MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
|
#
4177d9f7 |
| 22-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Return any log write failure encountered when closing the filemon fd.
Discussed with: sjg, markj Reviewed by: sjg MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
|
#
4d9fbc55 |
| 22-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Follow-up r297156: Close the log in filemon_dtr rather than in the last reference.
If the tracer has decided to the close the log then it should be fully written, not getting more entries, when clos
Follow-up r297156: Close the log in filemon_dtr rather than in the last reference.
If the tracer has decided to the close the log then it should be fully written, not getting more entries, when close(2) returns. This was a regression in r297156 in that it allowed a traced process to continue a traced syscall and add more entries to the log while the tracer had already closed its fd or exited. This was only really part of the daemonized process case which is abnormal.
MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
show more ...
|
#
e0d84b9e |
| 21-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Track filemon usage via a proc.p_filemon pointer rather than its own lists.
- proc.p_filemon is added which is protected by PROC_LOCK. This improves performance and avoids double-fork issues, tak
Track filemon usage via a proc.p_filemon pointer rather than its own lists.
- proc.p_filemon is added which is protected by PROC_LOCK. This improves performance and avoids double-fork issues, taking allproc_lock while in syscalls, and walking the process tree in syscalls. A particular proc.p_filemon can only be changed to NULL or another filemon, or the filemon inherited, while the filemon->lock is held. - Filemon are reference counted. On the last reference the log will be closed. - When closing the devfs file handle, the filemon will be detached from all processes and inheritance prevented. - Disallow attaching to a process already being traced since filemon is typically intended to be used on children only. This is allowed for curproc as bmake relies on this behavior for rare cases when combining .MAKE with .META. - Detach any previously tracked process on ioctl(FILEMON_SET_PID). - Handle error from devfs_set_cdevpriv() in filemon_open(). - The global filemon lock and lists are removed. - A free list is no longer kept. Previously this list was forever-expanding and never garbage cleaned. - No longer loses track of double-forks. If the process holding the filemon handle closes it will close the log rather than wait on a daemonized process, but it will log all activity until it closes its handle. The filemon will be removed from the process and not inherited. - A separate process count is kept only as an optimization for forced detachment to avoid taking allproc_lock and walking the entire process tree. - struct filemon access is protected by sx(9) filemon->lock as it was before. - Add more comments and KASSERTS.
MFC after: 2 weeks Reviewed by: kib, mjg, markj (all on previous versions) Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D5520
show more ...
|
#
7d536dc8 |
| 10-Mar-2016 |
Glen Barber <gjb@FreeBSD.org> |
MFH
Sponsored by: The FreeBSD Foundation
|
#
044fd543 |
| 09-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
FILEMON_SET_FD: Disallow changing the fd.
MFC after: 1 week Suggested by: mjg Sponsored by: EMC / Isilon Storage Division
|
#
1e35cdf6 |
| 07-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Add missing break for r296472.
This was lost in git rebasing, though it has no functional change.
X-MFC-With: r296472 MFC after: 1 week
|
#
4039c531 |
| 07-Mar-2016 |
Bryan Drewery <bdrewery@FreeBSD.org> |
Require kldunload -f to unload.
Code may still be executing from the wrappers at unload time and thus is not generally safe to unload. Converting the wrappers to use EVENTHANDLER(9) will allow this
Require kldunload -f to unload.
Code may still be executing from the wrappers at unload time and thus is not generally safe to unload. Converting the wrappers to use EVENTHANDLER(9) will allow this to safely drain on active threads in hooks. More work on EVENTHANDLER(9) is needed first.
MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
show more ...
|