summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2021-02-22 19:50:01 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2021-02-22 19:50:01 +0300
commit983e4adae0cfa4d3dfdf73b79aabc450dda8ce0e (patch)
treeaddc29bc5cf959ef4eb1258c9722d4afdfaa063e /scripts
parent31caf8b2a847214be856f843e251fc2ed2cd1075 (diff)
parenta7d53dbbc70a81d5781da7fc905b656f41ad2381 (diff)
downloadlinux-983e4adae0cfa4d3dfdf73b79aabc450dda8ce0e.tar.xz
Merge tag 'platform-drivers-x86-v5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86
Pull x86 platform driver updates from Hans de Goede: "Highlights: - Microsoft Surface devices System Aggregator Module support - SW_TABLET_MODE reporting improvements - thinkpad_acpi keyboard language setting support - platform / DPTF profile settings support: - Base / userspace API parts merged from Rafael's acpi-platform branch - thinkpad_acpi and ideapad-laptop support through pdx86 - Remove support for some obsolete Intel MID platforms through merging of the shared intel-mid-removal branch - Big cleanup of the ideapad-laptop driver - Misc other fixes / new hw support / quirks" * tag 'platform-drivers-x86-v5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86: (99 commits) platform/x86: intel_scu_ipc: Increase virtual timeout from 3 to 5 seconds platform/surface: aggregator: Fix access of unaligned value tools/power/x86/intel-speed-select: Update version to 1.8 tools/power/x86/intel-speed-select: Add new command to get/set TRL tools/power/x86/intel-speed-select: Add new command turbo-mode Platform: OLPC: Constify static struct regulator_ops platform/surface: Add Surface Hot-Plug driver platform/x86: intel_scu_wdt: Drop mistakenly added const platform/x86: Kconfig: add missing selects for ideapad-laptop platform/x86: acer-wmi: Don't use ACPI_EXCEPTION() platform/x86: thinkpad_acpi: Replace ifdef CONFIG_ACPI_PLATFORM_PROFILE with depends on platform/x86: thinkpad_acpi: Fix 'warning: no previous prototype for' warnings platform/x86: msi-wmi: Fix variable 'status' set but not used compiler warning platform/surface: surface3-wmi: Fix variable 'status' set but not used compiler warning platform/x86: Move all dell drivers to their own subdirectory Documentation/ABI: sysfs-platform-ideapad-laptop: conservation_mode attribute Documentation/ABI: sysfs-platform-ideapad-laptop: update device attribute paths platform/x86: ideapad-laptop: add "always on USB charging" control support platform/x86: ideapad-laptop: add keyboard backlight control support platform/x86: ideapad-laptop: send notification about touchpad state change to sysfs ...
Diffstat (limited to 'scripts')
-rw-r--r--scripts/mod/devicetable-offsets.c8
-rw-r--r--scripts/mod/file2alias.c23
2 files changed, 31 insertions, 0 deletions
diff --git a/scripts/mod/devicetable-offsets.c b/scripts/mod/devicetable-offsets.c
index e377f52dbfa3..f078eeb0a961 100644
--- a/scripts/mod/devicetable-offsets.c
+++ b/scripts/mod/devicetable-offsets.c
@@ -246,5 +246,13 @@ int main(void)
DEVID(auxiliary_device_id);
DEVID_FIELD(auxiliary_device_id, name);
+ DEVID(ssam_device_id);
+ DEVID_FIELD(ssam_device_id, match_flags);
+ DEVID_FIELD(ssam_device_id, domain);
+ DEVID_FIELD(ssam_device_id, category);
+ DEVID_FIELD(ssam_device_id, target);
+ DEVID_FIELD(ssam_device_id, instance);
+ DEVID_FIELD(ssam_device_id, function);
+
return 0;
}
diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
index fb4827027536..d21d2871387b 100644
--- a/scripts/mod/file2alias.c
+++ b/scripts/mod/file2alias.c
@@ -1375,6 +1375,28 @@ static int do_auxiliary_entry(const char *filename, void *symval, char *alias)
return 1;
}
+/*
+ * Looks like: ssam:dNcNtNiNfN
+ *
+ * N is exactly 2 digits, where each is an upper-case hex digit.
+ */
+static int do_ssam_entry(const char *filename, void *symval, char *alias)
+{
+ DEF_FIELD(symval, ssam_device_id, match_flags);
+ DEF_FIELD(symval, ssam_device_id, domain);
+ DEF_FIELD(symval, ssam_device_id, category);
+ DEF_FIELD(symval, ssam_device_id, target);
+ DEF_FIELD(symval, ssam_device_id, instance);
+ DEF_FIELD(symval, ssam_device_id, function);
+
+ sprintf(alias, "ssam:d%02Xc%02X", domain, category);
+ ADD(alias, "t", match_flags & SSAM_MATCH_TARGET, target);
+ ADD(alias, "i", match_flags & SSAM_MATCH_INSTANCE, instance);
+ ADD(alias, "f", match_flags & SSAM_MATCH_FUNCTION, function);
+
+ return 1;
+}
+
/* Does namelen bytes of name exactly match the symbol? */
static bool sym_is(const char *name, unsigned namelen, const char *symbol)
{
@@ -1450,6 +1472,7 @@ static const struct devtable devtable[] = {
{"wmi", SIZE_wmi_device_id, do_wmi_entry},
{"mhi", SIZE_mhi_device_id, do_mhi_entry},
{"auxiliary", SIZE_auxiliary_device_id, do_auxiliary_entry},
+ {"ssam", SIZE_ssam_device_id, do_ssam_entry},
};
/* Create MODULE_ALIAS() statements.