358253 |
22-Feb-2020 |
kevans |
MFC r358109: kdump: decode SHM_ANON as first arg to legacy shm_open(2)
The first argument to shm_open(2) as well as shm_open2(2) may be a path or SHM_ANON. Decode SHM_ANON, at least- paths will show up as namei results in kdump output, which may be sufficient; in those cases, we'll have printed an address. |
339239 |
08-Oct-2018 |
jhb |
MFC 338021: Use 'bool' instead of 'int' for various boolean flags. |
339238 |
08-Oct-2018 |
jhb |
MFC 337400: Remove spurious ABI tags from kdump output.
The abidump routine output an ABI tag when -A was specified for records that were not displayed due to type or pid filtering. To fix, split the code to lookup the ABI from the code to display the ABI, move the code to display the ABI into dumpheader(), and move dumpheader() later in the main loop as a simplification. Previously dumpheader() was called under a condition that repeated conditions made later in the main loop. |
331722 |
29-Mar-2018 |
eadler |
Revert r330897:
This was intended to be a non-functional change. It wasn't. The commit message was thus wrong. In addition it broke arm, and merged crypto related code.
Revert with prejudice.
This revert skips files touched in r316370 since that commit was since MFCed. This revert also skips files that require $FreeBSD$ property changes.
Thank you to those who helped me get out of this mess including but not limited to gonzo, kevans, rgrimes.
Requested by: gjb (re) |
330897 |
14-Mar-2018 |
eadler |
Partial merge of the SPDX changes
These changes are incomplete but are making it difficult to determine what other changes can/should be merged.
No objections from: pfg |
328454 |
26-Jan-2018 |
jhb |
MFC 326184: Decode kevent structures logged via ktrace(2) in kdump.
- Add a new KTR_STRUCT_ARRAY ktrace record type which dumps an array of structures.
The structure name in the record payload is preceded by a size_t containing the size of the individual structures. Use this to replace the previous code that dumped the kevent arrays dumped for kevent(). kdump is now able to decode the kevent structures rather than dumping their contents via a hexdump.
One change from before is that the 'changes' and 'events' arrays are not marked with separate 'read' and 'write' annotations in kdump output. Instead, the first array is the 'changes' array, and the second array (only present if kevent doesn't fail with an error) is the 'events' array. For kevent(), empty arrays are denoted by an entry with an array containing zero entries rather than no record.
- Move kevent decoding tables from truss to libsysdecode.
This adds three new functions to decode members of struct kevent: sysdecode_kevent_filter, sysdecode_kevent_flags, and sysdecode_kevent_fflags.
kdump uses these helper functions to pretty-print kevent fields.
- Move structure definitions for freebsd11 and freebsd32 kevent structures to <sys/event.h> so that they can be shared with userland. The 32-bit structures are only exposed if _WANT_KEVENT32 is defined. The freebsd11 structures are only exposed if _WANT_FREEBSD11_KEVENT is defined. The 32-bit freebsd11 structure requires both.
- Decode freebsd11 kevent structures in truss for the compat11.kevent() system call.
- Log 32-bit kevent structures via ktrace for 32-bit compat kevent() system calls.
- While here, constify the 'void *data' argument to ktrstruct().
Note that this version of the change for 11.x does not include freebsd11 kevent structures or _WANT_FREEBSD11_KEVENT. It also does not include the change to decode the compat11.kevent system call in truss. |
326044 |
21-Nov-2017 |
jhb |
MFC 319493,319509,319520,319595,319677,319679-319681,319688,319689, 319761-319768,320010,322899,322959,323020,323021,323151:
Sync libsysdecode, kdump, and truss with head (aside from changes such as ino64 that are not applicable to 11).
319493: Decode the arguments passed to __cap_rights_get() and cap_rights_limit().
319509: Decode the argument passed to cap_getmode().
The returned integer value is output.
319520: Decode the 'who' argument passed to getrusage().
Add a new sysdecode_getrusage_who() which decodes the RUSAGE_* constant passed as the first argument to getrusage(). Use this function in both kdump and truss to decode the first argument to getrusage().
319595: Decode arguments to dup, dup2, getdirentries, pread, and pwrite.
- dup and dup2 print fd arguments in decimal. - pread and pwrite are similar to read and write with the addition of the file offset. - getdirentries displays the output entries as a string for now and also prints the value returned in *basep. Eventually the buffer for getdirentries should perhaps be decoded as an array of dirent structures.
319677: Decode arguments to ACL related system calls.
This only decodes the raw arguments but not the contents of the struct acl objects.
319679: Decode arguments passed to extended attribute related system calls.
The cmd argument passed to extattrctl() is not decoded as a string constant but is just printed in hex. The value is filesystem-specific but in practice is only used with UFS1 filesystems.
319680: Decode arguments to minherit().
319681: Decode arguments to mlock(), mlockall(), and munlock().
319688: Decode flags passed to mount(), nmount(), and unmount().
319689: Decode arguments passed to msync().
319761: Fix decoding of setpriority() arguments.
The PRIO_* 'which' value is stored in the first argument to setpriority(2), not the last. While here, decode the arguments to getpriority(2).
319762: Decode arguments to getpriority() and setpriority().
319763: Decode the arguments to ptrace().
This does not decode structures returned by ptrace().
319764: Decode the arguments to quotactl().
319765: Improve decoding of RB_AUTOBOOT in the 'howto' argument to reboot().
The reboot() system call accepts a mode (RB_AUTOBOOT, RB_HALT, RB_POWEROFF, or RB_REROOT) as well as zero or more optional flags in 'howto'. However, RB_AUTOBOOT was only displayed if 'howto' was exactly 0. Combinations like 'RB_AUTOBOOT | RB_DUMP' were decoded as 'RB_DUMP'. Instead, imply that RB_AUTOBOOT was specified if none of the other "mode" flags were specified.
319766: Decode the 'howto' argument to reboot().
319767: Decode arguments to rtprio_thread() (same as rtprio()).
319768: Decode arguments to rtprio() and rtprio_thread().
320010: Decode arguments to sched_* family of system calls.
This includes decoding both scheduler policy constants and the sched_param structure for sched_get_priority_max(), sched_get_priority_min(), sched_getparam(), sched_getscheduler(), sched_rr_get_interval(), sched_setparam(), and sched_setscheduler().
322899: Decode arguments passed to thr_set_name().
322959: Decode extra signal information for caught signals.
Decode fields from the siginfo_t stored in the PT_LWPINFO structure when a signal is caught by a traced process. This includes the signal code (si_code) as well as additional members such as si_addr, si_pid, etc.
323020: Trim stale prototype for ioctlname().
323021: Decode signal information returned by system calls.
Specifically, decode the siginfo structure returned by sigtimedwait(), sigwaitinfo(), and wait6(). While here, also decode the signal number returned in the second argument to sigwait().
323151: Decode pathconf() names, *at() flags, and sysarch() numbers in libsysdecode.
Move tables that were previously in truss over to libsysdecode. truss output is unchanged, but kdump has been updated to decode these fields. In addition, sysdecode_sysarch_number() should support all platforms whereas the old table in truss only supported x86.
PR: 214885, 215448 |
319186 |
30-May-2017 |
ngie |
MFC r315170: r315170 (by imp):
Adopt SRCTOP in usr.bin
Prefer ${SRCTOP}/foo over ${.CURDIR}/../../foo and ${SRCTOP}/usr.bin/foo over ${.CURDIR}/../foo for paths in Makefiles.
Silence on: arch@ (twice) |
318771 |
24-May-2017 |
jhb |
MFC 315334: Decode arguments to chflagsat(). |
312000 |
12-Jan-2017 |
jhb |
MFC 303946: Remove files unused after pulling system call names from libsysdecode. |
311999 |
12-Jan-2017 |
jhb |
MFC 307538,307948,308602,308603,311151: Move kdump's mksubr into libsysdecode.
307538: Move mksubr from kdump into libsysdecode.
Restructure this script so that it generates a header of tables instead of a source file. The tables are included in a flags.c source file which provides functions to decode various system call arguments.
For functions that decode an enumeration, the function returns a pointer to a string for known values and NULL for unknown values.
For functions that do more complex decoding (typically of a bitmask), the function accepts a pointer to a FILE object (open_memstream() can be used as a string builder) to which decoded values are written. If the function operates on a bitmask, the function returns true if any bits were decoded or false if the entire value was valid. Additionally, the third argument accepts a pointer to a value to which any undecoded bits are stored. This pointer can be NULL if the caller doesn't care about remaining bits.
Convert kdump over to using decoder functions from libsysdecode instead of mksubr. truss also uses decoders from libsysdecode instead of private lookup tables, though lookup tables for objects not decoded by kdump remain in truss for now. Eventually most of these tables should move into libsysdecode as the automated table generation approach from mksubr is less stale than the static tables in truss.
Some changes have been made to truss and kdump output: - The flags passed to open() are now properly decoded in that one of O_RDONLY, O_RDWR, O_WRONLY, or O_EXEC is always included in a decoded mask. - Optional arguments to open(), openat(), and fcntl() are only printed in kdump if they exist (e.g. the mode is only printed for open() if O_CREAT is set in the flags). - Print argument to F_GETLK/SETLK/SETLKW in kdump as a pointer, not int. - Include all procctl() commands. - Correctly decode pipe2() flags in truss by not assuming full open()-like flags with O_RDONLY, etc. - Decode file flags passed to *chflags() as file flags (UF_* and SF_*) rather than as a file mode. - Fix decoding of quotactl() commands by splitting out the two command components instead of assuming the raw command value matches the primary command component.
In addition, truss and kdump now build without triggering any warnings. All of the sysdecode manpages now include the required headers in the synopsis.
307948: Use binary and (&) instead of logical to extract the mask of a capability.
308602: Generate and use a proper .depend file for tables.h.
308603: Move libsysdecode-specific hack out of buildworld.
This should fix the lib32 build since it was not removing the generated ioctl.c. This file is generated by a find(1) call, so cannot use normal dependency tracking methods.
311151: Update libsysdecode for getfsstat() 'flags' argument changing to 'mode'.
As a followup to r310638, update libsysdecode (and kdump) to decode the 'mode' argument to getfsstat(). sysdecode_getfsstat_flags() has been renamed to sysdecode_getfsstat_mode() and now treats the argument as an enumerated value rather than a mask of flags. |
311839 |
09-Jan-2017 |
jhb |
MFC 306565,306566: Use timercmp() and timersub() in kdump.
306565: Use timercmp() and timersub() in kdump.
Previously, kdump used the kernel-only timervalsub() macro which required defining _KERNEL when including <sys/time.h>. Now, kdump uses the existing userland API. The timercmp() usage to check for a backwards timestamp is also clearer and simpler than the previous code which checked the result of the subtraction for a negative value.
While here, take advantage of the 3-arg timersub() to store the subtraction results in a tempory timeval instead of overwriting the timestamp in the ktrace record and then having to restore it.
306566: Don't declare the 'temp' timeval as static. |
311708 |
09-Jan-2017 |
jhb |
MFC 306564: Expose kernel-only errno values if _WANT_KERNEL_ERRNO is defined.
The kernel uses a few negative errno values for internal conditions such as requesting a system call restart. Normally these errno values are not exposed to userland. However, kdump needs access to these values as some of then can be present in a ktrace system call return record. Previously kdump was defining _KERNEL to gain access to ehse values, but was then having to manually declare 'errno' (and doing it incorrectly). Now, kdump uses _WANT_KERNEL_ERRNO instead of _KERNEL and uses the system-provided declaration of errno. |
311654 |
07-Jan-2017 |
jhb |
MFC 306563: Decode arguments to truncate and ftruncate.
In particular, decode the off_t argument as a 64-bit argument to fix decoding for 32-bit processes. |
311546 |
06-Jan-2017 |
jhb |
MFC 306562: Handle 64-bit system call arguments (off_t, id_t).
In particular, 64-bit system call arguments use up two register_t arguments for 32-bit processes. They must also be aligned on a 64-bit boundary on 32-bit powerpc processes. This fixes the decoding of lseek(), procctl(), and wait6() arguments for 32-bit processes (both native and via freebsd32).
Note that the ktrace system call return record only returns a single register, so the return value of lseek is always truncated to the low 32-bits for 32-bit processes. |
304449 |
19-Aug-2016 |
kib |
MFC r303990: Remove unused prototypes. |
303092 |
20-Jul-2016 |
kib |
MFC r302770: Trace timeval parameters to the getitimer(2) and setitimer(2) syscalls.
Approved by: re (gjb) |
302408 |
08-Jul-2016 |
gjb |
Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle. Prune svn:mergeinfo from the new branch, as nothing has been merged here.
Additional commits post-branch will follow.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
300428 |
22-May-2016 |
ngie |
Fix humanized decoding of struct stat with respect to .st_mtim
st_mtim was being incorrectly described as "stime=", not "mtime=". This was introduced with the original feature commit (r176471).
MFC after: 1 week PR: 209699 Submitted by: naddy Sponsored by: EMC / Isilon Storage Division
|
299998 |
17-May-2016 |
sjg |
Use != 0 to be clear
|
299995 |
17-May-2016 |
sjg |
Allow -f - to read from stdin.
|
299005 |
03-May-2016 |
bapt |
Print the fchmodat mode in human readable fashion
MFC after: 1 week
|
296570 |
09-Mar-2016 |
jhb |
Fix reporting of the CloudABI ABI in kdump.
- Advertise the word size for CloudABI ABIs via the SV_LP64 flag. All of the other ABIs include either SV_ILP32 or SV_LP64. - Fix kdump to not assume a 32-bit ABI if the ABI flags field is non-zero but SV_LP64 isn't set. Instead, only assume a 32-bit ABI if SV_ILP32 is set and fallback to the unknown value of "00" if neither SV_LP64 nor SV_ILP32 is set.
Reviewed by: kib, ed Differential Revision: https://reviews.freebsd.org/D5560
|
296127 |
26-Feb-2016 |
bdrewery |
Update dependencies.
Sponsored by: EMC / Isilon Storage Division
|
296047 |
25-Feb-2016 |
oshogbo |
Convert casperd(8) daemon to the libcasper. After calling the cap_init(3) function Casper will fork from it's original process, using pdfork(2). Forking from a process has a lot of advantages: 1. We have the same cwd as the original process. 2. The same uid, gid and groups. 3. The same MAC labels. 4. The same descriptor table. 5. The same routing table. 6. The same umask. 7. The same cpuset(1). From now services are also in form of libraries. We also removed libcapsicum at all and converts existing program using Casper to new architecture.
Discussed with: pjd, jonathan, ed, drysdale@google.com, emaste Partially reviewed by: drysdale@google.com, bdrewery Approved by: pjd (mentor) Differential Revision: https://reviews.freebsd.org/D4277
|
296042 |
25-Feb-2016 |
jhb |
Add simple support for CloudABI processes to kdump(1).
This does not decode arguments to system calls but should properly decode system call names and error return values.
Reviewed by: ed Differential Revision: https://reviews.freebsd.org/D5412
|
295989 |
24-Feb-2016 |
bdrewery |
DIRDEPS_BUILD: Regenerate without local dependencies.
These are no longer needed after the recent 'beforebuild: depend' changes and hooking DIRDEPS_BUILD into a subset of FAST_DEPEND which supports skipping 'make depend'.
Sponsored by: EMC / Isilon Storage Division
|
295931 |
23-Feb-2016 |
jhb |
Add handling for non-native error values to libsysdecode.
Add two new functions, sysdecode_abi_to_freebsd_errno() and sysdecode_freebsd_to_abi_errno(), which convert errno values between the native FreeBSD ABI and other supported ABIs. Note that the mappings are not necessarily perfect meaning in some cases multiple errors in one ABI might map to a single error in another ABI. In that case, the reverse mapping will return one of the errors that maps, but which error is non-deterministic.
Change truss to always report the raw error value to the user but use libsysdecode to map it to a native errno value that can be used with strerror() to generate a description. Previously truss reported the "converted" error value. Now the user will always see the exact error value that the application sees.
Change kdump to report the truly raw error value to the user. Previously kdump would report the absolute value of the raw error value (so for Linux binaries it didn't output the FreeBSD error value, but the positive value of the Linux error). Now it reports the real (i.e. negative) error value for Linux binaries. Also, use libsysdecode to convert the native FreeBSD error reported in the ktrace record to the raw error used by the ABI. This means that the Linux ABI can now be handled directly in ktrsysret() and removes the need for linux_ktrsysret().
Reviewed by: bdrewery, kib Helpful notes: wblock (manpage) Differential Revision: https://reviews.freebsd.org/D5314
|
295650 |
16-Feb-2016 |
bdrewery |
DIRDEPS_BUILD: Update dependencies.
Sponsored by: EMC / Isilon Storage Division
|
295056 |
30-Jan-2016 |
jhb |
Add a SYSDECODE_ABI_ prefix to the ABI enums to avoid potential collisions.
Suggested by: jmallett Reviewed by: bdrewery, jmallett Differential Revision: https://reviews.freebsd.org/D5123
|
294849 |
26-Jan-2016 |
jhb |
Add support to libsysdecode for decoding system call names.
A new sysdecode_syscallname() function accepts a system call code and returns a string of the corresponding name (or NULL if the code is unknown). To support different process ABIs, the new function accepts a value from a new sysdecode_abi enum as its first argument to select the ABI in use. Current ABIs supported include FREEBSD (native binaries), FREEBSD32, LINUX, LINUX32, and CLOUDABI64. Note that not all ABIs are supported by all platforms. In general, a given ABI is only supported if a platform can execute binaries for that ABI.
To simplify the implementation, libsysdecode's build reuses the existing pre-generated files from the kernel source tree rather than duplicating new copies of said files during the build.
kdump(1) and truss(1) now use these functions to map system call identifiers to names. For kdump(1), a new 'syscallname()' function consolidates duplicated code from ktrsyscall() and ktrsyscallret(). The Linux ABI no longer requires custom handling for ktrsyscall() and linux_ktrsyscall() has been removed as a result.
Reviewed by: bdrewery Differential Revision: https://reviews.freebsd.org/D4823
|
293345 |
07-Jan-2016 |
bdrewery |
DIRDEPS_BUILD: Update dependencies.
Sponsored by: EMC / Isilon Storage Division
|
292622 |
22-Dec-2015 |
jhb |
Move the mkioctls script to libsysdecode and use it to generate a sysdecode_ioctlname() function. This function matches the behavior of the truss variant in that it returns a pointer to a string description for known ioctls. The caller is responsible for displaying unknown ioctl requests. For kdump this meant moving the logic to handle unknown ioctl requests out of the generated function and into an ioctlname() function in kdump.c instead.
Differential Revision: https://reviews.freebsd.org/D4610
|
292236 |
15-Dec-2015 |
jhb |
Start on a new library (libsysdecode) that provides routines for decoding system call information such as system call arguments. Initially this will consist of pulling duplicated code out of truss and kdump though it may prove useful for other utilities in the future.
This commit moves the shared utrace(2) record parser out of kdump into the library and updates kdump and truss to use it. One difference from the previous version is that the library version treats unknown events that start with the "RTLD" signature as unknown events. This simplifies the interface and allows the consumer to decide how to handle all non-recognized events. Instead, this function only generates a string description for known malloc() and RTLD records.
Reviewed by: bdrewery Differential Revision: https://reviews.freebsd.org/D4537
|
291330 |
25-Nov-2015 |
bdrewery |
Replace DPSRCS that work fine in SRCS.
This is so that 'make depend' is not a required build step in these files.
DPSRCS is overall unneeded. DPSRCS already contains SRCS, so anything which can safely be in SRCS should be. DPSRCS is mostly just a way to generate files that should not be linked into the final PROG/LIB. For headers and grammars it is safe for them to be in SRCS since they will be excluded during linking and installation.
The only remaining uses of DPSRCS are for generating .c or .o files that must be built before 'make depend' can run 'mkdep' on the SRCS c files list. A semi-proper example is in tests/sys/kern/acct/Makefile where a checked-in .c file has an #include on a generated .c file. The generated .c file should not be linked into the final PROG though since it is #include'd. The more proper way here is just to build/link it in though without DPSRCS. Another example is in sys/modules/linux/Makefile where a shell script runs to parse a DPSRCS .o file that should not be linked into the module. Beyond those, the need for DPSRCS is largely unneeded, redundant, and forces 'make depend' to be ran. Generally, these Makefiles should avoid the need for DPSRCS and define proper dependencies for their files as well.
An example of an improper usage and why this matters is in usr.bin/netstat. nl_defs.h was only in DPSRCS and so was not generated during 'make all', but only during 'make depend'. The files including it lacked proper depenencies on it, which forced running 'make depend' to workaround that bug. The 'make depend' target should mostly be used for incremental build help, not to produce a working build. This specific example was broken in the meta build until r287905 since it does not run 'make depend'.
The gnu/lib/libreadline/readline case is fine since bsd.lib.mk has 'OBJS: SRCS:M*.h' when there is no .depend file.
Sponsored by: EMC / Isilon Storage Division MFC after: 1 week
|
288957 |
06-Oct-2015 |
bdrewery |
truss: Add support for utrace(2).
This uses the kdump(1) utrace support code directly until a common library is created.
This allows malloc(3) tracing with MALLOC_CONF=utrace:true and rtld tracing with LD_UTRACE=1. Unknown utrace(2) data is just printed as hex.
PR: 43819 [inspired by] Reviewed by: jhb MFC after: 2 weeks Relnotes: yes Differential Revision: https://reviews.freebsd.org/D3819
|
285063 |
02-Jul-2015 |
oshogbo |
Let the nv.h and dnv.h includes be only in sys directory.
Change consumers to include those files from sys. Add duplicated files to ObsoleteFiles.
Approved by: pjd (mentor)
|
284481 |
16-Jun-2015 |
sjg |
new depends
|
284407 |
15-Jun-2015 |
rodrigc |
Add ioctl.c, linux_syscalls.c, linux32_syscalls.c to beforedepend target.
These files need to be generated before mkdep is run.
|
284406 |
15-Jun-2015 |
rodrigc |
Use cpp -I$includedir
"cpp -I$1" was expanding to "cpp -Iprint" which was not the proper directory of header files.
|
284370 |
14-Jun-2015 |
sjg |
Create proper targets for linux*syscalls.c
|
284345 |
13-Jun-2015 |
sjg |
Add META_MODE support.
Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree.
Still need to add real targets under targets/ to build packages.
Differential Revision: D2796 Reviewed by: brooks imp
|
284289 |
11-Jun-2015 |
sjg |
Misc fixes from projects/bmake
Differential Revision: D2748 Reviewed by: brooks imp
|
284268 |
11-Jun-2015 |
sjg |
Use INCLUDEDIR rather than hard coded /usr/include
Differential Revision: D2748 Reviewed by: brooks imp
|
283430 |
24-May-2015 |
dchagin |
Teach kdump to understand both linux emulation.
Differential Revision: https://reviews.freebsd.org/D1079 Reviewed by: emaste
|
282436 |
04-May-2015 |
brooks |
Remove "capability mode sandbox enabled" messages.
These messages serve little purpose and break some consumers.
PR: 199855 Differential Revision: https://reviews.freebsd.org/D2440 Reviewed by: rwatson Approved by: pjd MFC after: 1 week Sponsored by: DARPA, AFRL
|
281970 |
25-Apr-2015 |
sobomax |
o Properly init prevtime, so that we don't print bogus value in the first entry reported by the relative mode (-R).
o Properly print negative offsets, which I guess may happen if records get re-ordered somehow, possibly due to the locking. Right now we report huge bogus diff (i.e. 2 seconds or so).
|
281143 |
06-Apr-2015 |
glebius |
Stop including if_var.h from userland.
Sponsored by: Nginx, Inc.
|
278857 |
16-Feb-2015 |
pluknet |
kdump: sendfile(2) "flags" argument needs casting on 64-bit platforms.
MFC after: 1 week Sponsored by: Nginx, Inc.
|
277695 |
25-Jan-2015 |
des |
Allow tracing dlfunc() / dlsym() events.
MFC after: 1 week
|
277610 |
23-Jan-2015 |
jilles |
Add futimens and utimensat system calls.
The core kernel part is patch file utimes.2008.4.diff from pluknet@FreeBSD.org. I updated the code for API changes, added the manual page and added compatibility code for old kernels. There is also audit and Capsicum support.
A new UTIME_* constant might allow setting birthtimes in future.
Differential Revision: https://reviews.freebsd.org/D1426 Submitted by: pluknet (partially) Reviewed by: delphij, pluknet, rwatson Relnotes: yes
|
276758 |
06-Jan-2015 |
dchagin |
kdump: eliminate new clang warnings.
MFC after: 1 week
|
275042 |
25-Nov-2014 |
bapt |
Convert to usr.bin/ to LIBADD Reduce overlinking
|
273053 |
13-Oct-2014 |
jhb |
Decode the arguments passed to _umtx_op(). In particular, decode the opcode.
MFC after: 1 week Sponsored by: Norse
|
273048 |
13-Oct-2014 |
jhb |
Fix most of the warnings in kdump(1).
Sponsored by: Norse
|
269408 |
01-Aug-2014 |
rpaulo |
Add kdump support for shm_open().
MFC after: 1 week
|
265420 |
06-May-2014 |
imp |
Use src.opts.mk in preference to bsd.own.mk except where we need stuff from the latter.
|
263879 |
28-Mar-2014 |
bdrewery |
Add `-S' to display syscall numbers in the output as well.
This is useful for debugging compat modules.
Sponsored by: EMC / Isilon Storage Division Obtained from: Isilon OneFS (based on work by Jeff Hughes) MFC after: 2 weeks
|
263756 |
25-Mar-2014 |
sobomax |
Make `-R', `-T' and `-E' options mutially non-exclusive. It is often useful to see two or three types at the same time when inspecting the dump.
MFC after: 1 month Sponsored by: Sippy Software, Inc.
|
263234 |
16-Mar-2014 |
rwatson |
Update most userspace consumers of capability.h to use capsicum.h instead.
auditdistd is not updated as I will make the change upstream and then do a vendor import sometime in the next week or two.
MFC after: 3 weeks
|
263152 |
14-Mar-2014 |
glebius |
Remove AppleTalk support.
AppleTalk was a network transport protocol for Apple Macintosh devices in 80s and then 90s. Starting with Mac OS X in 2000 the AppleTalk was a legacy protocol and primary networking protocol is TCP/IP. The last Mac OS X release to support AppleTalk happened in 2009. The same year routing equipment vendors (namely Cisco) end their support.
Thus, AppleTalk won't be supported in FreeBSD 11.0-RELEASE.
|
263140 |
14-Mar-2014 |
glebius |
Remove IPX support.
IPX was a network transport protocol in Novell's NetWare network operating system from late 80s and then 90s. The NetWare itself switched to TCP/IP as default transport in 1998. Later, in this century the Novell Open Enterprise Server became successor of Novell NetWare. The last release that claimed to still support IPX was OES 2 in 2007. Routing equipment vendors (e.g. Cisco) discontinued support for IPX in 2011.
Thus, IPX won't be supported in FreeBSD 11.0-RELEASE.
|
262405 |
23-Feb-2014 |
pjd |
Capability rights are held by descriptors, not processes.
Reported by: jonathan
|
261797 |
12-Feb-2014 |
glebius |
Fix world build WITHOUT_PF.
Sponsored by: Nginx, Inc.
|
259580 |
19-Dec-2013 |
pjd |
If we cannot connect to casperd we don't enter sandbox, but if we can connect to casperd, but we cannot access the service we need we exit with an error. This should not happen and just indicates some configuration error which should be fixed, so we force the user to do it by failing.
Discussed with: emaste
|
259440 |
15-Dec-2013 |
pjd |
Include bsd.own.mk for MK_CASPER to work.
Reported by: nwhitehorn
|
259434 |
15-Dec-2013 |
pjd |
Make use of Casper's system.pwd and system.grp services when the -r option is given to convert uids and gids to user names and group names even when running in capability mode sandbox.
While here log on stderr when we successfully enter the sandbox.
Sponsored by: The FreeBSD Foundation
|
256107 |
07-Oct-2013 |
des |
When displaying a struct stat, if the -r option was not specified, display the numeric rather than symbolic representation of st_mode.
Approved by: re (glebius) MFC after: 1 week
|
255708 |
19-Sep-2013 |
jhb |
Extend the support for exempting processes from being killed when swap is exhausted. - Add a new protect(1) command that can be used to set or revoke protection from arbitrary processes. Similar to ktrace it can apply a change to all existing descendants of a process as well as future descendants. - Add a new procctl(2) system call that provides a generic interface for control operations on processes (as opposed to the debugger-specific operations provided by ptrace(2)). procctl(2) uses a combination of idtype_t and an id to identify the set of processes on which to operate similar to wait6(). - Add a PROC_SPROTECT control operation to manage the protection status of a set of processes. MADV_PROTECT still works for backwards compatability. - Add a p_flag2 to struct proc (and a corresponding ki_flag2 to kinfo_proc) the first bit of which is used to track if P_PROTECT should be inherited by new child processes.
Reviewed by: kib, jilles (earlier version) Approved by: re (delphij) MFC after: 1 month
|
255493 |
12-Sep-2013 |
jhb |
- Decode the idtype argument passed to wait6() in kdump and truss. - Don't treat an options argument of 0 to wait4() as an error in kdump. - Decode the wait options passed to wait4() and wait6() in truss and decode the returned rusage and exit status.
Approved by: re (kib) MFC after: 1 week
|
255426 |
09-Sep-2013 |
jhb |
Add a mmap flag (MAP_32BIT) on 64-bit platforms to request that a mapping use an address in the first 2GB of the process's address space. This flag should have the same semantics as the same flag on Linux.
To facilitate this, add a new parameter to vm_map_find() that specifies an optional maximum virtual address. While here, fix several callers of vm_map_find() to use a VMFS_* constant for the findspace argument instead of TRUE and FALSE.
Reviewed by: alc Approved by: re (kib)
|
255219 |
05-Sep-2013 |
pjd |
Change the cap_rights_t type from uint64_t to a structure that we can extend in the future in a backward compatible (API and ABI) way.
The cap_rights_t represents capability rights. We used to use one bit to represent one right, but we are running out of spare bits. Currently the new structure provides place for 114 rights (so 50 more than the previous cap_rights_t), but it is possible to grow the structure to hold at least 285 rights, although we can make it even larger if 285 rights won't be enough.
The structure definition looks like this:
struct cap_rights { uint64_t cr_rights[CAP_RIGHTS_VERSION + 2]; };
The initial CAP_RIGHTS_VERSION is 0.
The top two bits in the first element of the cr_rights[] array contain total number of elements in the array - 2. This means if those two bits are equal to 0, we have 2 array elements.
The top two bits in all remaining array elements should be 0. The next five bits in all array elements contain array index. Only one bit is used and bit position in this five-bits range defines array index. This means there can be at most five array elements in the future.
To define new right the CAPRIGHT() macro must be used. The macro takes two arguments - an array index and a bit to set, eg.
#define CAP_PDKILL CAPRIGHT(1, 0x0000000000000800ULL)
We still support aliases that combine few rights, but the rights have to belong to the same array element, eg:
#define CAP_LOOKUP CAPRIGHT(0, 0x0000000000000400ULL) #define CAP_FCHMOD CAPRIGHT(0, 0x0000000000002000ULL)
#define CAP_FCHMODAT (CAP_FCHMOD | CAP_LOOKUP)
There is new API to manage the new cap_rights_t structure:
cap_rights_t *cap_rights_init(cap_rights_t *rights, ...); void cap_rights_set(cap_rights_t *rights, ...); void cap_rights_clear(cap_rights_t *rights, ...); bool cap_rights_is_set(const cap_rights_t *rights, ...);
bool cap_rights_is_valid(const cap_rights_t *rights); void cap_rights_merge(cap_rights_t *dst, const cap_rights_t *src); void cap_rights_remove(cap_rights_t *dst, const cap_rights_t *src); bool cap_rights_contains(const cap_rights_t *big, const cap_rights_t *little);
Capability rights to the cap_rights_init(), cap_rights_set(), cap_rights_clear() and cap_rights_is_set() functions are provided by separating them with commas, eg:
cap_rights_t rights;
cap_rights_init(&rights, CAP_READ, CAP_WRITE, CAP_FSTAT);
There is no need to terminate the list of rights, as those functions are actually macros that take care of the termination, eg:
#define cap_rights_set(rights, ...) \ __cap_rights_set((rights), __VA_ARGS__, 0ULL) void __cap_rights_set(cap_rights_t *rights, ...);
Thanks to using one bit as an array index we can assert in those functions that there are no two rights belonging to different array elements provided together. For example this is illegal and will be detected, because CAP_LOOKUP belongs to element 0 and CAP_PDKILL to element 1:
cap_rights_init(&rights, CAP_LOOKUP | CAP_PDKILL);
Providing several rights that belongs to the same array's element this way is correct, but is not advised. It should only be used for aliases definition.
This commit also breaks compatibility with some existing Capsicum system calls, but I see no other way to do that. This should be fine as Capsicum is still experimental and this change is not going to 9.x.
Sponsored by: The FreeBSD Foundation
|
254922 |
26-Aug-2013 |
jilles |
kdump: Decode SOCK_CLOEXEC and SOCK_NONBLOCK in socket() and socketpair().
|
254430 |
16-Aug-2013 |
jhb |
Add new mmap(2) flags to permit applications to request specific virtual address alignment of mappings. - MAP_ALIGNED(n) requests a mapping aligned on a boundary of (1 << n). Requests for n >= number of bits in a pointer or less than the size of a page fail with EINVAL. This matches the API provided by NetBSD. - MAP_ALIGNED_SUPER is a special case of MAP_ALIGNED. It can be used to optimize the chances of using large pages. By default it will align the mapping on a large page boundary (the system is free to choose any large page size to align to that seems best for the mapping request). However, if the object being mapped is already using large pages, then it will align the virtual mapping to match the existing large pages in the object instead. - Internally, VMFS_ALIGNED_SPACE is now renamed to VMFS_SUPER_SPACE, and VMFS_ALIGNED_SPACE(n) is repurposed for specifying a specific alignment. MAP_ALIGNED(n) maps to using VMFS_ALIGNED_SPACE(n), while MAP_ALIGNED_SUPER maps to VMFS_SUPER_SPACE. - mmap() of a device object now uses VMFS_OPTIMAL_SPACE rather than explicitly using VMFS_SUPER_SPACE. All device objects are forced to use a specific color on creation, so VMFS_OPTIMAL_SPACE is effectively equivalent.
Reviewed by: alc MFC after: 1 month
|
254296 |
13-Aug-2013 |
jilles |
kdump: Decode AT_FDCWD in first argument of bindat() and connectat().
|
254291 |
13-Aug-2013 |
jilles |
kdump: Improve decoding of various *at calls:
* Write AT_FDCWD where appropriate. * Decode the remaining arguments of openat() etc like open() etc.
|
253456 |
18-Jul-2013 |
pjd |
- Make localtime(3) to work in sandbox. - Move strerror(3) initialization to its own function.
|
252356 |
28-Jun-2013 |
davide |
- Trim an unused and bogus Makefile for mount_smbfs. - Reconnect with some minor modifications, in particular now selsocket() internals are adapted to use sbintime units after recent'ish calloutng switch.
|
251486 |
07-Jun-2013 |
ae |
Use getnameinfo(3) instead of inet_ntop(3) to make printable versions of sockaddr_in6 structures. getnameinfo(3) does the same thing, but it is also able to represent a scope zone id as described in the RFC 4007.
MFC after: 2 weeks
|
251167 |
30-May-2013 |
pjd |
If the -r option is given we cannot enter capability mode. The option tells kdump to convert numeric UIDs and GIDs into user and group names plus to convert times and dates into locallized versions. This all needs opening various files at various occasions.
|
251073 |
28-May-2013 |
pjd |
MFp4 @229086:
Make use of Capsicum to protect kdump(1), as it might be used to parse data from untrusted sources:
- Sandbox kdump(1) using capability mode. - Limit stdin descriptor (where opened file is moved to) to only CAP_READ and CAP_FSTAT rights. - Limit stdout descriptor to only CAP_WRITE, CAP_FSTAT and CAP_IOCTL. Plus limit allowed ioctls to TIOCGETA only, which is needed for isatty() to work. - Limit stderr descriptor to only CAP_WRITE and CAP_FSTAT. In addition if the -s option is not given, grant CAP_IOCTL right, but allow for TIOCGWINSZ ioctl only, as we need screen width to dump the data. - Before entering capability mode call catopen("libc", NL_CAT_LOCALE), which opens message catalogs and caches data, so that strerror(3) and strsignal(3) can work in a sandbox.
Sponsored by: The FreeBSD Foundation Discussed with: rwatson
|
251072 |
28-May-2013 |
pjd |
MFp4 @229085:
Rearrange the code so we don't call ioctl(TIOCGWINSZ) if the -s option is given, as the result won't be used then.
Sponsored by: The FreeBSD Foundation
|
247602 |
02-Mar-2013 |
pjd |
Merge Capsicum overhaul:
- Capability is no longer separate descriptor type. Now every descriptor has set of its own capability rights.
- The cap_new(2) system call is left, but it is no longer documented and should not be used in new code.
- The new syscall cap_rights_limit(2) should be used instead of cap_new(2), which limits capability rights of the given descriptor without creating a new one.
- The cap_getrights(2) syscall is renamed to cap_rights_get(2).
- If CAP_IOCTL capability right is present we can further reduce allowed ioctls list with the new cap_ioctls_limit(2) syscall. List of allowed ioctls can be retrived with cap_ioctls_get(2) syscall.
- If CAP_FCNTL capability right is present we can further reduce fcntls that can be used with the new cap_fcntls_limit(2) syscall and retrive them with cap_fcntls_get(2).
- To support ioctl and fcntl white-listing the filedesc structure was heavly modified.
- The audit subsystem, kdump and procstat tools were updated to recognize new syscalls.
- Capability rights were revised and eventhough I tried hard to provide backward API and ABI compatibility there are some incompatible changes that are described in detail below:
CAP_CREATE old behaviour: - Allow for openat(2)+O_CREAT. - Allow for linkat(2). - Allow for symlinkat(2). CAP_CREATE new behaviour: - Allow for openat(2)+O_CREAT.
Added CAP_LINKAT: - Allow for linkat(2). ABI: Reuses CAP_RMDIR bit. - Allow to be target for renameat(2).
Added CAP_SYMLINKAT: - Allow for symlinkat(2).
Removed CAP_DELETE. Old behaviour: - Allow for unlinkat(2) when removing non-directory object. - Allow to be source for renameat(2).
Removed CAP_RMDIR. Old behaviour: - Allow for unlinkat(2) when removing directory.
Added CAP_RENAMEAT: - Required for source directory for the renameat(2) syscall.
Added CAP_UNLINKAT (effectively it replaces CAP_DELETE and CAP_RMDIR): - Allow for unlinkat(2) on any object. - Required if target of renameat(2) exists and will be removed by this call.
Removed CAP_MAPEXEC.
CAP_MMAP old behaviour: - Allow for mmap(2) with any combination of PROT_NONE, PROT_READ and PROT_WRITE. CAP_MMAP new behaviour: - Allow for mmap(2)+PROT_NONE.
Added CAP_MMAP_R: - Allow for mmap(PROT_READ). Added CAP_MMAP_W: - Allow for mmap(PROT_WRITE). Added CAP_MMAP_X: - Allow for mmap(PROT_EXEC). Added CAP_MMAP_RW: - Allow for mmap(PROT_READ | PROT_WRITE). Added CAP_MMAP_RX: - Allow for mmap(PROT_READ | PROT_EXEC). Added CAP_MMAP_WX: - Allow for mmap(PROT_WRITE | PROT_EXEC). Added CAP_MMAP_RWX: - Allow for mmap(PROT_READ | PROT_WRITE | PROT_EXEC).
Renamed CAP_MKDIR to CAP_MKDIRAT. Renamed CAP_MKFIFO to CAP_MKFIFOAT. Renamed CAP_MKNODE to CAP_MKNODEAT.
CAP_READ old behaviour: - Allow pread(2). - Disallow read(2), readv(2) (if there is no CAP_SEEK). CAP_READ new behaviour: - Allow read(2), readv(2). - Disallow pread(2) (CAP_SEEK was also required).
CAP_WRITE old behaviour: - Allow pwrite(2). - Disallow write(2), writev(2) (if there is no CAP_SEEK). CAP_WRITE new behaviour: - Allow write(2), writev(2). - Disallow pwrite(2) (CAP_SEEK was also required).
Added convinient defines:
#define CAP_PREAD (CAP_SEEK | CAP_READ) #define CAP_PWRITE (CAP_SEEK | CAP_WRITE) #define CAP_MMAP_R (CAP_MMAP | CAP_SEEK | CAP_READ) #define CAP_MMAP_W (CAP_MMAP | CAP_SEEK | CAP_WRITE) #define CAP_MMAP_X (CAP_MMAP | CAP_SEEK | 0x0000000000000008ULL) #define CAP_MMAP_RW (CAP_MMAP_R | CAP_MMAP_W) #define CAP_MMAP_RX (CAP_MMAP_R | CAP_MMAP_X) #define CAP_MMAP_WX (CAP_MMAP_W | CAP_MMAP_X) #define CAP_MMAP_RWX (CAP_MMAP_R | CAP_MMAP_W | CAP_MMAP_X) #define CAP_RECV CAP_READ #define CAP_SEND CAP_WRITE
#define CAP_SOCK_CLIENT \ (CAP_CONNECT | CAP_GETPEERNAME | CAP_GETSOCKNAME | CAP_GETSOCKOPT | \ CAP_PEELOFF | CAP_RECV | CAP_SEND | CAP_SETSOCKOPT | CAP_SHUTDOWN) #define CAP_SOCK_SERVER \ (CAP_ACCEPT | CAP_BIND | CAP_GETPEERNAME | CAP_GETSOCKNAME | \ CAP_GETSOCKOPT | CAP_LISTEN | CAP_PEELOFF | CAP_RECV | CAP_SEND | \ CAP_SETSOCKOPT | CAP_SHUTDOWN)
Added defines for backward API compatibility:
#define CAP_MAPEXEC CAP_MMAP_X #define CAP_DELETE CAP_UNLINKAT #define CAP_MKDIR CAP_MKDIRAT #define CAP_RMDIR CAP_UNLINKAT #define CAP_MKFIFO CAP_MKFIFOAT #define CAP_MKNOD CAP_MKNODAT #define CAP_SOCK_ALL (CAP_SOCK_CLIENT | CAP_SOCK_SERVER)
Sponsored by: The FreeBSD Foundation Reviewed by: Christoph Mallon <christoph.mallon@gmx.de> Many aspects discussed with: rwatson, benl, jonathan ABI compatibility discussed with: kib
|
246720 |
12-Feb-2013 |
zont |
- Make actually printing path of AF_LOCAL socket types.
MFC after: 1 week
|
246719 |
12-Feb-2013 |
zont |
- Use correct size of copying different socket structures.
MFC after: 1 week
|
246711 |
12-Feb-2013 |
pluknet |
o Bring in sync decoding the first nfssvc(2) parameter (flags) with the current definitions location. o Respect numbers in NFSSVC_* (e.g. NFSSVC_V4ROOTEXPORT).
MFC after: 1 week
|
242482 |
02-Nov-2012 |
jilles |
kdump: Also decode fcntl commands containing underscores and digits.
The commands F_SETLK_REMOTE, F_DUPFD_CLOEXEC and F_DUP2FD_CLOEXEC were not decoded.
|
241680 |
18-Oct-2012 |
attilio |
Disconnect non-MPSAFE SMBFS from the build in preparation for dropping GIANT from VFS. In addition, disconnect also netsmb, which is a base requirement for SMBFS.
In the while SMBFS regular users can use FUSE interface and smbnetfs port to work with their SMBFS partitions.
Also, there are ongoing efforts by vendor to support in-kernel smbfs, so there are good chances that it will get relinked once properly locked.
This is not targeted for MFC.
|
240820 |
22-Sep-2012 |
jilles |
kdump: Pretty-print signal codes.
MFC after: 1 week
|
236577 |
04-Jun-2012 |
jhb |
Allow the -p argument to kdump to accept either a PID or a thread ID.
Submitted by: Dmitry Banschikov d.banschikov hostcomm ru MFC after: 1 week
|
235911 |
24-May-2012 |
mav |
MFprojects/zfsd: Revamp the CAM enclosure services driver. This updated driver uses an in-kernel daemon to track state changes and publishes physical path location information\for disk elements into the CAM device database.
Sponsored by: Spectra Logic Corporation Sponsored by: iXsystems, Inc. Submitted by: gibbs, will, mav
|
234494 |
20-Apr-2012 |
jhb |
Include the associated wait channel message for context switch ktrace records. kdump supports both the old and new messages.
Submitted by: Andrey Zonov andrey zonov org MFC after: 1 week
|
234058 |
09-Apr-2012 |
dim |
In kdump's mkioctls script, use '${CPP}' instead of hardcodedly using 'gcc -E'. This fixes building when WITH_CLANG_IS_CC is in effect.
Report by: Niclas Zeising <zeising@daemonic.se> MFC after: 1 week
|
233925 |
05-Apr-2012 |
jhb |
Add new ktrace records for the start and end of VM faults. This gives a pair of records similar to syscall entry and return that a user can use to determine how long page faults take. The new ktrace records are enabled via the 'p' trace type, and are enabled in the default set of trace points.
Reviewed by: kib MFC after: 2 weeks
|
232128 |
24-Feb-2012 |
jhb |
Fix style in previous commit.
Submitted by: bde
|
232072 |
23-Feb-2012 |
jhb |
Pretty-print the advice constants passed to posix_fadvise(2).
MFC after: 2 weeks
|
226608 |
21-Oct-2011 |
des |
It turns out that truss also used kdump's mkioctls script, and expected ioctlname() to return a pointer to the name rather than print it. This did not show up in testing because truss had its own prototype for ioctlname(), so it would build fine and run fine as long as the program being traced did not issue an ioctl.
Teach mkioctls to generate different versions of ioctlname() based on its first command-line argument.
Pointed out by: Garrett Cooper <yanegomi@gmail.com>
|
226505 |
18-Oct-2011 |
des |
Fix copy-pasto in CAPFAIL_INCREASE case.
Noticed by: pjd
|
226495 |
18-Oct-2011 |
des |
Revisit the capability failure trace points. The initial implementation only logged instances where an operation on a file descriptor required capabilities which the file descriptor did not have. By adding a type enum to struct ktr_cap_fail, we can catch other types of capability failures as well, such as disallowed system calls or attempts to wrap a file descriptor with more capabilities than it had to begin with.
|
226344 |
13-Oct-2011 |
des |
Clean up mkioctls a bit, and fix cross-building by checking ${MACHINE} instead of $(uname -m).
Pointed out by: nyan@
|
226329 |
12-Oct-2011 |
des |
Make kdump compile cleanly at WARNS level 6, with one exception: the ipfilter headers contain a duplicated function declaration. Turn off -Werror to allow kdump to compile in spite of this.
It would be neat to be able to turn off -Werror on a file-by-file basis...
PR: bin/161478 Submitted by: Garrett Cooper <yanegomi@gmail.com>
|
226269 |
11-Oct-2011 |
des |
Add a new trace point, KTRFAC_CAPFAIL, which traces capability check failures. It is included in the default set for ktrace(1) and kdump(1).
|
226262 |
11-Oct-2011 |
des |
The previous commit did not fix the issue since it did not prevent sign extension. Cast to u_register_t first, then to uintmax_t.
Submitted by: bde@
|
226246 |
11-Oct-2011 |
des |
Cast to unsigned for %#jx.
Noticed by: jh@
|
226164 |
08-Oct-2011 |
des |
Address some of bde@'s concerns with the new code.
|
226159 |
08-Oct-2011 |
des |
Teach kdump(1) to decode capability bitmasks.
MFC after: 3 weeks
|
226158 |
08-Oct-2011 |
des |
Fix the dependency issue properly by a) moving kdump_subr.c to the front of the SRCS list and b) listing kdump_subr.h in DPSRCS.
|
226157 |
08-Oct-2011 |
des |
Bring ioctlname() in line with all the other *name() functions, which actually print the name (or the numeric value, if they can't figure out the correct name) instead of just returning a pointer to it. Also, since ioctl numbers are not and probably never will be unique, drop support for using a switch statement instead of an if/else chain.
|
226153 |
08-Oct-2011 |
des |
I appreciate the logic behind using a (void) cast to indicate that the return value is intentionally ignored, but frankly, all it does is get in the way of the code.
Also fix a few other incorrect casts, such as (void *)malloc(foo) and passing signed values to %x.
|
226151 |
08-Oct-2011 |
des |
Fix casting.
|
226150 |
08-Oct-2011 |
des |
Whitespace.
|
226148 |
08-Oct-2011 |
des |
C has had swicth statements for 40 years or so. It's about time we started using them.
|
226147 |
08-Oct-2011 |
des |
Sort and line up.
|
226145 |
08-Oct-2011 |
des |
1) Some of the #defines or enums for which we auto-generate naming functions may be wider than int, so use intmax_t throughout. Also add missing casts in printf() calls.
2) Clean up some of the auto-generated code to improve readability.
3) Auto-generate kdump_subr.h. Note that this requires a semi-ugly hack in the Makefile to make sure it is generated before make(1) tries to build kdump.c, or preprocess it for 'make depend'.
MFC after: 3 weeks
|
223173 |
17-Jun-2011 |
netchild |
Add 2-clause BSD license.
Approved by: David Kirchner <dpk@dpk.net> (initial author) Requested by: Otto Moerbeek <otto@drijf.net> MFC after: 1 week
|
222768 |
06-Jun-2011 |
dchagin |
Fix regex for ptraceopname().
PR: bin/157663 Submitted by: jason wright <jason@thought.net> MFC after: 10 days
|
220756 |
17-Apr-2011 |
jilles |
kdump: Show code for signals where the default action was taken.
This information is available as of kernel r220740. Trace files from older kernels will always have 0.
MFC after: 1 week
|
219138 |
01-Mar-2011 |
dchagin |
Teach kdump to decode linux syscalls names too.
Fix bug introduced in my previous commit: the kernel always dump native signal numbers, so no need to check the ABI in ktrpsig().
Suggested by: jhb MFC after: 1 Month.
|
219044 |
25-Feb-2011 |
dchagin |
Update manual page to reflect latest changes of ABI description support.
MFC after: 1 Month.
|
219043 |
25-Feb-2011 |
dchagin |
Teach kdump to understand sv_flags records in the trace files.
MFC after: 1 Month.
|
216370 |
11-Dec-2010 |
joel |
Remove the advertising clause from UCB copyrighted files in usr.bin. This is in accordance with the information provided at ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change
Also add $FreeBSD$ to a few files to keep svn happy.
Discussed with: imp, rwatson
|
216130 |
02-Dec-2010 |
delphij |
Decode IPC_CREAT and IPC_EXCL for semget(2).
PR: bin/152781 Submitted by: Anton Yuzhaninov <citrin citrin ru> MFC after: 2 weeks
|
214625 |
01-Nov-2010 |
jhb |
Correct the abbreviations for general I/O and signal traces.
PR: docs/151854 Submitted by: Stephen Veiss stephen of brokenbottle net MFC after: 3 days
|
213479 |
06-Oct-2010 |
netchild |
Fix regex for some socket- and acl-related syscall values.
Submitted by: Mikhail <hidden.node@gmail.com> PR: 149295 MFC-after: 2 weeks
|
212728 |
16-Sep-2010 |
rpaulo |
Fix indenting of the previous commit.
|
212727 |
16-Sep-2010 |
rpaulo |
When generating functions to print the arguments of system calls with bitwise parameters (e.g. mmap), print the syscall parameter value first. The resulting output looks like the %b specifier of printf(9).
Before: mmap(0,0x8000,PROT_READ|PROT_WRITE,... After: mmap(0,0x8000,0x3<PROT_READ|PROT_WRITE>,...
Submitted by: Norberto Lopes <nlopes.ml at gmail.com> Idea from: freebsd-arch/2006-April/005116.html
|
205793 |
28-Mar-2010 |
ed |
Change all our own code to use st_*tim instead of st_*timespec.
Also remove some local patches to diff(1) which are now unneeded.
|
204045 |
18-Feb-2010 |
imp |
The kdump data stream is an unaligned data stream for stat and sockaddr structures. As such, we have top copy the data structure into a local buffer before we can reference it, otherwise we have unaligned references (these are fixed up automatically on some CPUs, but not on others). We do this unconditionally to make the code easier to read and understand.
Submitted by: Grzegorz Bernacki
|
203551 |
06-Feb-2010 |
jh |
- Cast intptr_t, pid_t and time_t values to intmax_t and use %jd with printf. - Cast the system call return value to long and use %ld in a printf in ktrsysret().
PR: bin/123774 MFC after: 2 weeks
|
201386 |
02-Jan-2010 |
ed |
Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
|
199265 |
14-Nov-2009 |
cperciva |
Update malloc utrace structure parsing to reflect the change (r199265) in how malloc_init is logged from (0, 0, 0) to (-1, 0, 0).
While we're here, simplify the logic.
Reviewed by: jhb (earlier version)
|
199024 |
07-Nov-2009 |
attilio |
Use a safety belt for cases where corrupted narg can be passed to the ktrsyscall(). print_number() does decrement the number of arguments, leading to infinite loops for negative values.
Reported by: Patrick Lamaiziere <patpr at davenulle dot org>, Jonathan Pascal <jkpyvxmzsa at mailinator dot com> Submitted by: jh PR: bin/120055, kern/119564 MFC: 1 week
|
195751 |
18-Jul-2009 |
bz |
Remove no longer needed #include after removing the legacy vimage API in r195741.
Reviewed by: rwatson Approved by: re (kib)
|
193177 |
31-May-2009 |
zec |
Unbreak buildworld.
(not waiting for an approval from mentor (julian) due to emergency)
|
192901 |
27-May-2009 |
thompsa |
Delete the old USB stack. The new stack has settled in and has all the drivers/functionality and then some.
|
192768 |
25-May-2009 |
ed |
Fix kdump build when building it by hand.
I don't entirely like this approach, but it will only be temporarily, namely until we get rid of COMPAT_43TTY. I do want <sys/ioctl_compat.h> to cause a compiler error when included, because it's just there for binary compatibility.
Reported by: Andrzej Tobola <ato iem pw edu pl>
|
191936 |
09-May-2009 |
ed |
Add support for old TTY ioctls to kdump.
At first I allowed ioctl_compat.h to be included, but it just returned an empty file. I had to do this, to keep kdump happy. I really want to raise a compiler error when including this header, so now it will just throw an error if you don't set COMPAT_43TTY.
|
190168 |
20-Mar-2009 |
delphij |
Add two missing include files and prototype for sockfamilyname() which is generated by mksubr.
|
189707 |
11-Mar-2009 |
jhb |
Add a new type of KTRACE record for sysctl(3) invocations. It uses the internal sysctl_sysctl_name() handler to map the MIB array to a string name and logs this name in the trace log. This can be useful to see exactly which sysctls a thread is invoking.
MFC after: 1 month
|
188978 |
24-Feb-2009 |
thompsa |
Install the old usb headers under /usr/include/legacy/dev/usb as they are needed by the hal port. This will be removed before 8.0.
Add an exclusion to kdump as some structs will be redefined.
Requested by: marcus
|
179308 |
25-May-2008 |
rwatson |
Remove netatm from HEAD as it is not MPSAFE and relies on the now removed NET_NEEDS_GIANT. netatm has been disconnected from the build for ten months in HEAD/RELENG_7. Specifics:
- netatm include files - netatm command line management tools - libatm - ATM parts in rescue and sysinstall - sample configuration files and documents - kernel support as a module or in NOTES - netgraph wrapper nodes for netatm - ctags data for netatm. - netatm-specific device drivers.
MFC after: 3 weeks Reviewed by: bz Discussed with: bms, bz, harti
|
177856 |
02-Apr-2008 |
ru |
Spell -t option's argument by name.
|
177097 |
12-Mar-2008 |
jeff |
- Remove ksethrcmdname.
|
176471 |
23-Feb-2008 |
des |
This patch adds a new ktrace(2) record type, KTR_STRUCT, whose payload consists of the null-terminated name and the contents of any structure you wish to record. A new ktrstruct() function constructs and emits a KTR_STRUCT record. It is accompanied by convenience macros for struct stat and struct sockaddr.
In kdump(1), KTR_STRUCT records are handled by a dispatcher function that runs stringent sanity checks on its contents before handing it over to individual decoding funtions for each type of structure. Currently supported structures are struct stat and struct sockaddr for the AF_INET, AF_INET6 and AF_UNIX families; support for AF_APPLETALK and AF_IPX is present but disabled, as I am unable to test it properly.
Since 's' was already taken, the letter 't' is used by ktrace(1) to enable KTR_STRUCT trace points, and in kdump(1) to enable their decoding.
Derived from patches by Andrew Li <andrew2.li@citi.com>.
PR: kern/117836 MFC after: 3 weeks
|
175980 |
05-Feb-2008 |
des |
Revert CLEANDEPFILES commit per ru@'s request; it does not really solve the problem. The correct fix will follow.
|
175937 |
03-Feb-2008 |
des |
Normally, when a header file is removed from the build (as i4b headers were recently), a simple 'make cleandepend; make depend' is sufficient to keep the tree buildable after a cvs update when doing incremental builds.
However, kdump and truss use a script which searches for header files that define ioctls, and generates C code that includes them. This script will usually not need updating when a header file is removed, so the normal dependency mechanism will not realize that it needs to be re-run. One is therefore left with code that references dead files but will only be removed by a full 'make clean', which defeats the purpose of incremental builds.
To work around this, modify the cleandepend target in bsd.dep.mk to also remove any files listed in a new variable named CLEANDEPFILES, and modify kdump's and truss's Makefiles accordingly.
MFC after: 2 weeks
|
175936 |
03-Feb-2008 |
des |
These are files are shell scripts; give smart editors a chance to figure it out by adding the usual shebang.
MFC after: 2 weeks
|
175138 |
07-Jan-2008 |
jhb |
Only use sockoptname() to parse socket option names for SOL_SOCKET requests.
MFC after: 3 days Reported by: Michiel Boland michiel boland.org
|
174346 |
06-Dec-2007 |
jhb |
Add several missing comma's in the fancy syscall parsing case before some arguments that are parsed (e.g., semctl command names).
MFC after: 3 days
|
171453 |
14-Jul-2007 |
rwatson |
Disconnect netatm from the build as it is not MPSAFE and relies on NET_NEEDS_GIANT, which will shortly be removed. This is done in a away that it may be easily reattached to the build before 7.1 if appropriate locking is added. Specifics:
- Don't install netatm include files - Disconnect netatm command line management tools - Don't build libatm - Don't include ATM parts in rescue or sysinstall - Don't install sample configuration files and documents - Don't build kernel support as a module or in NOTES - Don't build netgraph wrapper nodes for netatm
This removes the last remaining consumer of NET_NEEDS_GIANT.
Reviewed by: harti Discussed with: bz, bms Approved by: re (kensmith)
|
171333 |
10-Jul-2007 |
jhb |
Fix alignment of context switch traces.
MFC after: 1 week Approved by: re (rwatson: "I like simple patches.")
|
171221 |
04-Jul-2007 |
peter |
kdump has knowledge of lseek() and mmap() arg decoding. Teach it about the new mmap and lseek syscalls.
Approved by: re (kensmith)
|
168553 |
09-Apr-2007 |
emaste |
Add prototype for generated ptraceopname function.
|
168543 |
09-Apr-2007 |
emaste |
Remove static ptrace_ops array and extract ptrace op names from sys/ptrace.h with mksubr.
|
165916 |
09-Jan-2007 |
jhb |
Add various utrace's for use with ktrace to the ELF runtime linker. To activate the traces, set the LD_UTRACE (or LD_32_UTRACE) environment variable. This also includes code in kdump(8) to parse the traces.
Reviewed by: kan, jdp MFC after: 2 weeks
|
165812 |
05-Jan-2007 |
jhb |
Add code to parse the utrace(2) entries generated by malloc(3) in a more human-readable format. Note that we report 'realloc(p, 0)' as 'free(p)' since both cases are encoded the same way and 'free()' is more common than a realloc() to 0.
MFC after: 1 week
|
165758 |
04-Jan-2007 |
rodrigc |
Add sockipprotoname() function. Decode the third parameter (protocol) of a socket() call with sockipprotoname() if the first parameter (domain) is PF_INET or PF_INET6.
Old parsing behavior before this change: ping6 CALL socket(PF_INET6,SOCK_RAW,0x3a)
New behavior after this change: ping6 CALL socket(PF_INET6,SOCK_RAW,IPPROTO_ICMPV6)
|
165757 |
04-Jan-2007 |
rodrigc |
Generate sockdomainname() function with auto_if_type() instead of auto_or_type.
The old parsing code would incorrectly decode a socket() call in the ping6 program as: CALL socket(PF_PUP|PF_ECMA|PF_APPLETALK|PF_COIP|PF_SIP,SOCK_DGRAM,0)
The new parsing code decodes the same socket() call as: CALL socket(PF_INET6,SOCK_DGRAM,0)
|
165756 |
04-Jan-2007 |
rodrigc |
Add auto_if_type() function, which is similar to auto_switch_type(). However, auto_if_type() uses if/else statements in C instead of a single switch statement, when mapping an integer value to a #define. For certain cases where multiple #define constants alias to a single integer value, auto_if_type() makes things easier to parse than auto_switch_type().
|
165461 |
22-Dec-2006 |
rodrigc |
The second argument (type) to socket(2) is an enum, not a bitmask, so parse it as an enum.
If an SCTP SOCK_SEQPACKET socket was opened, kdump would display this wrong output: socket(PF_INET,SOCK_STREAM|SOCK_RDM|SOCK_SEQPACKET,0x84)
instead of this correct output: socket(PF_INET,SOCK_SEQPACKET,0x84)
MFC after: 2 weeks
|
162399 |
18-Sep-2006 |
maxim |
o optname, the third {set,get}sockopt(2) argument, is an enum, not a bitmap. Treat it accordingly.
PR: bin/101642 MFC after: 3 weeks
|
160296 |
12-Jul-2006 |
maxim |
o Fix some printf(3) format nits in my patch I submitted to kib@.
Submitted by: ru
|
160295 |
12-Jul-2006 |
kib |
Remove slipped in spaces.
Pointed out by: maxim Approved by: pjd (mentor)
|
160294 |
12-Jul-2006 |
kib |
Check that the signal number is in range.
Submitted by: maxim MFC after: 1 week Approved by: pjd (mentor)
|
160291 |
12-Jul-2006 |
kib |
Check that the signal number is in range.
Submitted by: Michiel Boland <michiel boland org> MFC after: 1 week Approved by: pjd (mentor)
|
159247 |
05-Jun-2006 |
rwatson |
Add audit.h to mkioctls inclusion list: audit pipe ioctls need access to the audit types.
Submitted by: wsalamon Obtained from: TrustedBSD Project
|
158766 |
20-May-2006 |
netchild |
Change kdump to print more useful information, i.e. it changes from 32229 telnet CALL mmap(0,0x8000,0x3,0x1002,0xffffffff,0,0,0) 32229 telnet CALL open(0x2807bc28,0,0x1b6) 32229 telnet CALL socket(0x2,0x2,0) to 32229 telnet CALL mmap(0,0x8000,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,0xffffffff,0,0,0) 32229 telnet CALL open(0x2807bc28,O_RDONLY,<unused>0x1b6) 32229 telnet CALL socket(PF_INET,SOCK_DGRAM,0)
David wanted to implement the suggestions which came up at the review from arch@ too, but real life rejected this proposal. So I commit what we already got and let another volunteer pick the remaining work from the ideas list.
Submitted by: "David Kirchner" <dpk@dpk.net> Suggested by: FreeBSD ideas list page Reviewed by: arch
|
152568 |
18-Nov-2005 |
ru |
-mdoc sweep.
|
152331 |
12-Nov-2005 |
rwatson |
Add "-s" argument to kdump to suppress the display of I/O data.
MFC after: 1 week
|
151930 |
01-Nov-2005 |
rwatson |
Add a "-H" argument to kdump, which causes kdump to print an additional field holding the threadid. This is more useful for libthr than libpthread, but still quite useful in libpthread as it can be used to process interlaced records from multiple threads over the course of a system call.
Detect old ktr_buffer values using the heuristic "if it's negative, then it must not be a valid threadid". This may leave something to be desired.
MFC after: 1 month Reviewed by: davidxu
|
140933 |
28-Jan-2005 |
gnn |
Update kdump manual page with information on the dump format. Add a table with the different types of operations traced.
Reviewed by: Ruslan Ermilov Approved by: Robert Watson (mentor)
|
135466 |
19-Sep-2004 |
ru |
Place a function prototype correctly.
Submitted by: Divacky Roman
|
130617 |
16-Jun-2004 |
mlaier |
Commit userland part of pf version 3.5 from OpenBSD (OPENBSD_3_5_BASE).
|
129405 |
18-May-2004 |
ru |
Bump document date on behalf of the -E option.
|
127402 |
25-Mar-2004 |
phk |
Respect decimal flag when dumping USER type records.
|
126244 |
25-Feb-2004 |
des |
Use the -H option instead of the deprecated -follow predicate.
|
123306 |
08-Dec-2003 |
peter |
First pass at attempted debrucification: - sort the -E switch into the right place. - add previously missing -p pid in usage (from the last few commits). - add -E to usage. - consistently use trfile in the man page.
I knew I shouldn't have touched the man page. If I commit to a man page, it just makes people suspicious. :-)
|
123187 |
07-Dec-2003 |
peter |
Add a -E (elapsed time) flag to kdump. This is like -T, except it is relative to start of the dump.
Approved by: re (scottl)
|
115759 |
03-Jun-2003 |
peter |
Two enhancements for kdump. 1) add a "-p pid", which is rather useful for selecting a single pid in a combined trace file (eg: with ktrace -i). 2) display binary genio data in a more precise format.
|
112203 |
13-Mar-2003 |
jhb |
Add a default case that just outputs a new line for the case of an unknown header type.
|
112201 |
13-Mar-2003 |
jhb |
Teach kdump(8) to handle events marked with KTR_DROP. If a record has KTR_DROP set in its header, then we output an extra line to stdout to indicate that events were dropped between the previous record and this record. It is a bit trickier because we need to always notify the user if events are dropped even if KTR_DROP is set on a record of a type that we aren't interested in since kdump(8) doesn't know if the dropped events were of the types that the user has requested. To avoid outputting multiple events dropped notices in between actual event logs, a state variable is set whenever a drop is logged and cleared whenever an actual record is output.
Requested by: phk
|
111922 |
05-Mar-2003 |
peter |
Kill references to netns in comment about how it conflicted with netipx so it was ignored all this time.
|
103393 |
16-Sep-2002 |
bde |
Backed out revs 1.32-1.33. The problem has been fixed better by depolluting <netinet/if_gre.h> in the !_KERNEL case.
Reviewed by: sobomax
|
103069 |
07-Sep-2002 |
sobomax |
Also add #include <netinet/in_systm.h> before <neinet/ip.h> to fix the world.
Submitted by: Brooks Davis <brooks@one-eyed-alien.net>
|
103063 |
07-Sep-2002 |
sobomax |
Add #include <netinet/ip.h> in attempt to fix the world.
|
100824 |
28-Jul-2002 |
dwmalone |
Improve WARNS situation for kdump:
1) Define _KERNEL while including sys/time.h to get some function prototypes. 2) Add prototypes and ANSIify definitions. 3) Constness changes. 4) Remove register keyword. 5) Actually return a sensible value from main. 6) Make fread_tail take a void * instead of a char *. 7) Avoid a signedness warning by casting to a size_t. Should be safe enough 'cos we also check for nonnegativity. 8) Be extra chummy with sigset_t rather than passing a struct to printf and pretending it is an int.
|
100559 |
23-Jul-2002 |
ru |
Dependencies are delimited by space not tab.
|
99112 |
30-Jun-2002 |
obrien |
Consistently use FBSDID
|
98767 |
24-Jun-2002 |
markm |
Better warnings fixes. Use more sane argument types instead of bogus casts
Submitted by: bde
|
98557 |
21-Jun-2002 |
markm |
Better fix for style.
Suggested by: ru (but modified a bit by markm)
|
98554 |
21-Jun-2002 |
markm |
Fix warnings generated elsewhere.
|
98553 |
21-Jun-2002 |
markm |
Style tidy-up.
|
94432 |
11-Apr-2002 |
ru |
I now don't seem to be able to reproduce the -DNOCLEAN buildworld breakage with ioctl.c. The .depend file should track dependencies just fine, and the worst we can have is to miss new ioctls.
But I still think it's a good idea to have -DNOCLEAN build produce the same ioctl.c as it would without -DNOCLEAN.
Prodded for a long time by: bde
|
93522 |
01-Apr-2002 |
dwmalone |
Const the code.
|
93160 |
25-Mar-2002 |
ru |
Back out revision 1.13 (addition of ipfilter includes). A proper fix for the relevant world breakage was later committed in revision 1.20, and this now breaks -DNO_IPFILTER world.
|
85796 |
01-Nov-2001 |
obrien |
Really fix this work to work. While rev 1.24 did allow awk to run w/o complaining; the resulting output was useless.
|
85794 |
01-Nov-2001 |
obrien |
Utilize the property of 'echo' in that it removes \n from its input.
|
79755 |
15-Jul-2001 |
dd |
Remove whitespace at EOL.
|
79535 |
10-Jul-2001 |
ru |
mdoc(7) police: removed HISTORY info from the .Os call.
|
77118 |
24-May-2001 |
ru |
Backout rev. 1.22 as the change that caused problems was also backed out.
|
76936 |
21-May-2001 |
ru |
Work around the side effect of src/include/Makefile,v 1.137 changes. (The proper fix is to add missing #include directives.)
|
75261 |
06-Apr-2001 |
ru |
Execute this script in a "C" locale environment.
Currently, cs_CZ.ISO_8859-2 locale's collation sequence is broken, and this caused grep(1) to skip some include files.
Reported by: Michal Mertl <mime@traveller.cz>
|
74864 |
27-Mar-2001 |
ru |
Traverse ${DESTDIR}/usr/include in lexographical order. This should fix problems reported recently on -current.
|
74840 |
27-Mar-2001 |
ken |
Rewrite of the CAM error recovery code.
Some of the major changes include:
- The SCSI error handling portion of cam_periph_error() has been broken out into a number of subfunctions to better modularize the code that handles the hierarchy of SCSI errors. As a result, the code is now much easier to read.
- String handling and error printing has been significantly revamped. We now use sbufs to do string formatting instead of using printfs (for the kernel) and snprintf/strncat (for userland) as before.
There is a new catchall error printing routine, cam_error_print() and its string-based counterpart, cam_error_string() that allow the kernel and userland applications to pass in a CCB and have errors printed out properly, whether or not they're SCSI errors. Among other things, this helped eliminate a fair amount of duplicate code in camcontrol.
We now print out more information than before, including the CAM status and SCSI status and the error recovery action taken to remedy the problem.
- sbufs are now available in userland, via libsbuf. This change was necessary since most of the error printing code is shared between libcam and the kernel.
- A new transfer settings interface is included in this checkin. This code is #ifdef'ed out, and is primarily intended to aid discussion with HBA driver authors on the final form the interface should take. There is example code in the ahc(4) driver that implements the HBA driver side of the new interface. The new transfer settings code won't be enabled until we're ready to switch all HBA drivers over to the new interface.
src/Makefile.inc1, lib/Makefile: Add libsbuf. It must be built before libcam, since libcam uses sbuf routines.
libcam/Makefile: libcam now depends on libsbuf.
libsbuf/Makefile: Add a makefile for libsbuf. This pulls in the sbuf sources from sys/kern.
bsd.libnames.mk: Add LIBSBUF.
camcontrol/Makefile: Add -lsbuf. Since camcontrol is statically linked, we can't depend on the dynamic linker to pull in libsbuf.
camcontrol.c: Use cam_error_print() instead of checking for CAM_SCSI_STATUS_ERROR on every failed CCB.
sbuf.9: Change the prototypes for sbuf_cat() and sbuf_cpy() so that the source string is now a const char *. This is more in line wth the standard system string functions, and helps eliminate warnings when dealing with a const source buffer.
Fix a typo.
cam.c: Add description strings for the various CAM error status values, as well as routines to look up those strings.
Add new cam_error_string() and cam_error_print() routines for userland and the kernel.
cam.h: Add a new CAM flag, CAM_RETRY_SELTO.
Add enumerated types for the various options available with cam_error_print() and cam_error_string().
cam_ccb.h: Add new transfer negotiation structures/types.
Change inq_len in the ccb_getdev structure to be "reserved". This field has never been filled in, and will be removed when we next bump the CAM version.
cam_debug.h: Fix typo.
cam_periph.c: Modularize cam_periph_error(). The SCSI error handling part of cam_periph_error() is now in camperiphscsistatuserror() and camperiphscsisenseerror().
In cam_periph_lock(), increase the reference count on the periph while we wait for our lock attempt to succeed so that the periph won't go away while we're sleeping.
cam_xpt.c: Add new transfer negotiation code. (ifdefed out)
Add a new function, xpt_path_string(). This is a string/sbuf analog to xpt_print_path().
scsi_all.c: Revamp string handing and error printing code. We now use sbufs for much of the string formatting code. More of that code is shared between userland the kernel.
scsi_all.h: Get rid of SS_TURSTART, it wasn't terribly useful in the first place.
Add a new error action, SS_REQSENSE. (Send a request sense and then retry the command.) This is useful when the controller hasn't performed autosense for some reason.
Change the default actions around a bit.
scsi_cd.c, scsi_da.c, scsi_pt.c, scsi_ses.c: SF_RETRY_SELTO -> CAM_RETRY_SELTO. Selection timeouts shouldn't be covered by a sense flag.
scsi_pass.[ch]: SF_RETRY_SELTO -> CAM_RETRY_SELTO.
Get rid of the last vestiges of a read/write interface.
libkern/bsearch.c, sys/libkern.h, conf/files: Add bsearch.c, which is needed for some of the new table lookup routines.
aic7xxx_freebsd.c: Define AHC_NEW_TRAN_SETTINGS if CAM_NEW_TRAN_CODE is defined.
sbuf.h, subr_sbuf.c: Add the appropriate #ifdefs so sbufs can compile and run in userland.
Change sbuf_printf() to use vsnprintf() instead of kvprintf(), which is only available in the kernel.
Change the source string for sbuf_cpy() and sbuf_cat() to be a const char *.
Add __BEGIN_DECLS and __END_DECLS around function prototypes since they're now exported to userland.
kdump/mkioctls: Include stdio.h before cam.h since cam.h now includes a function with a FILE * argument.
Submitted by: gibbs (mostly) Reviewed by: jdp, marcel (libsbuf makefile changes) Reviewed by: des (sbuf changes) Reviewed by: ken
|
65848 |
14-Sep-2000 |
jkh |
Fix ioctl.c creation to deal with the depend case more properly.
Submitted by: Ruslan Ermilov <ru@sunbay.com>
|
65829 |
14-Sep-2000 |
jkh |
remove .PHONY to avoid gratuitous rebuild of ioctl.c each time.
Approved by: sef
|
64121 |
02-Aug-2000 |
ru |
Unbreak world build by adding the necessary <net/ethernet.h> include.
Submitted by: Nickolay Dudorov <nnd@wint.itfs.nsk.su>
|
64102 |
01-Aug-2000 |
ru |
Make auto-generated ioctl.c to be always considered out of date since it could potentially depend on any ${DESTDIR}/usr/include preprocessor file. This fixes the broken -DNOCLEAN world build I experienced yesterday.
|
64099 |
01-Aug-2000 |
ru |
Fix an off-by-nine error when building a list of includes.
|
62585 |
04-Jul-2000 |
itojun |
more pre-requisite for new ipv6 ioctls
|
55206 |
29-Dec-1999 |
peter |
Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" is an application space macro and the applications are supposed to be free to use it as they please (but cannot). This is consistant with the other BSD's who made this change quite some time ago. More commits to come.
|
54335 |
08-Dec-1999 |
phk |
sys/dkbad.h is no more.
|
54081 |
03-Dec-1999 |
marcel |
Avoid hardcoding any paths and variables. The include directory must now be specified on the command line. Accept a '-s' option which controls whether a switch-statement is to be used instead of a series of if-statements.
Replace cpp with gcc -E.
Discussed with: bde
|
54029 |
02-Dec-1999 |
marcel |
Make sure DESTDIR is set in the environment of mkioctls. This fixes the breakage people have encountered at certain times (for example when the altq_*.h files were removed).
$FreeBSD$ tag added.
|
53669 |
24-Nov-1999 |
guido |
Unbreak build world by readding the necessary ipfilter includes.
|
53079 |
10-Nov-1999 |
dfr |
ioctlname() is actually passed a register_t.
Pointed out by: bde
|
53069 |
09-Nov-1999 |
dfr |
Fix a boatload of warnings in the generated code on the alpha.
|
52130 |
11-Oct-1999 |
peter |
Ack, ip_mroute.h is not an ipfilter include. :-/
Submitted by: Mike Heffner <spock@techfour.net>
|
52099 |
10-Oct-1999 |
peter |
Don't #include ipfilter includes that aren't there anymore.
|
51960 |
06-Oct-1999 |
n_hibma |
Remove the inclusion of device.h. It's no longer there.
|
50477 |
28-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
48852 |
17-Jul-1999 |
bde |
Decode new ptrace requests PT_GETDBREGS and PT_SETDBREGS.
|
48234 |
26-Jun-1999 |
bde |
Decode all currently supported values of the ptrace `request' arg.
|
47957 |
16-Jun-1999 |
dt |
Syscall arguments are now properly aligned. Print them, and syscall return values, as longs, instead of int.
|
47349 |
21-May-1999 |
jmz |
FIx the output of long command names.
PR: bin/10027 Submitted by: Arne Henrik Juul <arnej@math.ntnu.no>
|
46672 |
08-May-1999 |
phk |
we don't have <sys/disk.h> anymore.
|
40455 |
16-Oct-1998 |
bde |
Generate code to interpret ioctl numbers for all ioctls defined in headers under /usr/include, not just for the ones in <sys/ioctl.h>. The generated file includes all headers that seem to define ioctls, so build errors will probably occur if headers become less self- sufficient than they are already. This is a feature. Build errors shall not be fixed by adding more includes here.
Optionally generate a case statement instead of a list of if statements. This source must be edited to change this. The case statement should be non-optional. It currently can't be, because many ioctl numbers are not unique.
|
27443 |
16-Jul-1997 |
charnier |
Use err(3). Correct incomplete man page.
|
25995 |
22-May-1997 |
charnier |
Spelling correction (`1 bytes' is now printed `1 byte') PR: bin/3376 Submitted by: me
|
25189 |
27-Apr-1997 |
jmg |
``appears'' -> ``appeared'' (closes PR#3393, Submitted-by: Josh Gilliam)
add missing Id's other minor clean ups
|
24360 |
29-Mar-1997 |
imp |
compare return value from getopt against -1 rather than EOF, per the final posix standard on the topic.
|
20287 |
10-Dec-1996 |
wollman |
Fix up programs which expect <net/if.h> to include <sys/time.h> to instead do it themselves. (Some of these programs actually depended on this beyond compiling the definition of struct ifinfo!) Also fix up some other #include messes while we're at it.
|
19853 |
18-Nov-1996 |
fenner |
Fix arg parsing. kdump used to allow a single argument, which it silently ignored.
|
18470 |
22-Sep-1996 |
phk |
Remove length field from utrace entries.
|
18400 |
19-Sep-1996 |
phk |
For now we just hexdump the stuff in USER records.
|
16631 |
23-Jun-1996 |
bde |
Run the headers through cpp -dM to find the #defines. The direct search has been broken at least since 4.4Lite moved most of the #defines out of <sys/ioctl.h>. This should be done better. Only a few headers are searched.
Added some #includes so that ioctl.c compiles. The networking headers have a maze of undocumented interdependencies and ioctl.c now actually supports networking ioctls.
|
14541 |
11-Mar-1996 |
dg |
Include queue.h in preparation for upcoming struct socket changes.
|
11823 |
26-Oct-1995 |
ache |
Add setlocale LC_CTYPE
|
8874 |
30-May-1995 |
rgrimes |
Remove trailing whitespace.
|
4722 |
21-Nov-1994 |
phk |
-I${.CURDIR}/../..
|
4721 |
21-Nov-1994 |
phk |
Absolute path to /sys again...
|
2782 |
15-Sep-1994 |
swallace |
Added $DESTDIR to $DESTDIR/usr/include/sys/ioctl.h $DESTDIR/usr/include/sys/ioctl_compat.h so ioctl.c is generated properly using 2.0 include files in $DESTDIR.
|
2215 |
22-Aug-1994 |
csgr |
move #include of <sys/errno.h> so that #defining KERNEL actually has an effect, and then also add a declaration of ernno as an extern int, because we lose that due to having KERNEL defined while we include errno.h. Reviewed by: Geoff.
|
1591 |
27-May-1994 |
rgrimes |
This commit was generated by cvs2svn to compensate for changes in r1590, which included commits to RCS files with non-trunk default branches.
|