sys/cpu/x86_64: Expose CPUMASK macros to userspace without _KERNEL_STRUCTURES
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Fri, 15 Jul 2016 23:57:06 +0000 (08:57 +0900)
committerTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Sat, 16 Jul 2016 12:07:46 +0000 (21:07 +0900)
commit6e279e27dfa05662c35f719a51b9c78656f9eaed
tree4f9f5293ca8b8e229f4095a748c8e4782a34440e
parentc9ab3383f9c85a578f919f886c0bb1f2792333c7
sys/cpu/x86_64: Expose CPUMASK macros to userspace without _KERNEL_STRUCTURES

Userspace programs other than /sbin/usched may use cpu affinity,
as the syscall was added for userspace programs to control it,
so it should not require _KERNEL_STRUCTURES.

Also note that cpumask_t which is a structure used by CPUMASK
macros doesn't require _KERNEL_STRUCTURES.

Confirmed the change doesn't break buildworld and buildkernel/LINT64.

(I actually had compile-time issues with fio while trying to add
cpu affinity support, and ended up copy-pasting CPUMASK macros
to a DragonFly specific header in fio source without defining
_KERNEL_STRUCTURES)
sbin/usched/usched.c
sys/cpu/x86_64/include/types.h