summaryrefslogtreecommitdiff
path: root/scripts/module-common.c
diff options
context:
space:
mode:
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2024-10-01 19:09:41 +0300
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2024-10-01 19:09:41 +0300
commit2cd86f02c017bf9733e5cd891381b7d40f6f37ad (patch)
tree839e63bdf31a2d1ec68fa8d6fb8dc821f8fcf243 /scripts/module-common.c
parentabf201f6ce14c4ceeccde5471bdf59614b83a3d8 (diff)
parent43102a2012c2e2f8424d7eef52aede8e73cf2fed (diff)
downloadlinux-2cd86f02c017bf9733e5cd891381b7d40f6f37ad.tar.xz
Merge remote-tracking branch 'drm/drm-fixes' into drm-misc-fixes
Required for a panthor fix that broke when FOP_UNSIGNED_OFFSET was added in place of FMODE_UNSIGNED_OFFSET. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'scripts/module-common.c')
-rw-r--r--scripts/module-common.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/scripts/module-common.c b/scripts/module-common.c
new file mode 100644
index 000000000000..12fbc6d3aae8
--- /dev/null
+++ b/scripts/module-common.c
@@ -0,0 +1,25 @@
+// SPDX-License-Identifier: GPL-2.0
+
+#include <linux/module.h>
+/*
+ * Include build-salt.h after module.h in order to
+ * inherit the definitions.
+ */
+#define INCLUDE_VERMAGIC
+#include <linux/build-salt.h>
+#include <linux/elfnote-lto.h>
+#include <linux/vermagic.h>
+
+#ifdef CONFIG_UNWINDER_ORC
+#include <asm/orc_header.h>
+ORC_HEADER;
+#endif
+
+BUILD_SALT;
+BUILD_LTO_INFO;
+
+MODULE_INFO(vermagic, VERMAGIC_STRING);
+
+#ifdef CONFIG_MITIGATION_RETPOLINE
+MODULE_INFO(retpoline, "Y");
+#endif