Page MenuHomeFreeBSD

Move syscall_args into struct thread.
ClosedPublic

Authored by kib on Jun 6 2017, 11:39 PM.
Tags
None
Referenced Files
F122495836: D11080.id29291.diff
Sat, Jul 5, 6:58 PM
Unknown Object (File)
Tue, Jul 1, 10:18 AM
Unknown Object (File)
Tue, Jul 1, 3:20 AM
Unknown Object (File)
Mon, Jun 30, 5:30 AM
Unknown Object (File)
Sun, Jun 29, 3:19 PM
Unknown Object (File)
Fri, Jun 27, 6:21 AM
Unknown Object (File)
Mon, Jun 23, 8:15 AM
Unknown Object (File)
Sat, Jun 21, 4:32 AM
Subscribers

Details

Summary

This allows to remove td_dbg_sc_code and td_dbg_sc_nargs.
Also, it allows to optionally print the syscall number in nosys().
Also, add PT_GET_SC_ARGS argument fetch operation for ptrace(2).

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

Right now this is only compiled on i386/amd64. PT_GET_SC_ARGS is not tested and not documented.

Handle compat32: simply copy out low 32bits from each arg. This should be, in fact, a correct truncation.

Document PT_GET_SC_ARGS.

Looks good to me. For full truss cleanup I'll also eventually want a PT_GET_SC_RVAL that returns td_retval[] and the translated error value from the system call (though I could also accept the "raw" error and do the translation in userland via the tables in libsysdecode). That one is easy enough I can add when adopting truss to use this.

This revision is now accepted and ready to land.Jun 12 2017, 5:29 PM
kib edited edge metadata.

Update patch to the current state, including fixes to PT_GET_SC_ARGS (it passes tests) and to scescx.c test itself.

This revision now requires review to proceed.Jun 12 2017, 8:37 PM
This revision was automatically updated to reflect the committed changes.