diff options
author | Luis R. Rodriguez <mcgrof@do-not-panic.com> | 2013-07-23 17:36:40 -0700 |
---|---|---|
committer | Luis R. Rodriguez <mcgrof@do-not-panic.com> | 2013-07-23 17:36:54 -0700 |
commit | f6dcbe29fef0074a351b26723790a03a1f8a2a4b (patch) | |
tree | 31c3b227edea32128752cc7d3df2e09325a18ed3 /backport/backport-include/linux/mod_devicetable.h | |
parent | a719752a5588262e20a8f6b2910000e55393cfd4 (diff) |
backports: fix DMI_EXACT_MATCH() backport
DMI_EXACT_MATCH uses struct dmi_strmatch's new member exact_match:
@@ -456,7 +456,8 @@ enum dmi_field {
};
struct dmi_strmatch {
- unsigned char slot;
+ unsigned char slot:7;
+ unsigned char exact_match:1;
char substr[79];
};
Prior to 5017b285 we only had slot so to use DMI_EXACT_MATCH with its
intent we'd have to do something like slot |= 1 if its called. This
however assumes though that older code has the sanity check as changed
in 5017b285 on drivers/firmware/dmi_scan.c. dmi_scan.o gets linked
with CONFIG_DMI. At least for x86 that gets objects sprinkled on
arch/x86/, but more importantly CONFIG_DMI is bool. I've argued how I
envision us being able to backport core components before (see
0935deab for the hint) but as it is right now we can't. We only
backport things we can throw in as modular.
Since we only backport modularly for now we can't backport DMI_EXACT_MATCH()
and as such all entries defined with DMI_EXACT_MATCH() should be ifdef'd
out for usage only on kernels >= v3.11 but to help reduce code churn we
can also just force such entries to be ignored for now. We therefore
backport DMI_EXACT_MATCH() for now to match something that will not be
found.
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
Diffstat (limited to 'backport/backport-include/linux/mod_devicetable.h')
-rw-r--r-- | backport/backport-include/linux/mod_devicetable.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/backport/backport-include/linux/mod_devicetable.h b/backport/backport-include/linux/mod_devicetable.h index 5b636371..c09793bc 100644 --- a/backport/backport-include/linux/mod_devicetable.h +++ b/backport/backport-include/linux/mod_devicetable.h @@ -3,7 +3,7 @@ #include_next <linux/mod_devicetable.h> #if LINUX_VERSION_CODE < KERNEL_VERSION(3,11,0) -#define DMI_EXACT_MATCH(a, b) { a, b } +#define DMI_EXACT_MATCH(a, b) DMI_MATCH(DMI_PRODUCT_NAME, "BACKPORT_IGNORE") #endif #ifndef HID_BUS_ANY |