4b2cb13e manu Aug. 18, 2022, 7:46 a.m.
Those are needed and also included in linux (via polution).

Reviewed by:	bz
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36111
cgit
d4eeb029 manu Aug. 18, 2022, 7:46 a.m.
All those are needed for drm-kmod.
Add them to base in another directory that will be append in the CFLAGS.

Reviewed by:	bz
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36110
cgit
6d3d5653 manu Aug. 18, 2022, 7:46 a.m.
Add needed includes so we can use it.

Reviewed by:	bz
Fixes:	c3f4f28c63da ("linuxkpi: Add some basic swap functions")
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36109
cgit
35b7625e manu Aug. 18, 2022, 7:46 a.m.
Needed by drm-kmod.

Reviewed by:	bz
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36108
cgit
b2c86006 manu Aug. 18, 2022, 7:46 a.m.
Also fill the boot_cpu_data struct as drm needs it.

Reviewed by:	bz
Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36107
cgit
9202c95f manu Aug. 18, 2022, 7:46 a.m.
Variant of dma_{un,}map_sg_attrs for struct sg_table.

Reviewed by:	bz
Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36106
cgit
b1c82bd4 manu Aug. 18, 2022, 7:46 a.m.
With a typedef needed by drm-kmod.

Reviewed by:	bz
Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36105
cgit
fd62b3fa manu Aug. 18, 2022, 7:46 a.m.
Needed by drm-kmod

Reviewed by:	bz
Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36101
cgit
8828ebd6 manu Aug. 18, 2022, 7:46 a.m.
With stubs needed by drm-kmod.

Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36100
cgit
1a6874e3 manu Aug. 18, 2022, 7:46 a.m.
In Linux this takes a refcount_t argument but in linuxkpi struct kref
uses an atomic_t for the refcount and code in drm directly uses this
function with a kref so use an atomic_t here.

Reviewed by:	bz
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36099
cgit
4370e9f1 manu Aug. 18, 2022, 7:46 a.m.
Needed by drm-kmod.

Reviewed by:	bz
Obtained from:	drm-kmod
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D36098
cgit
c6890399 jrtc27 Aug. 18, 2022, 1:46 a.m.
This adds missing includes, uses the standard dirent.h rather than the
BSD-specific sys/dirent.h subset (which works on macOS but not Linux)
and works around Linux's lack of st_birthtim.

This allows usr.sbin/makefs to be added to LOCAL_XTOOL_DIRS again on
macOS and Linux so that disk images can be cross-built.

Reviewed by:	markj
Fixes:		240afd8c1fcc ("makefs: Add ZFS support")
Differential Revision:	https://reviews.freebsd.org/D36135
cgit
548f8a65 jrtc27 Aug. 18, 2022, 1:46 a.m.
flsll is needed for makefs's new ZFS support, and the others are added
for completeness.

Reviewed by:	emaste, arichardson
Fixes:		240afd8c1fcc ("makefs: Add ZFS support")
Differential Revision:	https://reviews.freebsd.org/D36134
cgit
e9ba1fd5 jrtc27 Aug. 18, 2022, 1:46 a.m.
This is needed for building makefs as a cross-tool since the ZFS code
uses these APIs.

Reviewed by:	emaste
Fixes:		240afd8c1fcc ("makefs: Add ZFS support")
Differential Revision:	https://reviews.freebsd.org/D36133
cgit
92fc50b4 jrtc27 Aug. 18, 2022, 1:46 a.m.
This will allow the code to be reused by the cross-build sys/types.h
wrapper in order to provide the APIs for greater compatibility. This
also provides a path towards eventually removing the definitions from
sys/types.h altogether if so desired by gradually migrating users to
including sys/bitcount.h explicitly, but that is not the primary goal
here.

Note that the copyright header is a direct copu of sys/types.h's given
that's where this code comes from. This could be replaced in future with
a more specific one restricted to just the code in question, depending
on what the copyright for that code is.

Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D36132
cgit