Managing and Developing Dynamically Loadable Kernel Modules

Managing and Developing Dynamically Loadable Kernel Modules
Developing Dynamically Loadable Kernel Modules
Chapter 12526
file and other configuration files needed to install the module into the
system.
“Initializing and Terminating DLKM Modules” on page 538 describes
the steps that each type of DLKM module must take to initialize and
terminate itself.
“DLKM Module Development Process” on page 551 describes the
iterative processes and procedures that are of specific interest to
developers of new DLKM modules, such as writing the module, and
installing, testing and debugging it. Other procedures useful in the
development process, such as configuring, registering, and loading a
DLKM, are covered in the section “Managing Dynamically Loadable
Kernel Modules” on page 493 of this chapter.
“Sample DLKM WSIO Class Driver” on page 558, presents a
complete skeleton of a DLKM WSIO (Workstation Input/Output)
class driver in HP-UX.
Overview of Boot Time Loading
Dynamically Loadable Kernel Modules were introduced in HP-UX 11.0.
This feature allowed kernel modules to be loaded or unloaded
dynamically without rebooting. However, loading and unloading of
modules was allowed only during system run-time. This prevented very
low-level kernel functions that are needed at early system boot from
being implemented as DLKM modules.
With this release the Boot Time Loading feature eliminates this
limitation for the Itanium-based platform. The HP-UX boot process can
be divided into two parts, the architecture-dependent part and the
architecture-independent part. The architecture-dependent part is
referred to as the boot phase 1, and the architecture-independent part is
referred to as boot phase 2. More precisely, boot phase 1 is the time when
the kernel does not use pfdat (virtual memory page management table)
based memory allocation system, and boot phase 2 is the time when the
kernel begins to use the regular virtual memory allocation system that is
used during system run-time
When you configure a module to be loaded during boot time, it is
necessary to specify the phase in which you want to load the module. A
module can specify two kinds of loading phases: “configured loading
phase” and “supported loading phase.”
The supported loading phase specifies the capability of a module to be