Specifications

System Macros Invoked by Drivers
DDTAB
[cloneducb=+IOC$RETURN]
Address of routine called when a UCB is cloned by the $ASSIGN system service.
Description
The DDTAB macro creates a driver dispatch table (DDT). The table has a label
of devnam$DDT. Just preceding the table, DDTAB generates the driver code
program section with the following statement:
.PSECT $$$115_DRIVER
The DDTAB macro writes the address of the universal executive routine vector
IOC$RETURN into routine address fields of the DDT that are not supplied in the
macro invocation (with the exception of the mntver argument). IOC$RETURN
simply executes an RSB instruction.
A plus sign (+) precedes the address of any specified routine that is part of the
operating system: that is, it is an address that is not relative to the location of
the driver. No plus sign precedes the address of a routine (such as a start-I/O
routine) that is part of the driver module.
Example
DDTAB - ;DDT-creation macro
DEVNAM=XX, - ;Name of device
START=XX_START,- ;Start-I/O routine
FUNCTB=XX_FUNCTABLE,- ;FDT address
CANCEL=+IOC$CANCELIO,- ;Cancel-I/O routine
REGDMP=XX_REGDUMP,- ;Register-dumping routine
DIAGBF=<<15*4>+<<3+5+1>*4>>,- ;Diagnostic buffer size
ERLGBF=<<15*4>+<1*4>+<EMB$L_DV_REGSAV>> ;Error message buffer size
This code excerpt uses the DDTAB macro to create a driver dispatch table for the
XX device type. Note that because the cancel-I/O routine is part of the operating
system, its address is preceded by a plus sign (+).
2–13