linux-old/README.modules
<<
>>
Prefs
   1This file describes the strategy for dynamically loadable modules
   2in the Linux kernel. This is not a technical description on
   3the internals of module, but mostly a sample of how to compile
   4and use modules.
   5
   6In this kernel you also have a possibility to create modules that are
   7less dependent on the kernel version.  This option can be selected
   8during "make config", by enabling CONFIG_MODVERSIONS.
   9Note: If you enable CONFIG_MODVERSIONS, you will need some utilities
  10      from the latest module support package: "modules-1.1.8*.tar.gz"!
  11
  12Anyway, your first step is to compile the kernel, as explained in the
  13file README.  It generally goes like:
  14
  15        make config
  16        make dep
  17        make clean
  18        make zImage or make zlilo
  19
  20In "make config", you select what you want to include in the kernel.
  21You will generally select the minimal set that is needed to boot:
  22
  23        The filesystem of your root partition
  24        A scsi driver, but see below for a list of SCSI modules!
  25        Normal hard drive support
  26        Net support (CONFIG_NET)
  27        TCP/IP support (CONFIG_INET), but no drivers!
  28
  29        plus those things that you just can't live without...
  30
  31What has been left out is generally loadable as a modules.
  32The set of modules is rapidly increasing, but so far these are known:
  33
  34        Most filesystems: minix, xiafs, msdos, umsdos, sysv, isofs
  35
  36        Some SCSI drivers: aha1542, in2000
  37
  38        Some ethernet drivers:
  39                plip, slip, dummy,
  40                de600, de620
  41                3c501, 3c509
  42                eexpress, depca,
  43                ewrk3, apricot
  44
  45        Some misc modules:
  46                lp: line printer
  47                binfmt_elf: elf loader
  48                sbpcd:     CDROM-driver for Matsushita,Panasonic CR52x,CR56x
  49                sonycd535: CDROM-driver for Sony CD535
  50                aztcd:     CDROM-driver for Aztech,Orchid,Okano,Wearnes
  51
  52When you have made the kernel, you create the modules by doing:
  53
  54        make modules
  55
  56This will compile all modules and update the modules directory.
  57In this directory you will then find a bunch of symbolic links,
  58pointing to the various object files in the kernel tree.
  59
  60As soon as you have rebooted the newly made kernel, you can install
  61and remove modules at will with the utilities: "insmod" and "rmmod".
  62
  63
  64Now, after you have made all modules, you can also do:
  65
  66        make modules_install
  67
  68This will copy all newly made modules into subdirectories under
  69"/lib/modules/kernel_release/", where "kernel_release" is something
  70like 1.1.83, or whatever the current kernel version is...
  71
  72
  73Nifty features:
  74
  75If you have installed the utilities from "modules-1.1.8*.tar.gz",
  76you will have access to two new utilities: "modprobe" and "depmod"
  77
  78Using the modprobe utility, you can load any module like this:
  79
  80        /sbin/modprobe module
  81
  82without paying much attention to which kernel you are running.
  83To use modprobe successfully, you generally place the following
  84command in your /etc/rc.d/rc.S script.
  85
  86        /sbin/depmod -a
  87
  88This computes the dependencies between the different modules.
  89Then if you do, for example
  90
  91        /sbin/modprobe umsdos
  92
  93you will automatically load _both_ the msdos and umsdos modules,
  94since umsdos runs piggyback on msdos.
  95
  96
  97Written by:
  98        Jacques Gelinas <jacques@solucorp.qc.ca>
  99        Bjorn Ekwall <bj0rn@blox.se>
 100
lxr.linux.no kindly hosted by Redpill Linpro AS, provider of Linux consulting and operations services since 1995.