NAME
modinfo - 显示当前内核模块信息
总览
modinfo [ options ] <module_file>
描述
modinfo 工具软件用来对内核模块的目标文件 module_file 进行测试并打印输出相关信息。
选项
- -a, --author
- 显示模块的开发人员
- -d, --description
- 显示此模块的描述说明
- -fformat_string, --format format_string
- 由用户定义任意格式字符串,可以通过该字符串从内核模块 module_file 的 ELF 段中获得该模块相应的值,其中包含该模块的信息。替换由一个百分号后跟一个由花括号括起来的标签名组成。
- -p, --parameters
- 显示模块所支持的有类型的参数
- -h, --help
- 显示帮助信息
- -V, --version
- 显示 modinfo的版本信息
参见
insmod(8), modprobe(8), depmod(8), rmmod(8), lsmod(8), ksyms(8), modules(2)
#p#
NAME
modinfo --- program to show information about a Linux Kernel module
SYNOPSIS
modinfo [-0] [-F field] [modulename|filename ...]
modinfo -V
modinfo -h
DESCRIPTION
modinfo extracts information the Linux Kernel modules given on the command line. If the module name is not a filename, then the /lib/modules/version directory is searched, as done by modprobe(8).
modinfo by default lists each attribute of the module in form fieldname : value, for easy reading. The filename is listed the same way (although it's not really an attribute).
This version of modinfo can understand modules of any Linux Kernel architecture.
OPTIONS
- -V --version
- Print the modinfo version. Note BACKWARDS COMPATIBILITY below: you might be printing the version of modinfo.old.
- -F --field
- Only print this field value, one per line. This is most useful for scripts. Field names are case-insenitive. Common fields (which may not be in every module) include author, description, license, param, depends, and alias. There are often multiple param, alias and depends fields. The special field filename lists the filename of the module.
- -0 --null
- Use the ASCII zero character to separate field values, instead of a new line. This is useful for scripts, since a new line can theoretically appear inside a field.
- -a -d -l -p -n
- These are shortcuts for author, description, license. param and filename respectively, to ease the transition from the old modutils modinfo.
BACKWARDS COMPATIBILITY
This version of modinfo is for kernel modules 2.5.48 and above. If it detects a kernel with support for old-style modules, it will attempt to run modprobe.old in its place, so it is completely transparent to the user.
Note that the output of this version of modinfo is simpler and more regular than the older version: scripts attempting to use the default output may get confused with complex fields.
You can force the new modinfo to always be used, by setting the NEW_MODINFO environment variable.
COPYRIGHT
This manual page Copyright 2003, Rusty Russell, IBM Corporation.
SEE ALSO
modprobe(8), modinfo.old(8)