In response to http://bugzilla.kernel.org/show_bug.cgi?id=15565 and the fact this capability has been present in bsg for some time, add SG_FLAG_Q_AT_TAIL flag. It has the same binary value as the bsg flag and the define name is the same apart from the leading "B". The semantics are the same, namely to override the default queue at head action of the SCSI midlevel when a low level driver blocks (i.e. when a LLD returns non-zero to a queuecommand() ). Tested with scsi_debug. Changelog - add SG_FLAG_Q_AT_TAIL flag to override default queue at head semantics of the SCSI midlevel queue. Signed-off-by: Douglas Gilbert