diff options
| author | H. Peter Anvin <hpa@zytor.com> | 2008-09-04 19:08:42 +0400 |
|---|---|---|
| committer | H. Peter Anvin <hpa@zytor.com> | 2008-09-04 19:08:42 +0400 |
| commit | 7203781c98ad9147564d327de6f6513ad8fc0f4e (patch) | |
| tree | 5c29a2a04a626bf08a0d56fd8a0068b3c92ad284 /scripts | |
| parent | 671eef85a3e885dff4ce210d8774ad50a91d5967 (diff) | |
| parent | af2e1f276ff08f17192411ea3b71c13a758dfe12 (diff) | |
| download | linux-7203781c98ad9147564d327de6f6513ad8fc0f4e.tar.xz | |
Merge branch 'x86/cpu' into x86/core
Conflicts:
arch/x86/kernel/cpu/feature_names.c
include/asm-x86/cpufeature.h
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/mod/file2alias.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c index 4fa1f3ad2513..4c9890ec2528 100644 --- a/scripts/mod/file2alias.c +++ b/scripts/mod/file2alias.c @@ -344,14 +344,20 @@ static void do_pnp_device_entry(void *symval, unsigned long size, struct module *mod) { const unsigned long id_size = sizeof(struct pnp_device_id); - const struct pnp_device_id *id = symval; + const unsigned int count = (size / id_size)-1; + const struct pnp_device_id *devs = symval; + unsigned int i; device_id_check(mod->name, "pnp", size, id_size, symval); - buf_printf(&mod->dev_table_buf, - "MODULE_ALIAS(\"pnp:d%s*\");\n", id->id); - buf_printf(&mod->dev_table_buf, - "MODULE_ALIAS(\"acpi*:%s:*\");\n", id->id); + for (i = 0; i < count; i++) { + const char *id = (char *)devs[i].id; + + buf_printf(&mod->dev_table_buf, + "MODULE_ALIAS(\"pnp:d%s*\");\n", id); + buf_printf(&mod->dev_table_buf, + "MODULE_ALIAS(\"acpi*:%s:*\");\n", id); + } } /* looks like: "pnp:dD" for every device of the card */ |
