diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2024-03-13 10:10:30 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2024-03-13 10:10:30 -0700 |
commit | aa7d6513d68bad539142f9d6c3e2faa629bc27d8 (patch) | |
tree | c15ef8a1d3e69e78f87e258f0cb9216a9da55bf8 /scripts | |
parent | 61387b8dcf1dc0f30cf690956a48768a3fce1810 (diff) | |
parent | 8a0a62941a042612f7487f6c4ff291f9054ff214 (diff) |
Merge tag 'tag-chrome-platform-firmware-for-v6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux
Pull chrome platform firmware updates from Tzung-Bi Shih:
- Allow userspace to automatically load coreboot modules by adding
modaliases and sending uevents
- Make bus_type const
* tag 'tag-chrome-platform-firmware-for-v6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux:
firmware: coreboot: Replace tag with id table in driver struct
firmware: coreboot: Generate aliases for coreboot modules
firmware: coreboot: Generate modalias uevent for devices
firmware: coreboot: make coreboot_bus_type const
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/mod/devicetable-offsets.c | 3 | ||||
-rw-r--r-- | scripts/mod/file2alias.c | 10 |
2 files changed, 13 insertions, 0 deletions
diff --git a/scripts/mod/devicetable-offsets.c b/scripts/mod/devicetable-offsets.c index e91a3c38143b..518200813d4e 100644 --- a/scripts/mod/devicetable-offsets.c +++ b/scripts/mod/devicetable-offsets.c @@ -274,5 +274,8 @@ int main(void) DEVID(vchiq_device_id); DEVID_FIELD(vchiq_device_id, name); + DEVID(coreboot_device_id); + DEVID_FIELD(coreboot_device_id, tag); + return 0; } diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c index 4829680a0a6d..5d1c61fa5a55 100644 --- a/scripts/mod/file2alias.c +++ b/scripts/mod/file2alias.c @@ -1494,6 +1494,15 @@ static int do_vchiq_entry(const char *filename, void *symval, char *alias) return 1; } +/* Looks like: coreboot:tN */ +static int do_coreboot_entry(const char *filename, void *symval, char *alias) +{ + DEF_FIELD(symval, coreboot_device_id, tag); + sprintf(alias, "coreboot:t%08X", tag); + + return 1; +} + /* Does namelen bytes of name exactly match the symbol? */ static bool sym_is(const char *name, unsigned namelen, const char *symbol) { @@ -1575,6 +1584,7 @@ static const struct devtable devtable[] = { {"ishtp", SIZE_ishtp_device_id, do_ishtp_entry}, {"cdx", SIZE_cdx_device_id, do_cdx_entry}, {"vchiq", SIZE_vchiq_device_id, do_vchiq_entry}, + {"coreboot", SIZE_coreboot_device_id, do_coreboot_entry}, }; /* Create MODULE_ALIAS() statements. |