Re: XNU syscall numbers
- In reply to: mothcompute : "XNU syscall numbers"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 21 May 2025 20:59:57 UTC
On Wed, May 21, 2025 at 05:02:25PM +0000, mothcompute wrote: > I've been looking into writing a module for FreeBSD that adds a sysentvec for XNU syscalls, but XNU syscall numbers contain two fields so syscall numbers can be as many as 26 bits long. Does FreeBSD have some mechanism to 'fix' the syscall number before dispatching it to a sysent, and if not, what would be the best way to go about implementing this without slowing down existing ABIs? > You'll need to make the entries in syscalls.master compact as that generates arrays like sysent, but you could likely implement a transform between the real numbers and the compact set in your sv_fetch_syscall_args function. That's where we handle syscall(2), etc. -- Brooks