Skip to content

Commit

Permalink
Documentation: replace install commands with softdeps
Browse files Browse the repository at this point in the history
Install commands should not be used to specify soft dependencies among
modules. When loading modules it's much better to have a softdep that
modprobe knows what's being done than having to fork/exec another
instance of modprobe to load the other module.

By using a softdep user has also an option to remove the dependencies
when removing the module (and if its refcount dropped to 0)

Signed-off-by: Lucas De Marchi <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Lucas De Marchi authored and torvalds committed Mar 30, 2012
1 parent 970e248 commit 78286cd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions Documentation/networking/bonding.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1822,8 +1822,7 @@ modules.conf manual page.
In this case, the following can be added to config files in
/etc/modprobe.d/ as:

install bonding /sbin/modprobe tg3; /sbin/modprobe e1000;
/sbin/modprobe --ignore-install bonding
softdep bonding pre: tg3 e1000

This will load tg3 and e1000 modules before loading the bonding one.
Full documentation on this can be found in the modprobe.d and modprobe
Expand Down
4 changes: 2 additions & 2 deletions Documentation/sound/oss/AudioExcelDSP16
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ Loading MSS and OPL3 needs to pre load the aedsp16 module to set up correctly
the sound card. Installation dependencies must be written in configuration
files under /etc/modprobe.d/ directory:

install ad1848 /sbin/modprobe aedsp16 && /sbin/modprobe -i ad1848
install opl3 /sbin/modprobe aedsp16 && /sbin/modprobe -i opl3
softdep ad1848 pre: aedsp16
softdep opl3 pre: aedsp16

Then you must load the sound modules stack in this order:
sound -> aedsp16 -> [ ad1848, opl3 ]
Expand Down
2 changes: 1 addition & 1 deletion Documentation/sound/oss/README.modules
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ options adlib_card io=0x388 # FM synthesizer
Alternatively, if you have compiled in kernel level ISAPnP support:

alias char-major-14 sb
post-install sb /sbin/modprobe "-k" "adlib_card"
softdep sb post: adlib_card
options adlib_card io=0x388

The effect of this is that the sound driver and all necessary bits and
Expand Down

0 comments on commit 78286cd

Please sign in to comment.