diff options
author | Lucas De Marchi <lucas.demarchi@intel.com> | 2022-02-09 18:46:34 -0800 |
---|---|---|
committer | Lucas De Marchi <lucas.demarchi@intel.com> | 2022-02-11 22:06:34 -0800 |
commit | 7a0f593de3bef04b8f8d35e51f76995d0493d007 (patch) | |
tree | 97de9ef986f5d4a1859e47a2a6800c7a4751873d | |
parent | a965641625dab1688b202e1f8b8b52497d75eeb1 (diff) | |
download | kmod-7a0f593de3bef04b8f8d35e51f76995d0493d007.tar.gz kmod-7a0f593de3bef04b8f8d35e51f76995d0493d007.tar.bz2 kmod-7a0f593de3bef04b8f8d35e51f76995d0493d007.zip |
depmod: Do not duplicate builtin index
Now that libkmod uses modules.builtin.bin again, we don't need to add
the module names in modules.builtin.alias.bin and just add the aliases.
After this change, here are the new sizes for the indexes:
Before After index
21k 6.4K modules.builtin.alias.bin
11k 11K modules.builtin.bin
-rw-r--r-- | tools/depmod.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/tools/depmod.c b/tools/depmod.c index eb810b8..ac6ead8 100644 --- a/tools/depmod.c +++ b/tools/depmod.c @@ -2405,7 +2405,7 @@ static int output_devname(struct depmod *depmod, FILE *out) static int output_builtin_alias_bin(struct depmod *depmod, FILE *out) { - int ret = 0, count = 0; + int ret = 0; struct index_node *idx; struct kmod_list *l, *builtin = NULL; @@ -2450,9 +2450,6 @@ static int output_builtin_alias_bin(struct depmod *depmod, FILE *out) } kmod_module_info_free_list(info_list); - - index_insert(idx, modname, modname, 0); - count++; } out: |