SG_SET_KEEP_ORPHAN (and _GET_)

The Linux SCSI Generic (sg) HOWTO
Prev | Chapter 8. Ioctl()s | Next

# 8.6. SG_SET_KEEP_ORPHAN (and _GET_)

SG_SET_KEEP_ORPHAN 0x2287 [_GET_ 0x2288]. These ioctl()s allow the setting and reading of the "keep_orphan" flag. This controls what happens to the request associated with a SG_IO ioctl() that is interrupted (i.e. errno is EINTR). The default action is to drop the response as soon as it is received. This corresponds to the "keep_orphan" flag being 0. When the "keep_orphan" flag is 1 then the response is transformed in such a way that it can be fetched by a read(). This is the only circumstance in which a request sent by a SG_IO ioctl() can have the associated response fetched by a read().

Prev | Home | Next
SG_EMULATED_HOST | Up | SG_SET_FORCE_LOW_DMA