Page MenuHomeFreeBSD

Move ioctl decoding to libsysdecode.
ClosedPublic

Authored by jhb on Dec 18 2015, 5:54 AM.
Tags
None
Referenced Files
Unknown Object (File)
Nov 30 2023, 5:54 PM
Unknown Object (File)
Oct 19 2023, 11:00 PM
Unknown Object (File)
Oct 19 2023, 5:50 PM
Unknown Object (File)
Sep 30 2023, 4:15 AM
Unknown Object (File)
Jul 6 2023, 2:17 PM
Unknown Object (File)
Jul 4 2023, 4:32 AM
Unknown Object (File)
Jul 4 2023, 4:32 AM
Unknown Object (File)
Jul 4 2023, 4:30 AM
Subscribers

Details

Summary

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.

Test Plan
  • Compared truss and kdump output before/after of a /bin/ls run.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jhb retitled this revision from to Move ioctl decoding to libsysdecode..
jhb updated this object.
jhb edited the test plan for this revision. (Show Details)
jhb added a reviewer: bdrewery.
lib/libsysdecode/Makefile
26 ↗(On Diff #11408)

Note that the ${.TARGET} route didn't actually work well here as I would have needed to define separate variables for ioctl.o, ioctl.So and ioctl.po. Using ${.IMPSRC} let me only define a single variable.

lib/libsysdecode/sysdecode_ioctlname.3
28 ↗(On Diff #11408)

git is just confused here, this is a new file, not copied from sysdecode.3.

This revision was automatically updated to reflect the committed changes.