| Previous | Next |
| kIOReturnPortExists | kIOReturnNoInterrupt |
kIOReturnCannotWire
Why I/O buffers may need to be wired
kIOReturnCannotWire means that the operation could not wire down physical memory. IOKit documentation explains that memory used for an I/O transfer may need to remain resident and not be relocated while a device accesses it. This is a transfer-preparation condition, not merely a complaint about ordinary heap availability.
The request’s address range, segment layout, memory-descriptor lifetime, and timing can matter. It is distinct from kIOReturnNoMemory, which labels an allocation failure, and from kIOReturnNotAligned, which identifies an alignment error. A retry without releasing prior descriptors or reducing outstanding work can repeat the same constraint.
What to inspect
- Record the buffer size, memory ownership, descriptor type, direction, segment count, and phase at which preparation failed.
- Verify that every prepare-like operation is paired with its required completion or release action.
- Test a smaller, bounded request and avoid holding locks around operations that can block on memory preparation.
- Use the documented IOKit memory-descriptor path rather than assuming a raw user-space pointer is directly usable for device I/O.
References
- Apple XNU source: IOReturn.h
- Apple: Managing data in IOKit
- Apple: Introduction to IOKit Fundamentals
Looking for a different code? Search another status or error code.