Page MenuHomeFreeBSD
Feed Advanced Search

Sep 25 2023

dchagin abandoned D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.

Due to D41976

Sep 25 2023, 5:50 PM · Linux Emulation

Sep 21 2023

dchagin added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
In D41859#955406, @kib wrote:
In D41859#955376, @kib wrote:

Btw, the way you proposed will not work, due to nosys marked as ABSENT and in such cases syscall_thread_enter() return ENOSYS.

Are you saying that sometimes we do not send SIGSYS for FreeBSD native processes?

yes, OBSOL syscalls, https://people.freebsd.org/~dchagin/nosys.c

And ABSENT as well?

Sep 21 2023, 12:14 PM · Linux Emulation

Sep 20 2023

kib added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
In D41859#955376, @kib wrote:

Btw, the way you proposed will not work, due to nosys marked as ABSENT and in such cases syscall_thread_enter() return ENOSYS.

Are you saying that sometimes we do not send SIGSYS for FreeBSD native processes?

yes, OBSOL syscalls, https://people.freebsd.org/~dchagin/nosys.c

And ABSENT as well?

Sep 20 2023, 9:30 AM · Linux Emulation
dchagin added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
In D41859#955376, @kib wrote:

Btw, the way you proposed will not work, due to nosys marked as ABSENT and in such cases syscall_thread_enter() return ENOSYS.

Are you saying that sometimes we do not send SIGSYS for FreeBSD native processes?

Sep 20 2023, 9:08 AM · Linux Emulation
kib added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.

Btw, the way you proposed will not work, due to nosys marked as ABSENT and in such cases syscall_thread_enter() return ENOSYS.

Are you saying that sometimes we do not send SIGSYS for FreeBSD native processes?

Sep 20 2023, 4:00 AM · Linux Emulation

Sep 19 2023

dchagin added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
In D41859#955044, @kib wrote:

D41901 sounds as a hack, again.

Am I right that the issue is that nosys() sends signal, while Linux' nosys should not? If yes, there are two options:

yes

Sep 19 2023, 10:45 PM · Linux Emulation

Sep 18 2023

kib added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.

D41901 sounds as a hack, again.

Sep 18 2023, 3:21 PM · Linux Emulation
dchagin added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
In D41859#954114, @kib wrote:

Can you explain more? Does linuxolator need syscall slot 0?

Sep 18 2023, 3:00 PM · Linux Emulation

Sep 14 2023

kib added a comment to D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.

Can you explain more? Does linuxolator need syscall slot 0?

Sep 14 2023, 5:56 PM · Linux Emulation
dchagin updated the summary of D41859: syscall: Allow the sv_fetch_syscall_args to return an uninitialized sysent on error.
Sep 14 2023, 11:04 AM · Linux Emulation
xmj removed a member for Linux Emulation: xmj.
Sep 14 2023, 7:09 AM

Sep 1 2023

jhb added a comment to D38459: timerfd: Add native support for Linux's timerfd.

This patch has been applied to src under commit af93fea710385b2b11f0cabd377e7ed6f3d97c34.

There doesn't seem to be a way to associate this review directly with that commit, so I'm just going to abandon it.

Sep 1 2023, 9:47 PM · linuxkpi, Linux Emulation
jfree abandoned D38459: timerfd: Add native support for Linux's timerfd.

This patch has been applied to src under commit af93fea710385b2b11f0cabd377e7ed6f3d97c34.

Sep 1 2023, 6:41 PM · linuxkpi, Linux Emulation
jfree accepted D38459: timerfd: Add native support for Linux's timerfd.
Sep 1 2023, 6:35 PM · linuxkpi, Linux Emulation

Aug 24 2023

jfree added inline comments to D38459: timerfd: Add native support for Linux's timerfd.
Aug 24 2023, 11:44 PM · linuxkpi, Linux Emulation
mjg added inline comments to D38459: timerfd: Add native support for Linux's timerfd.
Aug 24 2023, 11:11 PM · linuxkpi, Linux Emulation
jfree added a comment to D38459: timerfd: Add native support for Linux's timerfd.
In D38459#947334, @imp wrote:

Are there any tests?

Aug 24 2023, 2:08 PM · linuxkpi, Linux Emulation
jfree abandoned D38460: timerfd: Add libc syscall wrappers.
Aug 24 2023, 2:01 PM · linuxkpi, Linux Emulation
imp updated subscribers of D38459: timerfd: Add native support for Linux's timerfd.
Aug 24 2023, 5:07 AM · linuxkpi, Linux Emulation
imp added a comment to D38459: timerfd: Add native support for Linux's timerfd.

I have this staged and plan to commit once I confirm universe builds.

Aug 24 2023, 5:03 AM · linuxkpi, Linux Emulation

Aug 17 2023

dchagin closed D34555: linuxulator: add sendfile fallback for non-socket FDs.
Aug 17 2023, 7:59 PM · Linux Emulation

Aug 4 2023

dchagin closed D41153: linux(4): Add a dedicated ioprio system calls.
Aug 4 2023, 1:05 PM · Linux Emulation

Jul 29 2023

dchagin closed D41224: linux(4): Fix control message size calculation.
Jul 29 2023, 8:23 AM · Linux Emulation

Jul 28 2023

dchagin added a reviewer for D41224: linux(4): Fix control message size calculation: Linux Emulation.
Jul 28 2023, 9:17 AM · Linux Emulation
dchagin closed D41165: linux(4): Add elf_hwcap2 to x86.
Jul 28 2023, 8:57 AM · Linux Emulation

Jul 24 2023

dchagin added a reviewer for D41165: linux(4): Add elf_hwcap2 to x86: Linux Emulation.
Jul 24 2023, 8:08 PM · Linux Emulation
dchagin added a project to D41165: linux(4): Add elf_hwcap2 to x86: Linux Emulation.
Jul 24 2023, 8:08 PM · Linux Emulation
dchagin abandoned D41162: linux(4): Properly apply the protection mode for stack.
Jul 24 2023, 8:08 PM · Linux Emulation
dchagin added a comment to D41162: linux(4): Properly apply the protection mode for stack.

hmm, looks like the problem in how protections handled during stack grows

Jul 24 2023, 7:45 PM · Linux Emulation
dchagin added reviewers for D41162: linux(4): Properly apply the protection mode for stack: Linux Emulation, kib.
Jul 24 2023, 6:18 PM · Linux Emulation
dchagin added a comment to D41153: linux(4): Add a dedicated ioprio system calls.

debootstrap for Ubuntu 23.04 requires Linux ionice command which depends on these syscalls

Jul 24 2023, 6:18 PM · Linux Emulation
dchagin added a reviewer for D41153: linux(4): Add a dedicated ioprio system calls: Linux Emulation.
Jul 24 2023, 6:18 PM · Linux Emulation

Jul 22 2023

dchagin closed D35544: linux(4): Implement xattr syscalls.
Jul 22 2023, 11:10 AM · Linux Emulation

Jul 18 2023

minsoochoo0122_proton.me removed a member for Linux Emulation: minsoochoo0122_proton.me.
Jul 18 2023, 8:20 PM
minsoochoo0122_proton.me added a watcher for Linux Emulation: minsoochoo0122_proton.me.
Jul 18 2023, 8:20 PM

Jun 29 2023

Herald added a reviewer for D40096: linux(4): Make ptrace_pokeusr machine dependent: andrew.
Jun 29 2023, 8:26 AM · Linux Emulation
Herald added a reviewer for D40095: linux(4): Make ptrace_peekusr machine dependend: andrew.
Jun 29 2023, 8:21 AM · Linux Emulation
Herald added a reviewer for D39645: linux(4): Fix LINUX_AT_COUNT comments: andrew.
Jun 29 2023, 8:20 AM · Linux Emulation
Herald added a reviewer for D39644: linux(4): Deduplicate linux_copyout_auxargs(): andrew.
Jun 29 2023, 8:20 AM · Linux Emulation

Jun 28 2023

jfree added a comment to D38459: timerfd: Add native support for Linux's timerfd.

I would like to get this patch committed before the 14.0 freeze in August. I am personally in favor of making these syscalls, but I'd like some notice if we're not going this route.

Jun 28 2023, 8:01 PM · linuxkpi, Linux Emulation
jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.

Add brief comments explaining each of the tfd_jumped macros.

Jun 28 2023, 7:57 PM · linuxkpi, Linux Emulation

Jun 8 2023

dchagin closed D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 8 2023, 10:34 PM · Linux Emulation
dchagin closed D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 8 2023, 10:34 PM · Linux Emulation
kib accepted D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 8 2023, 6:50 PM · Linux Emulation
dchagin updated the diff for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.

whoops, magic2 type changed to uint32_t too

Jun 8 2023, 8:06 AM · Linux Emulation
dchagin updated the diff for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.

Yes, done, it's much better now, thank you!

Jun 8 2023, 8:03 AM · Linux Emulation

Jun 7 2023

kib added inline comments to D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 7 2023, 11:22 PM · Linux Emulation
dchagin added inline comments to D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 7 2023, 11:14 PM · Linux Emulation
kib added inline comments to D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 7 2023, 10:12 PM · Linux Emulation
kib accepted D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 10:08 PM · Linux Emulation
dchagin added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 9:43 PM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 9:21 PM · Linux Emulation
dchagin added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 3:14 PM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 2:05 PM · Linux Emulation
dchagin updated the diff for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.

Don't leak xfpustate if copyin of magic2 failed

Jun 7 2023, 8:41 AM · Linux Emulation
dchagin updated the diff for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.

Rebase to D40443

Jun 7 2023, 8:07 AM · Linux Emulation
dchagin updated the diff for D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.

Done, thank you!

Jun 7 2023, 8:05 AM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 7 2023, 12:11 AM · Linux Emulation

Jun 6 2023

dchagin added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 11:23 PM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 11:09 PM · Linux Emulation
dchagin added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 10:59 PM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 10:31 PM · Linux Emulation
dchagin added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 9:54 PM · Linux Emulation
kib added inline comments to D40443: linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 9:14 PM · Linux Emulation
dchagin updated the diff for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.

ugh, old commit, fix magic2 printout in error and some comments

Jun 6 2023, 8:16 PM · Linux Emulation
dchagin updated the test plan for D40444: linux(4): Preserve fpu xsave state across signal delivery on amd64.
Jun 6 2023, 8:09 PM · Linux Emulation
dchagin retitled D40443: linux(4): In preparation for xsave refactor fxsave code on amd64 from linux(4): In preparation for xsave refactor fxsave code to linux(4): In preparation for xsave refactor fxsave code on amd64.
Jun 6 2023, 8:08 PM · Linux Emulation

May 31 2023

imp added a comment to D38459: timerfd: Add native support for Linux's timerfd.
In D38459#918469, @kib wrote:
In D38459#918467, @imp wrote:

I have code that automatically translates new system calls between host/target for bsd-user (though I'm not quite ready to commit it).
ioctl is possible, but has a lot more exceptional cases so is harder to do automatically. There's no automated annotation like there is for system calls.
The 'generic interfaces' require that I go and create annotations for each of the 'op codes' in that, because that doesn't exist in our current annotation.

So having a few extra system calls means they will be annotated and my job of getting it to work in bsd-user and others wanting to do automatic translation is easier.

For system calls you do need annotations, you cannot properly understand the purpose of any pointer passed to syscall otherwise. Is it in, out, in/out, or even just an abstract address like mmap/munmap/madvise arguments?

May 31 2023, 7:43 PM · linuxkpi, Linux Emulation

May 30 2023

mckusick added a comment to D38459: timerfd: Add native support for Linux's timerfd.

For system calls you do need annotations, you cannot properly understand the purpose of any pointer passed to syscall otherwise. Is it in, out, in/out, or even just an abstract address like mmap/munmap/madvise arguments?

For ioctls, the meaning of the command/arg is quite formalized, at least in BSDs. You are well aware that we encode both sizes and directions for copyin and copyout. After I took some time thinking how to implement what you described, I was surprised by the statement that syscalls are easier than ioctls.

That said, I am quite dislike extending the syscall semantical coverage by adding one-off operations. In the case of special fds, having all ops grouped together (under ioctl umbrella) localizes the interfaces and make them more comprehensive. This is, of course, my opinion, but all my experience supports the claim.

May 30 2023, 11:28 PM · linuxkpi, Linux Emulation
kib added a comment to D38459: timerfd: Add native support for Linux's timerfd.
In D38459#918467, @imp wrote:

I have code that automatically translates new system calls between host/target for bsd-user (though I'm not quite ready to commit it).
ioctl is possible, but has a lot more exceptional cases so is harder to do automatically. There's no automated annotation like there is for system calls.
The 'generic interfaces' require that I go and create annotations for each of the 'op codes' in that, because that doesn't exist in our current annotation.

So having a few extra system calls means they will be annotated and my job of getting it to work in bsd-user and others wanting to do automatic translation is easier.

May 30 2023, 10:24 PM · linuxkpi, Linux Emulation
imp added a comment to D38459: timerfd: Add native support for Linux's timerfd.

I have code that automatically translates new system calls between host/target for bsd-user (though I'm not quite ready to commit it).
ioctl is possible, but has a lot more exceptional cases so is harder to do automatically. There's no automated annotation like there is for system calls.
The 'generic interfaces' require that I go and create annotations for each of the 'op codes' in that, because that doesn't exist in our current annotation.

May 30 2023, 10:00 PM · linuxkpi, Linux Emulation

May 29 2023

dchagin closed D39438: linprocfs: Rework according to the new struct pwd facility.
May 29 2023, 8:21 AM · Linux Emulation
dchagin closed D38933: namei: Add the abilty for the ABI to specify an alternate root path.
May 29 2023, 8:20 AM · Linux Emulation

May 28 2023

dchagin closed D40156: linux(4): Fix stack unwinding across signal frame on x86_64.
May 28 2023, 2:08 PM · Linux Emulation
dchagin closed D40155: linux(4): Preserve %rcx (return address) like a Linux do.
May 28 2023, 2:08 PM · Linux Emulation
dchagin closed D40154: linux(4): Simplify %r10 restoring on amd64.
May 28 2023, 2:08 PM · Linux Emulation
dchagin closed D40153: linux(4): Add a comment explaining registers at syscall entry point on amd64.
May 28 2023, 2:08 PM · Linux Emulation
dchagin closed D40152: linux(4): Drop a weird comment from linux_set_syscall_retval on amd64.
May 28 2023, 2:08 PM · Linux Emulation

May 26 2023

dchagin closed D40151: kdump: Decode linux_clone syscall flags.
May 26 2023, 4:35 PM · Linux Emulation
dchagin closed D40150: libsysdecode: Decode linux_clone syscall flags.
May 26 2023, 4:35 PM · Linux Emulation
dchagin closed D40149: linux(4): Guard linux_fork.h by _KERNEL for use by libsysdecode.
May 26 2023, 4:35 PM · Linux Emulation

May 24 2023

kib accepted D38933: namei: Add the abilty for the ABI to specify an alternate root path.
May 24 2023, 5:54 AM · Linux Emulation

May 22 2023

jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.
  • tfd_jumped must be set to TFD_CANCELED, not TFD_JUMPED, for timerfd_settime to return ECANCELED.
  • style(9) line-break fixes courtesy of @mckusick.
May 22 2023, 10:28 PM · linuxkpi, Linux Emulation
jfree added a comment to D38459: timerfd: Add native support for Linux's timerfd.

Er? Can you explain? What is confusing for ioctl, and what is intuitive for the syscall interface?

May 22 2023, 8:42 PM · linuxkpi, Linux Emulation

May 21 2023

kib added a comment to D38459: timerfd: Add native support for Linux's timerfd.

Why? I do not like it very much. It is not as if all (or most) other individual kernel ops where performed by dedicated syscall entries, so I do not see a good reason to do it there. Ioctl perfectly fits the intent of providing file-specific requests.

The system call interface is standard and more intuitive for those that want to extend timerfd later.
The ioctl() implementation is confusing and messy for compat.

Er? Can you explain? What is confusing for ioctl, and what is intuitive for the syscall interface?

May 21 2023, 10:38 PM · linuxkpi, Linux Emulation
jfree added a comment to D38459: timerfd: Add native support for Linux's timerfd.

Why? I do not like it very much. It is not as if all (or most) other individual kernel ops where performed by dedicated syscall entries, so I do not see a good reason to do it there. Ioctl perfectly fits the intent of providing file-specific requests.

May 21 2023, 2:01 PM · linuxkpi, Linux Emulation
kib added a comment to D38459: timerfd: Add native support for Linux's timerfd.
  • Support TFD_TIMER_CANCEL_ON_SET settime flag using timerfd_jumped().
  • Convert ioctl() interface to native syscalls.
May 21 2023, 11:28 AM · linuxkpi, Linux Emulation
jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.
  • Support TFD_TIMER_CANCEL_ON_SET settime flag using timerfd_jumped().
  • Convert ioctl() interface to native syscalls.
May 21 2023, 2:31 AM · linuxkpi, Linux Emulation

May 19 2023

emaste accepted D40149: linux(4): Guard linux_fork.h by _KERNEL for use by libsysdecode.
May 19 2023, 2:25 PM · Linux Emulation
emaste accepted D40151: kdump: Decode linux_clone syscall flags.
May 19 2023, 2:23 PM · Linux Emulation
emaste accepted D40150: libsysdecode: Decode linux_clone syscall flags.
May 19 2023, 2:18 PM · Linux Emulation

May 18 2023

emaste accepted D40152: linux(4): Drop a weird comment from linux_set_syscall_retval on amd64.
May 18 2023, 7:39 PM · Linux Emulation
emaste updated subscribers of D40152: linux(4): Drop a weird comment from linux_set_syscall_retval on amd64.
May 18 2023, 7:39 PM · Linux Emulation
dchagin added a reviewer for D40149: linux(4): Guard linux_fork.h by _KERNEL for use by libsysdecode: Linux Emulation.
May 18 2023, 7:36 PM · Linux Emulation
dchagin added a reviewer for D40150: libsysdecode: Decode linux_clone syscall flags: Linux Emulation.
May 18 2023, 7:36 PM · Linux Emulation
dchagin added a reviewer for D40151: kdump: Decode linux_clone syscall flags: Linux Emulation.
May 18 2023, 7:36 PM · Linux Emulation
dchagin added a reviewer for D40152: linux(4): Drop a weird comment from linux_set_syscall_retval on amd64: Linux Emulation.
May 18 2023, 7:35 PM · Linux Emulation
dchagin added a reviewer for D40153: linux(4): Add a comment explaining registers at syscall entry point on amd64: Linux Emulation.
May 18 2023, 7:35 PM · Linux Emulation
dchagin added a reviewer for D40154: linux(4): Simplify %r10 restoring on amd64: Linux Emulation.
May 18 2023, 7:34 PM · Linux Emulation
dchagin added a reviewer for D40155: linux(4): Preserve %rcx (return address) like a Linux do: Linux Emulation.
May 18 2023, 7:34 PM · Linux Emulation