Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Mar 2026 20:28:15 +0000
From:      Bjoern A. Zeeb <bz@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 29dce45d8c50 - stable/15 - LinuxKPI: add supporting #includes
Message-ID:  <69cc2e5f.26dc4.671fe228@gitrepo.freebsd.org>

index | next in thread | raw e-mail

The branch stable/15 has been updated by bz:

URL: https://cgit.FreeBSD.org/src/commit/?id=29dce45d8c50ea5858dc91a4294e83b8d72a2f80

commit 29dce45d8c50ea5858dc91a4294e83b8d72a2f80
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2026-03-19 20:29:29 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2026-03-31 16:22:51 +0000

    LinuxKPI: add supporting #includes
    
    Compiling drm-kmod on !X86 does not include asm/smp.h which includes
    preempt.h on FreeBSD.  In order to compile drm-kmod on other
    architectures add the secondary #includes for preempt.h to
    spinlock.h and hardirq.h (which now also gets included from highmem.h)
    to connect the #include chain.
    
    Sponsored by:   The FreeBSD Foundation
    PR:             279864
    Reviewed by:    jhibbits, emaste
    Differential Revision: https://reviews.freebsd.org/D55974
    
    (cherry picked from commit 1d18872c2519d7ca726ddc49735180ab1d8916e0)
---
 sys/compat/linuxkpi/common/include/linux/hardirq.h  | 1 +
 sys/compat/linuxkpi/common/include/linux/highmem.h  | 1 +
 sys/compat/linuxkpi/common/include/linux/spinlock.h | 1 +
 3 files changed, 3 insertions(+)

diff --git a/sys/compat/linuxkpi/common/include/linux/hardirq.h b/sys/compat/linuxkpi/common/include/linux/hardirq.h
index f79451dd0d35..c6cbf1a34f14 100644
--- a/sys/compat/linuxkpi/common/include/linux/hardirq.h
+++ b/sys/compat/linuxkpi/common/include/linux/hardirq.h
@@ -31,6 +31,7 @@
 
 #include <linux/types.h>
 #include <linux/lockdep.h>
+#include <linux/preempt.h>
 
 #include <sys/param.h>
 #include <sys/bus.h>
diff --git a/sys/compat/linuxkpi/common/include/linux/highmem.h b/sys/compat/linuxkpi/common/include/linux/highmem.h
index 58a9cdcdf60f..dc1c4fe2f299 100644
--- a/sys/compat/linuxkpi/common/include/linux/highmem.h
+++ b/sys/compat/linuxkpi/common/include/linux/highmem.h
@@ -45,6 +45,7 @@
 
 #include <linux/mm.h>
 #include <linux/page.h>
+#include <linux/hardirq.h>
 
 #define	PageHighMem(p)		(0)
 
diff --git a/sys/compat/linuxkpi/common/include/linux/spinlock.h b/sys/compat/linuxkpi/common/include/linux/spinlock.h
index a08edcf8f417..0ab81d92d4ef 100644
--- a/sys/compat/linuxkpi/common/include/linux/spinlock.h
+++ b/sys/compat/linuxkpi/common/include/linux/spinlock.h
@@ -41,6 +41,7 @@
 #include <linux/rwlock.h>
 #include <linux/bottom_half.h>
 #include <linux/lockdep.h>
+#include <linux/preempt.h>
 
 typedef struct mtx spinlock_t;
 


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69cc2e5f.26dc4.671fe228>