Messages in this thread | | | Date | Tue, 20 Dec 2005 10:08:07 -0800 (PST) | From | Linus Torvalds <> | Subject | Re: [PATCH rc6] block: Fix CDROMEJECT to work in more cases |
| |
On Tue, 20 Dec 2005, Jens Axboe wrote: > > WRITEs cannot have length 0, and READs cannot as well. Since it's just > one bit for direction, those are the rules.
Jens, your logic doesn't make sense.
There clearly _are_ commands with a 0 data-length.
And commands _have_ to be either READ or WRITE. We don't have a choice. ll_rw_block: blk_get_request() even has a BIG_ON() that enforces that.
So claiming that reads and writes cannot have zere data-length is INSANE.
So reads and writes HAVE to accept a zero data length. End of story. If there is some path in the SCSI layer that refuses it, that part must be fixed, or you have to add a new "NONE" (and perhaps "BOTH") direction.
Linus - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |