summaryrefslogtreecommitdiff
path: root/modutils/modinfo.c
AgeCommit message (Collapse)Author
2017-07-21config: deindent all help textsDenys Vlasenko
Those two spaces after tab have no effect, and always a nuisance when editing. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2017-07-18Update menuconfig items with approximate applet sizesDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2017-04-17Spelling fixes in comments, documentation, tests and examplesDenys Vlasenko
By klemens <ka7@github.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-10-28modinfo: fix "-F firmware", add "intree" field displayDenys Vlasenko
function old new delta shortcuts - 52 +52 modinfo 317 330 +13 display 77 87 +10 packed_usage 30752 30761 +9 modinfo_main 351 345 -6 static.shortcuts 48 - -48 ------------------------------------------------------------------------------ (add/remove: 1/1 grow/shrink: 3/1 up/down: 84/-54) Total: 30 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-03-12libbb: introduce and use is_prefixed_with()Denys Vlasenko
function old new delta is_prefixed_with - 18 +18 complete_username 78 77 -1 man_main 737 735 -2 fsck_device 429 427 -2 unpack_ar_archive 80 76 -4 strip_unsafe_prefix 105 101 -4 singlemount 1054 1050 -4 rtc_adjtime_is_utc 90 86 -4 resolve_mount_spec 88 84 -4 parse_one_line 1029 1025 -4 parse_conf 1460 1456 -4 may_wakeup 83 79 -4 loadkmap_main 219 215 -4 get_irqs_from_stat 103 99 -4 get_header_cpio 913 909 -4 findfs_main 79 75 -4 fbsplash_main 1230 1226 -4 load_crontab 776 771 -5 expand_vars_to_list 1151 1146 -5 date_main 881 876 -5 skip_dev_pfx 30 24 -6 make_device 2199 2193 -6 complete_cmd_dir_file 773 767 -6 run_applet_and_exit 715 708 -7 uudecode_main 321 313 -8 pwdx_main 197 189 -8 execute 568 560 -8 i2cdetect_main 1186 1176 -10 procps_scan 1242 1230 -12 procps_read_smaps 1017 1005 -12 process_module 746 734 -12 patch_main 1903 1891 -12 nfsmount 3572 3560 -12 stack_machine 126 112 -14 process_timer_stats 449 435 -14 match_fstype 111 97 -14 do_ipaddr 1344 1330 -14 open_list_and_close 359 343 -16 get_header_tar 1795 1779 -16 prepend_new_eth_table 340 323 -17 fsck_main 1811 1794 -17 find_iface_state 56 38 -18 dnsd_main 1321 1303 -18 base_device 179 158 -21 find_keyword 104 82 -22 handle_incoming_and_exit 2785 2762 -23 parse_and_put_prompt 774 746 -28 modinfo 347 317 -30 find_action 204 171 -33 update_passwd 1470 1436 -34 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 0/49 up/down: 18/-540) Total: -522 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-21modinfo: fix fallout from basename removalDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2014-07-04modinfo: fix module parsing with kernel >= 2.6.37David Marchand
display() function returns the length of the value we are displaying + 1. As a consequence, if we have field=value\0field=value\0field=value in the binary, then the second occurence will be skipped as ptr will miss the first character of the following field. Example trying to list aliases from ixgbe.ko on a 3.2 kernel. - In the module we have: alias=pci:v00008086d00001560sv*sd*bc*sc*i*\0 alias=pci:v00008086d0000154Asv*sd*bc*sc*i*\0 alias=pci:v00008086d00001557sv*sd*bc*sc*i*\0 alias=pci:v00008086d0000154Fsv*sd*bc*sc*i*\0 alias=pci:v00008086d0000154Dsv*sd*bc*sc*i*\0 ... - Using modinfo -F alias ixgbe returns: alias: pci:v00008086d00001560sv*sd*bc*sc*i* alias: pci:v00008086d00001557sv*sd*bc*sc*i* alias: pci:v00008086d0000154Dsv*sd*bc*sc*i* ... This problem appeared with kernel commit "modules: no need to align .modinfo strings" b6472776816af1ed52848c93d26e3edb3b17adab in 2.6.37. Fix this by not trusting display() return value but increment ptr by strlen(ptr) (the same way as depmod.c does). Signed-off-by: David Marchand <david.marchand@6wind.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2012-06-12modinfo: match more standard module fields and fix version fieldTanguy Pruvot
Previously, -F version could match the srcversion= string. before : ~ # modinfo -F version tiwlan_drv version: 6.1.2012.05.29 version: 533BB7E5866E52F63B9ACCB version: 0x%x, oui=0x%x, 0x%x, 0x%x version: 0x%x ~ # modinfo tiwlan_drv filename: tiwlan_drv.ko author: Texas Instruments Inc - Retouched by CyanogenDefy license: GPL vermagic: 2.6.32.9 preempt mod_unload ARMv7 parm: g_sdio_debug_level:debug level depends: now : ~ # modinfo -F version tiwlan_drv version: 6.1.2012.05.29 ~ # modinfo tiwlan_drv filename: tiwlan_drv.ko license: GPL author: Texas Instruments Inc - Retouched by CyanogenDefy version: 6.1.2012.05.29 srcversion: 533BB7E5866E52F63B9ACCB depends: uts_release: 2.6.32.9-g306944c vermagic: 2.6.32.9 preempt mod_unload ARMv7 parm: g_sdio_debug_level:debug level This patch also add support for the old "-n" and some other helpers Change-Id: Icb4e9ca513cbce46b075a6f038799a7a19fb7e22 Signed-off-by: Tanguy Pruvot <tanguy.pruvot@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-10-30modinfo: make it select PLATFORM_LINUX. Closes 4411Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-06-05*: remove "Options:" string from help textsDenys Vlasenko
function old new delta packed_usage 28706 28623 -83 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-02-15modinfo: trivial optimizationsDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-02-15modinfo: show firmware and depends fieldsLauri Kasanen
Signed-off-by: Lauri Kasanen <curaga@operamail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2011-01-18mass removal of underscores from _BB_DIR_foo and _BB_SUID_fooDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-08-16*: make GNU licensing statement forms more regularDenys Vlasenko
This change retains "or later" state! No licensing _changes_ here, only form is adjusted (article, space between "GPL" and "v2" and so on). Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-06-27modinfo: support relative paths in modules.depLauri Kasanen
function old new delta modinfo 272 329 +57 modinfo_main 325 344 +19 Signed-off-by: Lauri Kasanen <curaga@operamail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-06-09modinfo: needs modutils.oDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2010-06-06modinfo: new appletPascal Bellard
function old new delta modinfo_main - 307 +307 modinfo - 280 +280 packed_usage 27037 27131 +94 display - 74 +74 static.shortcuts - 24 +24 applet_names 2254 2262 +8 applet_main 1324 1328 +4 applet_nameofs 662 664 +2 ------------------------------------------------------------------------------ (add/remove: 5/0 grow/shrink: 4/0 up/down: 793/0) Total: 793 bytes Signed-off-by: Pascal Bellard <pascal.bellard@ads-lu.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>