The use of driver services is essential to a driver's portability to future Mac OS releases. These are the programming interfaces for device drivers that are guaranteed to be common across Mac OS system versions. They consist of
When writing a device driver, never use Toolbox API calls. Doing so will prevent your device driver from being compatible with future Mac OS releases. Instead, use the functionality provided by the corresponding drivers services APIs, for example when working with USB devices, use the USB Services Library (USL) and USB Manager. The driver services calls let you deal more naturally with device driver issues that the Toolbox API does, because the Toolbox is intended for applications.
You can ensure compliance with the foregoing rule by not letting your driver link with application libraries such as InterfaceLib, MathLib, StdCLib, and so on. Any necessary Toolbox functionality, such as driving a graphical user interface, should be accomplished by separate application-level software on behalf of the device driver.