Page MenuHomeFreeBSD

linuxkpi: Add missing includes leading to <linux/kconfig.h>
AbandonedPublic

Authored by dumbbell on Sun, Jun 14, 9:11 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Jun 15, 2:31 PM
Unknown Object (File)
Mon, Jun 15, 2:11 PM
Unknown Object (File)
Sun, Jun 14, 6:25 PM
Subscribers

Details

Reviewers
None
Group Reviewers
linuxkpi
Summary

Several include paths lead to <linux/kconfig.h>. This commit adds those that help resolve a buil failure of the i915 DRM driver.

One awkward fix is in <linux/radix-tree.h>. On Linux, <linux/radix-tress.h> includes <linux/xarray.h>. However on FreeBSD, this is the opposite because an xarray is implemented on top of a radix-tree. Unfortunately, some code relies on the namespace pollution; for instance to implicitly import IS_ENABLED() in a header of the i915 DRM driver.

To kind of implement this order of includes, we include <linux/xarray.h> at the end of <linux/radix-tree.h>. It is at the end because <linux/xarray.h> depends on the definitions above in <linux/radix-tree.h>.

The i915 DRM driver started to depend on this namespace pollution to import IS_ENABLED() in <linux/kconfig.h>.

This is part of the update of DRM drivers to Linux 6.13.

Sponsored by: The FreeBSD Foundation

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped