[Stgt-devel] ibmvio is slow

FUJITA Tomonori tomof
Wed Aug 15 05:11:37 CEST 2007


On Tue, 14 Aug 2007 21:20:54 +0200
Bastian Blank <waldi at berlios.de> wrote:

> On Tue, Aug 14, 2007 at 08:36:02PM +0200, Bastian Blank wrote:
> > There is only lvm between it. This looks like some sort of read-ahead
> > for the data, which should not happen for write requests. I tried to dig
> > a little bit in the block code but was not able to found the cause.
> 
> I found something:
> 
> scsi_host_get_command
> | int write = (data_dir == DMA_TO_DEVICE);
> 
> According to ibmvstgt, this is a write to the scsi device, aka data
> transfer to this system.
> 
> | rq = blk_get_request(shost->uspace_req_q, !write, gfp_mask);
> 
> The second parameter should be READ or WRITE, not true/false and it
> seems to have the wrong direction.

No. The code is correct.

READ is zero so it works though we can do better here.

The in-kernel ibmvio driver (ibmvstgt) uses the block layer functions
in reverse. You can try your correct direction to see data corruption.



More information about the stgt mailing list