[Bug 273458] SIOCGIFDATA should be _IORW not _IOW

From: <bugzilla-noreply_at_freebsd.org>
Date: Wed, 30 Aug 2023 19:40:22 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=273458

Brooks Davis <brooks@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |brooks@FreeBSD.org

--- Comment #1 from Brooks Davis <brooks@FreeBSD.org> ---
On FreeBSD the _IO* values set flags in the command word that control what
centralized copyin/out operations are performed by the ioctl infrastructure and
_IOW is correct for something that should not modify the copied in ifreq.

While I can imagine use cases were it would be nice to know if any data is to
be written out, I don't believe the flags set by _IO* are part of the public
API of ioctl and introducing a pointless copyout isn't the right thing to do.

Note that changing this define would be a ABI break and we'd have to support
_IOW('i', 44, struct ifreq) essentially forever.

-- 
You are receiving this mail because:
You are the assignee for the bug.