Skip Navigation Links | |
Exit Print View | |
Writing Device Drivers Oracle Solaris 11.1 Information Library |
Part I Designing Device Drivers for the Oracle Solaris Platform
1. Overview of Oracle Solaris Device Drivers
2. Oracle Solaris Kernel and Device Tree
5. Managing Events and Queueing Tasks
7. Device Access: Programmed I/O
10. Mapping Device and Kernel Memory
13. Hardening Oracle Solaris Drivers
14. Layered Driver Interface (LDI)
Part II Designing Specific Kinds of Device Drivers
15. Drivers for Character Devices
18. SCSI Host Bus Adapter Drivers
19. Drivers for Network Devices
Part III Building a Device Driver
22. Compiling, Loading, Packaging, and Testing Drivers
23. Debugging, Testing, and Tuning Device Drivers
24. Recommended Coding Practices
B. Summary of Oracle Solaris DDI/DKI Services
Device Information Tree Node (dev_info_t) Functions
Device Software State Functions
Memory Allocation and Deallocation Functions
Kernel Thread Control and Synchronization Functions
Task Queue Management Functions
Direct Memory Access (DMA) Functions
User Process Information Functions
User Application Kernel and Device Access Functions
Kernel Logging and Printing Functions
Resource Map Management Functions
C. Making a Device Driver 64-Bit Ready
The programmed I/O functions are:
Return the number of register sets a device has
Return the size of a device's register
Set up a mapping for a register address space
Free a previously mapped register address space
Copy data from one device register to another device register
Zero fill the device
Check data access handle
Read 8-bit data from mapped memory, device register, or DMA memory
Read 16-bit data from mapped memory, device register, or DMA memory
Read 32-bit data from mapped memory, device register, or DMA memory
Read 64-bit data from mapped memory, device register, or DMA memory
Write 8-bit data to mapped memory, device register, or DMA memory
Write 16-bit data to mapped memory, device register, or DMA memory
Write 32-bit data to mapped memory, device register, or DMA memory
Write 64-bit data to mapped memory, device register, or DMA memory
Read multiple 8-bit data from mapped memory, device register, or DMA memory
Read multiple 16-bit data from mapped memory, device register, or DMA memory
Read multiple 32-bit data from mapped memory, device register, or DMA memory
Read multiple 64-bit data from mapped memory, device register, or DMA memory
Write multiple 8-bit data to mapped memory, device register, or DMA memory
Write multiple 16-bit data to mapped memory, device register, or DMA memory
Write multiple 32-bit data to mapped memory, device register, or DMA memory
Write multiple 64-bit data to mapped memory, device register, or DMA memory
Cautiously read an 8-bit value from a location
Cautiously read a 16-bit value from a location
Cautiously read a 32-bit value from a location
Cautiously read a 64-bit value from a location
Cautiously write an 8-bit value to a location
Cautiously write a 16-bit value to a location
Cautiously write a 32-bit value to a location
Cautiously write a 64-bit value to a location
The general programmed I/O functions listed above can always be used rather than the mem, io, and pci_config functions that follow. However, the following functions can be used as alternatives in cases where the type of access is known at compile time.
Read 8-bit data from a mapped device register in I/O space
Read 16-bit data from a mapped device register in I/O space
Read 32-bit data from a mapped device register in I/O space
Write 8-bit data to a mapped device register in I/O space
Write 16-bit data to a mapped device register in I/O space
Write 32-bit data to a mapped device register in I/O space
Read multiple 8-bit data from a mapped device register in I/O space
Read multiple 16-bit data from a mapped device register in I/O space
Read multiple 32-bit data from a mapped device register in I/O space
Write multiple 8-bit data to a mapped device register in I/O space
Write multiple 16-bit data to a mapped device register in I/O space
Write multiple 32-bit data to a mapped device register in I/O space
Read 8-bit data from a mapped device in memory space or DMA memory
Read 16-bit data from a mapped device in memory space or DMA memory
Read 32-bit data from a mapped device in memory space or DMA memory
Read 64-bit data from a mapped device in memory space or DMA memory
Write 8-bit data to a mapped device in memory space or DMA memory
Write 16-bit data to a mapped device in memory space or DMA memory
Write 32-bit data to a mapped device in memory space or DMA memory
Write 64-bit data to a mapped device in memory space or DMA memory
Read multiple 8-bit data from a mapped device in memory space or DMA memory
Read multiple 16-bit data from a mapped device in memory space or DMA memory
Read multiple 32-bit data from a mapped device in memory space or DMA memory
Read multiple 64-bit data from a mapped device in memory space or DMA memory
Write multiple 8-bit data to a mapped device in memory space or DMA memory
Write multiple 16-bit data to a mapped device in memory space or DMA memory
Write multiple 32-bit data to a mapped device in memory space or DMA memory
Write multiple 64-bit data to a mapped device in memory space or DMA memory
Set up access to PCI Local Bus Configuration space
Tear down access to PCI Local Bus Configuration space
Read 8-bit data from the PCI Local Bus Configuration space
Read 16-bit data from the PCI Local Bus Configuration space
Read 32-bit data from the PCI Local Bus Configuration space
Read 64-bit data from the PCI Local Bus Configuration space
Write 8-bit data to the PCI Local Bus Configuration space
Write 16-bit data to the PCI Local Bus Configuration space
Write 32-bit data to the PCI Local Bus Configuration space
Write 64-bit data to the PCI Local Bus Configuration space
Table B-4 Deprecated Programmed I/O Functions
|