Moving device power management out of drivers
Master of Science
Device drivers are notorious for development effort, faults and security exploits. A widely practiced strategy toward simpler drivers is to move functions out of drivers. Power management (PM), an important function provided by drivers, however, has long resisted this strategy. Today, device drivers track device usage and implement suspend/resume functions to save and restore device context necessary for power management. This work presents our attempt to move PM context management out of drivers and realize it in a device-independent manner. Our key idea is the rule of representation: separate device-specific knowledge from the logic of PM context management. We design and prototype a central PM context manager that provides device-independent suspend/resume logic for devices. Instead of supplying code, device vendors only need to provide device-specific PM knowledge in data structures to drive the device-independent logic. Our evaluation on an open-source embedded system (BeagleBone Black) shows that our design is able to move most of suspend/resume code out of device drivers. And we also demonstrate that using the central PM context manager to suspend/resume devices can achieve the same level of power savings as the original driver-based PM context management.
device driver; power management; rule of representation