android_kernel_xiaomi_sm8350/drivers/block
Jens Axboe 9e973e64ac xen/blkfront: use blk_rq_map_sg to generate ring entries
On occasion, the request will apparently have more segments than we
fit into the ring. Jens says:

> The second problem is that the block layer then appears to create one
> too many segments, but from the dump it has rq->nr_phys_segments ==
> BLKIF_MAX_SEGMENTS_PER_REQUEST. I suspect the latter is due to
> xen-blkfront not handling the merging on its own. It should check that
> the new page doesn't form part of the previous page. The
> rq_for_each_segment() iterates all single bits in the request, not dma
> segments. The "easiest" way to do this is to call blk_rq_map_sg() and
> then iterate the mapped sg list. That will give you what you are
> looking for.

> Here's a test patch, compiles but otherwise untested. I spent more
> time figuring out how to enable XEN than to code it up, so YMMV!
> Probably the sg list wants to be put inside the ring and only
> initialized on allocation, then you can get rid of the sg on stack and
> sg_init_table() loop call in the function. I'll leave that, and the
> testing, to you.

[Moved sg array into info structure, and initialize once. -J]

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
2009-02-26 10:45:48 +01:00
..
aoe aoe: ignore vendor extension AoE responses 2009-02-18 15:37:53 -08:00
paride paride/pg.c: xs(): &&/|| confusion 2009-02-18 10:32:01 +01:00
amiflop.c m68k: amiflop - Get rid of sleep_on calls 2009-01-12 20:56:33 +01:00
ataflop.c m68k: atari - Rename "mfp" to "st_mfp" 2009-02-22 09:23:02 -08:00
brd.c
cciss_cmd.h cciss: switch to using hlist for command list management 2008-12-29 08:28:43 +01:00
cciss_scsi.c
cciss_scsi.h
cciss.c cciss: shorten 30s timeout on controller reset 2009-02-26 10:45:48 +01:00
cciss.h cciss: switch to using hlist for command list management 2008-12-29 08:28:43 +01:00
cpqarray.c
cpqarray.h
cryptoloop.c
DAC960.c
DAC960.h
floppy.c floppy: request and release only the ports we actually use 2009-02-18 15:37:55 -08:00
hd.c
ida_cmd.h
ida_ioctl.h
Kconfig
loop.c loop: Do not call loop_unplug for not configured loop device. 2008-12-29 08:29:52 +01:00
Makefile
nbd.c nbd: fix I/O hang on disconnected nbds 2009-02-11 14:25:37 -08:00
pktcdvd.c
ps3disk.c powerpc/ps3: Printing fixups for l64 to ll64 conversion drivers/block 2009-01-16 16:15:13 +11:00
smart1,2.h
sunvdc.c sparc64: Fix unsigned long long warnings in drivers. 2009-01-06 13:20:38 -08:00
swim3.c
sx8.c
ub.c USB: change interface to usb_lock_device_for_reset() 2009-01-07 09:59:52 -08:00
umem.c
umem.h
viodasd.c
virtio_blk.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus 2008-12-30 17:37:25 -08:00
xd.c
xd.h
xen-blkfront.c xen/blkfront: use blk_rq_map_sg to generate ring entries 2009-02-26 10:45:48 +01:00
xsysace.c powerpc/xsysace: add compatible string for non-ipcore instance 2009-01-09 15:49:06 -07:00
z2ram.c