DDI 8 provides facilities that enable one driver to invoke another driver's entry points. Layered drivers, such as volume managers, require this functionality. In earlier releases of the operating system, drivers implemented this functionality by stepping outside the bounds of DDI.
The DDI 8 implementation is based on an opaque ``channel handle''. The driver whose entry points will be called creates a channel handle for itself with the drv_open(D3) function, then registers itself and its entry points by calling the drv_attach(D3) function. The corresponding drv_detach(D3) function can be called to deregister the driver when appropriate.
The layered driver can then access that driver's entry points using the do_biostart(D3), do_devinfo(D3), do_ioctl(D3), do_drvctl(D3), and uiobuf(D3) functions.
In DDI 8, this functionality is available only for SDI and non-SDI storage drivers.
SDI 4 provides the following structures and functions for use in layered drivers.
SDI devices are managed with the following:
SDI drivers are managed with the following:
SDI also provides functions for the special buf(D4) manipulation that is required for layered drivers:
b_iodoneand (optionally) the
b_blknomembers of the buf structure.
b_blknomember of the buf structure.