Page MenuHomeFreeBSD

linuxkpiGroup
ActivePublic

Details

Description

Linux kernel compatibility support

Recent Activity

Mar 4 2024

emaste closed D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.
Mar 4 2024, 2:35 PM · linuxkpi

Mar 2 2024

emaste added a comment to D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.

@bz thanks, commit subject line and Reviewed-by's updated.

Mar 2 2024, 10:07 PM · linuxkpi
bz accepted D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.

Great catch! I wonder what else that will help for the other (unconnected) drivers. Thanks!

Mar 2 2024, 8:10 PM · linuxkpi
emaste updated subscribers of D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.
Mar 2 2024, 7:32 PM · linuxkpi
emaste added a comment to D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.

Now in my staging tree as:

Mar 2 2024, 7:27 PM · linuxkpi
emaste accepted D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.
Mar 2 2024, 7:21 PM · linuxkpi
emaste added a comment to D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.

FYI, please generate diffs for reviews with full context e.g. git diff -U999999 or git show -U999999 so that Phabricator will display the additional context on demand. See https://wiki.freebsd.org/Phabricator for more info.

Mar 2 2024, 6:43 PM · linuxkpi
tom_coldrick.cc requested review of D44192: linuxkpi: Queue skbuffs at tail in skb_queue_tail.
Mar 2 2024, 6:40 PM · linuxkpi

Feb 18 2024

minsoochoo0122_proton.me removed a watcher for linuxkpi: minsoochoo0122_proton.me.
Feb 18 2024, 11:54 PM

Dec 18 2023

dumbbell added a member for linuxkpi: dumbbell.
Dec 18 2023, 7:14 PM

Dec 15 2023

wulf added a member for linuxkpi: wulf.
Dec 15 2023, 7:56 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

Jul 18 2023

minsoochoo0122_proton.me added a watcher for linuxkpi: minsoochoo0122_proton.me.
Jul 18 2023, 8:19 PM
minsoochoo0122_proton.me removed a member for linuxkpi: minsoochoo0122_proton.me.
Jul 18 2023, 8:19 PM

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

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 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 18 2023

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

I have contrary opinion about ioctl vs syscall.

May 18 2023, 12:04 AM · linuxkpi, Linux Emulation

May 10 2023

markj added a comment to D38459: timerfd: Add native support for Linux's timerfd.
    • and also…
  • EVFILT_TIMER is currently subject to a system-wide and small-by-default kern.kq_calloutmax (kq_ncallouts) limit, which feels very unnerving: imagine an important daemon getting starved of timers by some random user app!! This code as-is is not, and I wouldn't like it to be, but then it would be kinda strange that EVFILT_TIMER would still be.
    • should we convert that to a per-{user,process,…} that both facilities would use? An rlimit sounds appropriate I think?
    • but do we need that limit at all? Maybe just abolish it from EVFILT_TIMER?

A per-proc limit sounds appropriate through rlimit. I'm not sure about abolishing the limit altogether, though. I am guessing it was implemented for a reason.

May 10 2023, 5:37 PM · linuxkpi, Linux Emulation

May 9 2023

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

Hey, couple random notes:

  • re: "Developers that wish to support FreeBSD should avoid using timerfd" in the quarterly… :/
    • file descriptor handle based APIs are actually kinda better because composability / fd-passing / capability mode friendliness
      • FreeBSD invented procdesc(4) soo it's strange that we're not yet striving to turn everything into a file descriptor and Linux has us beat on this…
    • also there's no explicit clock selection in EVFILT_TIMER so when we finally add a suspend-aware monotonic clock it would only be possible to explicitly choose suspend-awareness-or-not with timerfd :)
May 9 2023, 5:56 PM · linuxkpi, Linux Emulation
jfree added a comment to D38459: timerfd: Add native support for Linux's timerfd.

Quick update: I'm nearly finished with my school work for the year, so I've had more time to work on this. I've nearly re-engineered the entire patch and I'm passing ~95% of the epoll-shim timerfd testing suite. I should have a new patch out in the next week (hopefully).

May 9 2023, 5:51 PM · linuxkpi, Linux Emulation

Apr 20 2023

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

Hey, couple random notes:

Apr 20 2023, 6:12 AM · linuxkpi, Linux Emulation

Apr 5 2023

grahamperrin removed a watcher for linuxkpi: grahamperrin.
Apr 5 2023, 5:15 AM

Apr 4 2023

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

What is the destiny of these patches? Why did you not committed them still?

Apr 4 2023, 2:18 PM · linuxkpi, Linux Emulation
kib added a comment to D38459: timerfd: Add native support for Linux's timerfd.

What is the destiny of these patches? Why did you not committed them still?

Apr 4 2023, 7:41 AM · linuxkpi, Linux Emulation

Mar 11 2023

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

BTW, something that will need testing is to verify that the timerfd_gettime and timerfd_settime pseudo syscalls work in capability mode.

Mar 11 2023, 1:33 AM · linuxkpi, Linux Emulation

Mar 10 2023

markj accepted D38460: timerfd: Add libc syscall wrappers.
Mar 10 2023, 5:59 PM · linuxkpi, Linux Emulation

Mar 7 2023

kib accepted D38459: timerfd: Add native support for Linux's timerfd.
Mar 7 2023, 1:41 AM · linuxkpi, Linux Emulation
jfree added inline comments to D38459: timerfd: Add native support for Linux's timerfd.
Mar 7 2023, 1:27 AM · linuxkpi, Linux Emulation
jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.
  • Remove __FBSDID tag
  • Move SYSINIT to avoid forward declaring timerfd_init()
  • Correctly check for read blocking in FIONREADioctl case
Mar 7 2023, 1:26 AM · linuxkpi, Linux Emulation

Mar 6 2023

kib added inline comments to D38459: timerfd: Add native support for Linux's timerfd.
Mar 6 2023, 11:54 PM · linuxkpi, Linux Emulation
jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.

Fix minor logic error in FIONREAD ioctl case

Mar 6 2023, 2:21 AM · linuxkpi, Linux Emulation
jfree updated the diff for D38459: timerfd: Add native support for Linux's timerfd.
  • Use SYSINIT() to initialize timerfd ino unit number
  • Use atomic bitwise operations for file flags in FIONBIO ioctl
  • Return 0 when FNONBLOCK is not set in FIONREAD ioctl
Mar 6 2023, 2:13 AM · linuxkpi, Linux Emulation