*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->HP-UX 11i man pages -> modload (2)              


 modload(2)                                                       modload(2)

 NAME    [Toc]    [Back]
      modload - load kernel modules on demand

 SYNOPSIS    [Toc]    [Back]
      #include <sys/mod.h>
      int modload(char *pathname);

 DESCRIPTION    [Toc]    [Back]
      modload allows processes with appropriate privilege to demand-load a
      kernel module into the running kernel.  The module must be of a
      supported type and must have been registered via kcmodule(1M) before
      it can be loaded.

      The module to be loaded is specified by pathname.  pathname may be
      either a module name or an absolute pathname. If pathname is a module
      name, a list of directories specified by modpath is searched for a
      match. If pathname is absolute, only pathname is used to access the
      object file. The file must be an ELF64 relocatable object file.

    Notes    [Toc]    [Back]
      modload is currently implemented as a macro.

 RETURN VALUE    [Toc]    [Back]
      On successful completion, modload returns a module identifier that can
      be passed to moduload or modstat.  On failure it returns -1 and sets
      errno to identify the error.

 ERRORS    [Toc]    [Back]
      modload fails if one or more of the following are true:

      [EACCES]        A component of pathname denies search permission.

      [ENOENT]        The file named by pathname does not exist.

      [ENOREG]        Module being loaded is not currently registered.

      [EINVAL]        The file named by pathname is not appropriately preconfigured
 or has invalid dependency on other modules.

      [EPERM]         The calling process does not have appropriate

      [ERELOC]        A relocation error occurred during the attempt to load
                      the module, or the module references symbols not
                      defined in the running kernel, or the module
                      references symbols in another loadable module but it
                      did not declare its dependence on this module in its
                      module metadata.

      [ENAMETOOLONG]  pathname is more than MAXPATHLEN characters long.

 Hewlett-Packard Company            - 1 -   HP-UX 11i Version 2: August 2003

 modload(2)                                                       modload(2)

      [EBADVER]       The module wrapper has an incorrect version number.

      [ENOSYS]        The Dynamically Loadable Kernel Module feature is not

 SEE ALSO    [Toc]    [Back]
      kcmodule(1M), modstat(2), moduload(2).

 Hewlett-Packard Company            - 2 -   HP-UX 11i Version 2: August 2003
[ Back ]
 Similar pages
Name OS Title
ml IRIX load dynamic kernel modules
modules Linux kernel modules to load at boot time
AutoLoader IRIX load subroutines only on demand
SelfLoader IRIX load functions only on demand
IO IRIX load various IO modules
autouse IRIX postpone load of modules until a function is used
moduload HP-UX unload a kernel module on demand
lkm OpenBSD Loadable Kernel Modules interface
kcmodule HP-UX manage kernel modules and subsystems
mload IRIX dynamically loadable kernel modules
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service