android_kernel_samsung_msm8976/arch/um
Tejun Heo 47526903fe ubd: fix incorrect sector handling during request restart
Commit f81f2f7c (ubd: drop unnecessary rq->sector manipulation)
dropped request->sector manipulation in preparation for global request
handling cleanup; unfortunately, it incorrectly assumed that the
updated sector wasn't being used.

ubd tries to issue as many requests as possible to io_thread.  When
issuing fails due to memory pressure or other reasons, the device is
put on the restart list and issuing stops.  On IO completion, devices
on the restart list are scanned and IO issuing is restarted.

ubd issues IOs sg-by-sg and issuing can be stopped in the middle of a
request, so each device on the restart queue needs to remember where
to restart in its current request.  ubd needs to keep track of the
issue position itself because,

* blk_rq_pos(req) is now updated by the block layer to keep track of
  _completion_ position.

* Multiple io_req's for the current request may be in flight, so it's
  difficult to tell where blk_rq_pos(req) currently is.

Add ubd->rq_pos to keep track of the issue position and use it to
correctly restart io_req issue.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Richard Weinberger <richard@nod.at>
Tested-by: Richard Weinberger <richard@nod.at>
Tested-by: Chris Frey <cdfrey@foursquare.net>
Cc: stable@kernel.org
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
2010-10-15 12:56:21 +02:00
..
drivers ubd: fix incorrect sector handling during request restart 2010-10-15 12:56:21 +02:00
include uml: fix compile error in dma_get_cache_alignment() 2010-08-20 09:34:55 -07:00
kernel uml: fix compile warning 2010-09-22 17:22:39 -07:00
os-Linux Deal with missing exports for hostfs 2010-08-09 16:47:25 -04:00
scripts
sys-i386 Merge branch 'master' into for-next 2010-04-23 02:08:44 +02:00
sys-ia64 uml: remove useless comments 2009-04-01 08:59:17 -07:00
sys-ppc elf: kill USE_ELF_CORE_DUMP 2009-12-16 07:20:12 -08:00
sys-x86_64 UML: Fix compiler warning due to missing task_struct declaration 2010-04-21 01:43:03 +02:00
.gitignore um: tell git to ignore generated files 2010-03-06 11:26:28 -08:00
defconfig UML: update defconfig 2008-02-23 17:12:13 -08:00
Kconfig.char sound: make OSS sound core optional 2008-08-29 10:06:21 +02:00
Kconfig.common time: Kill off CONFIG_GENERIC_TIME 2010-07-27 12:40:54 +02:00
Kconfig.debug uml: GPROF needs to depend on FRAME_POINTER 2008-02-05 09:44:25 -08:00
Kconfig.net uml: fix URLs in Kconfig and help strings 2008-02-05 09:44:25 -08:00
Kconfig.rest uml: kill a kconfig warning 2009-04-21 13:41:50 -07:00
Kconfig.um x86, um: get rid of arch/um/Kconfig.arch 2008-10-22 22:55:23 -07:00
Kconfig.x86 x86, um: get rid of arch/um/Kconfig.arch 2008-10-22 22:55:23 -07:00
Makefile kbuild: move asm-offsets.h to include/generated 2009-12-12 13:08:14 +01:00
Makefile-i386 [UML] fix gcc ICEs and unresolved externs 2008-07-07 10:53:10 -07:00
Makefile-ia64
Makefile-os-Linux x86, um: get rid of arch/um/os symlink 2008-10-22 22:55:22 -07:00
Makefile-ppc
Makefile-skas
Makefile-x86_64 [UML] fix gcc ICEs and unresolved externs 2008-07-07 10:53:10 -07:00