Discussion:
ioctls that return file descriptors
(too old to reply)
Paul Floyd
2024-09-14 10:10:14 UTC
Permalink
Hi

Does anyone know of any FreeBSD ioctls that return file descriptors?

An example from Linux is DRM_IOCTL_SYNCOBJ_HANDLE_TO_FD.

A+
Paul



--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Konstantin Belousov
2024-09-14 10:42:28 UTC
Permalink
Post by Paul Floyd
Hi
Does anyone know of any FreeBSD ioctls that return file descriptors?
An example from Linux is DRM_IOCTL_SYNCOBJ_HANDLE_TO_FD.
I expect that the same ioctl is implemented by the FreeBSD drm kmod.

For in-tree, you could search for falloc_caps() calls. Quick grep
shows it is only used by expected syscalls, not by drivers.


--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Paul Floyd
2024-09-14 19:15:43 UTC
Permalink
Post by Konstantin Belousov
Post by Paul Floyd
Hi
Does anyone know of any FreeBSD ioctls that return file descriptors?
An example from Linux is DRM_IOCTL_SYNCOBJ_HANDLE_TO_FD.
I expect that the same ioctl is implemented by the FreeBSD drm kmod.
For in-tree, you could search for falloc_caps() calls. Quick grep
shows it is only used by expected syscalls, not by drivers.
Thanks for that.

There is DRM_IOCTL_PRIME_HANDLE_TO_FD but not
DRM_IOCTL_SYNCOBJ_HANDLE_TO_FD.

I see also that there's one _umtx_op sub-command that I wasn't handling.

A+
Paul


--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...