Re: [PATCH] bsg : Add support for io vectors in bsg

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: James Bottomley <James.Bottomley@...>
Cc: Pete Wyckoff <pw@...>, FUJITA Tomonori <fujita.tomonori@...>, <tomof@...>, <deepakrc@...>, <linux-scsi@...>, <linux-kernel@...>
Date: Friday, January 11, 2008 - 8:16 pm

James Bottomley wrote:

The sg driver's async interface has been pretty stable for
a long time. The sync SG_IO ioctl is built on top of the
async interface. That makes the async interface extremely
well tested.

The write()/read() async interface in sg does have one
problem: when a command is dispatched via a write()
it would be very useful to get back a tag but that
violates write()'s second argument: 'const void * buf'.
That tag could be useful both for identification of the
response and by task management functions.

I was hoping that the 'flags' field in sgv4 could be used
to implement the variants:
     SG_IO_SUBMIT - start a new blk_execute_rq_nowait()
     SG_IO_TEST   - complete and return a previous req
     SG_IO_WAIT   - wait for a req to finish, interruptibly

that way the existing SG_IO ioctl is sufficient.

And if Tomo doesn't want to do it in the bsg driver,
then it could be done it the sg driver.

Doug Gilbert
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] bsg : Add support for io vectors in bsg, Deepak Colluru, (Fri Jan 4, 12:17 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, FUJITA Tomonori, (Sat Jan 5, 1:01 am)
Re: [PATCH] bsg : Add support for io vectors in bsg, Pete Wyckoff, (Tue Jan 8, 6:09 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, FUJITA Tomonori, (Tue Jan 8, 8:11 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, Pete Wyckoff, (Thu Jan 10, 4:43 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, James Bottomley, (Thu Jan 10, 4:55 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, Pete Wyckoff, (Thu Jan 10, 5:46 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, FUJITA Tomonori, (Fri Jan 11, 1:42 am)
Re: [PATCH] bsg : Add support for io vectors in bsg, Mark Rustad, (Thu Jan 10, 6:33 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, James Bottomley, (Thu Jan 10, 5:54 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, Douglas Gilbert, (Fri Jan 11, 8:16 pm)
Re: [PATCH] bsg : Add support for io vectors in bsg, Pete Wyckoff, (Mon Jan 14, 12:18 pm)