]> git.baikalelectronics.ru Git - kernel.git/commitdiff
x86/devicetable: Move x86 specific macro out of generic code
authorThomas Gleixner <tglx@linutronix.de>
Mon, 3 Oct 2022 13:10:04 +0000 (10:10 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 7 Oct 2022 07:16:54 +0000 (09:16 +0200)
commit 9af5e5e410de3c0f985666192708222871ecab09 upstream.

There is no reason that this gunk is in a generic header file. The wildcard
defines need to stay as they are required by file2alias.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Link: https://lkml.kernel.org/r/20200320131508.736205164@linutronix.de
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/include/asm/cpu_device_id.h
arch/x86/kvm/svm.c
arch/x86/kvm/vmx/vmx.c
drivers/cpufreq/acpi-cpufreq.c
drivers/cpufreq/amd_freq_sensitivity.c
include/linux/mod_devicetable.h

index 31c379c1da41c48b7f4ee89d3c100d62895ff5b2..a28dc6ba5be1574b4fb58e33ee0cd5d66a22f636 100644 (file)
@@ -6,9 +6,20 @@
  * Declare drivers belonging to specific x86 CPUs
  * Similar in spirit to pci_device_id and related PCI functions
  */
-
 #include <linux/mod_devicetable.h>
 
+/*
+ * The wildcard initializers are in mod_devicetable.h because
+ * file2alias needs them. Sigh.
+ */
+
+#define X86_FEATURE_MATCH(x) {                 \
+       .vendor         = X86_VENDOR_ANY,       \
+       .family         = X86_FAMILY_ANY,       \
+       .model          = X86_MODEL_ANY,        \
+       .feature        = x,                    \
+}
+
 /*
  * Match specific microcode revisions.
  *
index 1efcc7d4bc88ed009ea363f33f62f3c835be3405..3db407e3c4166a4feb2b57e7ce960b49b64993dd 100644 (file)
@@ -47,6 +47,7 @@
 #include <asm/kvm_para.h>
 #include <asm/irq_remapping.h>
 #include <asm/spec-ctrl.h>
+#include <asm/cpu_device_id.h>
 
 #include <asm/virtext.h>
 #include "trace.h"
index 4bd1bf6214eea185f77b11d60aa6221ea7101c55..766612a339afa6989822baa7df57458fc0f7af36 100644 (file)
@@ -31,6 +31,7 @@
 #include <asm/apic.h>
 #include <asm/asm.h>
 #include <asm/cpu.h>
+#include <asm/cpu_device_id.h>
 #include <asm/debugreg.h>
 #include <asm/desc.h>
 #include <asm/fpu/internal.h>
index 4195834a45912e405eebf5b278ca761e72586500..cf7ebe3bd1ad2d89365dd0f4ef83591ea5a8d877 100644 (file)
@@ -30,6 +30,7 @@
 #include <asm/msr.h>
 #include <asm/processor.h>
 #include <asm/cpufeature.h>
+#include <asm/cpu_device_id.h>
 
 MODULE_AUTHOR("Paul Diefenbaugh, Dominik Brodowski");
 MODULE_DESCRIPTION("ACPI Processor P-States Driver");
index e2df9d1121063ba8d4a6e85b950d4b23dbaa38e6..5107cbe2d64dd2aeabb06d8b0e1d63e2c9dccb1a 100644 (file)
@@ -18,6 +18,7 @@
 
 #include <asm/msr.h>
 #include <asm/cpufeature.h>
+#include <asm/cpu_device_id.h>
 
 #include "cpufreq_ondemand.h"
 
index 04a19e30b16860bd9b74725b5c081876273b40ac..d82048680e59d05d64e3230e2b7db60f07212e2a 100644 (file)
@@ -667,9 +667,7 @@ struct x86_cpu_id {
        kernel_ulong_t driver_data;
 };
 
-#define X86_FEATURE_MATCH(x) \
-       { X86_VENDOR_ANY, X86_FAMILY_ANY, X86_MODEL_ANY, x }
-
+/* Wild cards for x86_cpu_id::vendor, family, model and feature */
 #define X86_VENDOR_ANY 0xffff
 #define X86_FAMILY_ANY 0
 #define X86_MODEL_ANY  0