HomeFreeBSD

linuxkpi: Add `struct xa_limit` support to xarray

Description

linuxkpi: Add struct xa_limit support to xarray

The xa_alloc*() functions family takes a struct xa_limit to describe
the range of IDs the caller wants to allocate. We were using a single
mask to qualify a maximum ID only.

This commit changes that to use the same struct xa_limit. The logic
did not change, except it now supports a minimum ID as well.

The definition of XA_LIMIT() macro is adapted, as well as the
definitions of xa_limit_* (only xa_limit_32b existed, the other two
are added with this commit).

The DRM generic code started to use this struct xa_limit in Linux
6.12.

Reviewed by: bz
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D56445

Details

Provenance
dumbbellAuthored on Apr 13 2026, 9:39 PM
Reviewer
bz
Differential Revision
D56445: linuxkpi: Add `struct xa_limit` support to xarray
Parents
rGb683fd0b3206: preload: add "show preload" DDB command
Branches
Unknown
Tags
Unknown