diff mbox series

[64/75] header: Add module.h include to firmware.h

Message ID 20240627234808.1253337-65-hauke@hauke-m.de (mailing list archive)
State New, archived
Headers show
Series backports: Update to kernel 6.1.95 | expand

Commit Message

Hauke Mehrtens June 27, 2024, 11:47 p.m. UTC
Many drivers do not include linux/module.h directly, but use definitions
from it. They include the firmware.h

In later kernel versions this additional include is already done by the
kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/firmware.h | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox series

Patch

diff --git a/backport/backport-include/linux/firmware.h b/backport/backport-include/linux/firmware.h
index 9bfe6e9d..36d0702a 100644
--- a/backport/backport-include/linux/firmware.h
+++ b/backport/backport-include/linux/firmware.h
@@ -2,6 +2,10 @@ 
 #define __BACKPORT_LINUX_FIRMWARE_H
 #include_next <linux/firmware.h>
 
+#if LINUX_VERSION_IS_LESS(5,6,0)
+#include <linux/module.h>
+#endif
+
 #if LINUX_VERSION_IS_LESS(4,18,0)
 #define firmware_request_nowarn(fw, name, device) request_firmware(fw, name, device)
 #endif