Lucas De Marchi | cb48c9b | 2011-12-12 16:41:38 -0200 | [diff] [blame] | 1 | kmod - Linux kernel module handling |
Gustavo Sverzut Barbieri | 91b44c7 | 2011-12-02 21:05:38 -0200 | [diff] [blame] | 2 | |
Lucas De Marchi | 1dd4ff5 | 2014-12-13 11:55:05 -0200 | [diff] [blame] | 3 | Information |
| 4 | =========== |
| 5 | |
Lucas De Marchi | 0d83371 | 2015-06-11 13:59:54 -0300 | [diff] [blame] | 6 | Build status: |
| 7 | [![Build Status](https://semaphoreci.com/api/v1/projects/29d989ba-0f70-4006-be21-550f6692b73b/449920/shields_badge.svg)](https://semaphoreci.com/lucasdemarchi/kmod) |
| 8 | |
Lucas De Marchi | 1dd4ff5 | 2014-12-13 11:55:05 -0200 | [diff] [blame] | 9 | Mailing list: |
| 10 | linux-modules@vger.kernel.org (no subscription needed) |
| 11 | |
Lucas De Marchi | f7ed430 | 2016-05-24 11:45:25 -0300 | [diff] [blame] | 12 | Patchwork: |
| 13 | https://patchwork.kernel.org/project/linux-modules/ |
| 14 | |
Lucas De Marchi | 1dd4ff5 | 2014-12-13 11:55:05 -0200 | [diff] [blame] | 15 | Signed packages: |
| 16 | http://www.kernel.org/pub/linux/utils/kernel/kmod/ |
| 17 | |
| 18 | Git: |
| 19 | git://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git |
| 20 | http://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git |
| 21 | https://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git |
| 22 | |
| 23 | Gitweb: |
| 24 | http://git.kernel.org/?p=utils/kernel/kmod/kmod.git |
| 25 | |
| 26 | Irc: |
| 27 | #kmod on irc.freenode.org |
| 28 | |
| 29 | License: |
| 30 | LGPLv2.1+ for libkmod, testsuite and helper libraries |
| 31 | GPLv2+ for tools/* |
| 32 | |
| 33 | |
Gustavo Sverzut Barbieri | 91b44c7 | 2011-12-02 21:05:38 -0200 | [diff] [blame] | 34 | OVERVIEW |
| 35 | ======== |
| 36 | |
Lucas De Marchi | cb48c9b | 2011-12-12 16:41:38 -0200 | [diff] [blame] | 37 | kmod is a set of tools to handle common tasks with Linux kernel modules like |
| 38 | insert, remove, list, check properties, resolve dependencies and aliases. |
Gustavo Sverzut Barbieri | 91b44c7 | 2011-12-02 21:05:38 -0200 | [diff] [blame] | 39 | |
Lucas De Marchi | cb48c9b | 2011-12-12 16:41:38 -0200 | [diff] [blame] | 40 | These tools are designed on top of libkmod, a library that is shipped with |
| 41 | kmod. See libkmod/README for more details on this library and how to use it. |
| 42 | The aim is to be compatible with tools, configurations and indexes from |
| 43 | module-init-tools project. |
Lucas De Marchi | dd42060 | 2012-01-09 13:15:46 -0200 | [diff] [blame] | 44 | |
| 45 | Compilation and installation |
| 46 | ============================ |
| 47 | |
| 48 | In order to compiler the source code you need following software packages: |
| 49 | - GCC compiler |
| 50 | - GNU C library |
| 51 | |
| 52 | Optional dependencies: |
| 53 | - ZLIB library |
| 54 | - LZMA library |
| 55 | |
| 56 | Typical configuration: |
| 57 | ./configure CFLAGS="-g -O2" --prefix=/usr \ |
| 58 | --sysconfdir=/etc --libdir=/usr/lib |
| 59 | |
| 60 | Configure automatically searches for all required components and packages. |
| 61 | |
| 62 | To compile and install run: |
| 63 | make && make install |
| 64 | |
Lucas De Marchi | 3bf8d4b | 2012-01-12 18:31:10 -0200 | [diff] [blame] | 65 | Hacking |
| 66 | ======= |
| 67 | |
| 68 | Run 'bootstrap' script before configure. If you want to accept the recommended |
Laura Abbott | 4cce76e | 2015-09-28 15:39:10 -0700 | [diff] [blame] | 69 | flags, you just need to run 'bootstrap-configure'. Note that the recommended |
| 70 | flags require cython be installed to compile successfully. |
Lucas De Marchi | 3bf8d4b | 2012-01-12 18:31:10 -0200 | [diff] [blame] | 71 | |
Lucas De Marchi | 314719c | 2012-03-21 22:26:03 -0300 | [diff] [blame] | 72 | Make sure to read the CODING-STYLE file and the other READMEs: libkmod/README |
| 73 | and testsuite/README. |
Lucas De Marchi | 3bf8d4b | 2012-01-12 18:31:10 -0200 | [diff] [blame] | 74 | |
Lucas De Marchi | cd92311 | 2013-07-17 02:26:47 -0300 | [diff] [blame] | 75 | Compatibility with module-init-tools |
| 76 | ==================================== |
| 77 | |
| 78 | kmod replaces module-init-tools, which is end-of-life. Most of its tools are |
| 79 | rewritten on top of libkmod so it can be used as a drop in replacements. |
| 80 | Somethings however were changed. Reasons vary from "the feature was already |
| 81 | long deprecated on module-init-tools" to "it would be too much trouble to |
| 82 | support it". |
| 83 | |
| 84 | There are several features that are being added in kmod, but we don't |
| 85 | keep track of them here. |
| 86 | |
| 87 | modprobe |
| 88 | -------- |
| 89 | |
| 90 | * 'modprobe -l' was marked as deprecated and does not exist anymore |
| 91 | |
| 92 | * 'modprobe -t' is gone, together with 'modprobe -l' |
| 93 | |
| 94 | * modprobe doesn't parse configuration files with names not ending in |
| 95 | '.alias' or '.conf'. modprobe used to warn about these files. |
| 96 | |
| 97 | * modprobe doesn't parse 'config' and 'include' commands in configuration |
| 98 | files. |
| 99 | |
| 100 | * modprobe from m-i-t does not honour softdeps for install commands. E.g.: |
| 101 | config: |
| 102 | |
| 103 | install bli "echo bli" |
| 104 | install bla "echo bla" |
| 105 | softdep bla pre: bli |
| 106 | |
| 107 | With m-i-t, the output of 'modprobe --show-depends bla' will be: |
| 108 | install "echo bla" |
| 109 | |
| 110 | While with kmod: |
| 111 | install "echo bli" |
| 112 | install "echo bla" |
| 113 | |
| 114 | * kmod doesn't dump the configuration as is in the config files. Instead it |
| 115 | dumps the configuration as it was parsed. Therefore, comments and file names |
| 116 | are not dumped, but on the good side we know what the exact configuration |
| 117 | kmod is using. We did this because if we only want to know the entire content |
| 118 | of configuration files, it's enough to use find(1) in modprobe.d directories |
| 119 | |
| 120 | depmod |
| 121 | ------ |
| 122 | |
| 123 | * there's no 'depmod -m' option: legacy modules.*map files are gone |
| 124 | |
| 125 | lsmod |
| 126 | ----- |
| 127 | |
| 128 | * module-init-tools used /proc/modules to parse module info. kmod uses |
| 129 | /sys/module/*, but there's a fallback to /proc/modules if the latter isn't |
| 130 | available |