linux-stable-rt/drivers/scsi
FUJITA Tomonori c982c368bb [SCSI] st: fix mdata->page_order handling
dio transfer always resets mdata->page_order to zero. It breaks
high-order pages previously allocated for non-dio transfer.

This patches adds reserved_page_order to st_buffer structure to save
page order for non-dio transfer.

http://bugzilla.kernel.org/show_bug.cgi?id=14563

When enlarge_buffer() allocates 524288 from 0, st uses six-order page
allocation. So mdata->page_order is 6 and frp_seg is 2.

After that, if st uses dio, sgl_map_user_pages() sets
mdata->page_order to 0 for st_do_scsi(). After that, when we call
normalize_buffer(), it frees only free frp_seg * PAGE_SIZE (2 * 4096)
though we should free frp_seg * PAGE_SIZE << 6 (2 * 4096 << 6). So we
see buffer_size is set to 516096 (524288 - 8192).

Reported-by: Joachim Breuer <linux-kernel@jmbreuer.net>
Tested-by: Joachim Breuer <linux-kernel@jmbreuer.net>
Acked-by: Kai Makisara <kai.makisara@kolumbus.fi>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: stable@kernel.org
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-12-10 08:54:13 -06:00
..
aacraid Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
aic7xxx tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
aic7xxx_old
aic94xx tree-wide: fix misspelling of "definition" in comments 2009-12-04 23:41:47 +01:00
arcmsr [SCSI] modify change_queue_depth to take in reason why it is being called 2009-12-04 12:00:41 -06:00
arm
be2iscsi [SCSI] be2iscsi: Adding support for various Async messages from chip 2009-12-10 08:54:13 -06:00
bfa Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
bnx2i Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
cxgb3i [SCSI] libiscsi: add warm target reset tmf support 2009-12-04 12:01:36 -06:00
device_handler [SCSI] scsi_dh_rdac: Add two new IBM devices to rdac_dev_list 2009-12-10 08:54:10 -06:00
dpt
fcoe [SCSI] fcoe, libfc: add get_lesb() to allow LLD to fill the link error status block (LESB) 2009-12-04 12:01:58 -06:00
fnic [SCSI] fnic: enable bsg pass-thru for fcping 2009-12-04 12:01:20 -06:00
ibmvscsi [SCSI] modify change_queue_depth to take in reason why it is being called 2009-12-04 12:00:41 -06:00
libfc Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
libsas Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2009-12-09 19:42:25 -08:00
lpfc [SCSI] lpfc: fix hang on SGI ia64 platform 2009-12-10 08:54:09 -06:00
megaraid Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
mpt2sas [SCSI] mpt2sas: add missing initialization of scsih_cmds 2009-12-10 08:54:10 -06:00
mvsas [SCSI] mvsas: add support for Adaptec ASC-1045/1405 SAS/SATA HBA 2009-12-10 08:54:12 -06:00
osd [SCSI] libosd: Error handling revamped 2009-12-04 12:01:47 -06:00
pcmcia pcmcia: rework the irq_req_t typedef 2009-11-28 18:03:14 +01:00
pm8001 [SCSI] pm8001: Fixes for tag alloc, error goto and code cleanup 2009-12-04 12:01:32 -06:00
qla2xxx [SCSI] scsi_lib_dma: fix bug with dma maps on nested scsi objects 2009-12-04 12:01:30 -06:00
qla4xxx
sym53c8xx_2 tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
.gitignore
3w-9xxx.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
3w-9xxx.h
3w-sas.c [SCSI] 3w-sas: Add new driver for LSI 3ware 9750 2009-12-04 12:00:51 -06:00
3w-sas.h [SCSI] 3w-sas: Add new driver for LSI 3ware 9750 2009-12-04 12:00:51 -06:00
3w-xxxx.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
3w-xxxx.h
53c700.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
53c700.h
53c700.scr
53c700_d.h_shipped
BusLogic.c
BusLogic.h
FlashPoint.c
Kconfig [SCSI] fnic: Add FIP support to the fnic driver 2009-12-04 12:01:19 -06:00
Makefile [SCSI] 3w-sas: Add new driver for LSI 3ware 9750 2009-12-04 12:00:51 -06:00
NCR53c406a.c
NCR5380.c
NCR5380.h
NCR_D700.c
NCR_D700.h
NCR_Q720.c
NCR_Q720.h
a100u2w.c
a100u2w.h
a2091.c
a2091.h
a3000.c
a3000.h
a4000t.c
advansys.c tree-wide: fix misspelling of "definition" in comments 2009-12-04 23:41:47 +01:00
aha152x.c
aha152x.h
aha1542.c
aha1542.h
aha1740.c
aha1740.h
aic7xxx_old.c
atari_NCR5380.c
atari_scsi.c
atari_scsi.h
atp870u.c
atp870u.h
bvme6000_scsi.c
ch.c
constants.c [SCSI] scsi: Add missing command definitions 2009-12-04 12:00:15 -06:00
dc395x.c tree-wide: fix typos "selct" + "slect" -> "select" 2009-11-09 09:40:56 +01:00
dc395x.h
dmx3191d.c tree-wide: fix misspelling of "definition" in comments 2009-12-04 23:41:47 +01:00
dpt_i2o.c dpt_i2o: Fix typo of EINVAL 2009-10-31 12:11:38 -07:00
dpti.h
dtc.c
dtc.h
eata.c
eata_generic.h
eata_pio.c
eata_pio.h
esp_scsi.c
esp_scsi.h
fd_mcs.c
fdomain.c
fdomain.h
g_NCR5380.c
g_NCR5380.h
g_NCR5380_mmio.c
gdth.c [SCSI] gdth: Prevent negative offsets in ioctl CVE-2009-3080 2009-11-11 12:14:21 -05:00
gdth.h
gdth_ioctl.h
gdth_proc.c
gdth_proc.h
gvp11.c
gvp11.h
hosts.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2009-12-09 19:42:25 -08:00
hptiop.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-12-09 19:43:33 -08:00
hptiop.h
ibmmca.c
imm.c
imm.h
in2000.c
in2000.h
initio.c
initio.h
ipr.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2009-12-09 19:42:25 -08:00
ipr.h [SCSI] ipr: add workaround for MSI interrupts on P7 2009-11-06 11:09:27 -06:00
ips.c
ips.h
iscsi_tcp.c [SCSI] libiscsi: add warm target reset tmf support 2009-12-04 12:01:36 -06:00
iscsi_tcp.h
jazz_esp.c
lasi700.c
libiscsi.c [SCSI] libiscsi: hook into ramp up/down handling 2009-12-04 12:01:39 -06:00
libiscsi_tcp.c tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
libsrp.c
mac53c94.c
mac53c94.h
mac_esp.c
mac_scsi.c
mac_scsi.h
megaraid.c
megaraid.h tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
mesh.c
mesh.h
mvme16x_scsi.c
mvme147.c
mvme147.h
ncr53c8xx.c tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
ncr53c8xx.h
nsp32.c tree-wide: fix a very frequent spelling mistake 2009-11-09 09:40:54 +01:00
nsp32.h
nsp32_debug.c
nsp32_io.h
osst.c
osst.h
osst_detect.h
osst_options.h
pas16.c
pas16.h
pmcraid.c [SCSI] pmcraid: support SMI-S object model of storage pool 2009-12-10 08:54:12 -06:00
pmcraid.h [SCSI] pmcraid: support SMI-S object model of storage pool 2009-12-10 08:54:12 -06:00
ppa.c
ppa.h
ps3rom.c
qla1280.c
qla1280.h
qlogicfas.c
qlogicfas408.c
qlogicfas408.h
qlogicpti.c
qlogicpti.h [SCSI] qlogicpti: add missing parentheses 2009-12-04 12:01:28 -06:00
raid_class.c
script_asm.pl
scsi.c [SCSI] add queue_depth ramp up code 2009-12-04 12:00:44 -06:00
scsi.h
scsi_debug.c [SCSI] scsi_debug: fix Thin provisioning support 2009-12-04 12:00:49 -06:00
scsi_devinfo.c [SCSI] fix func names in kernel-doc 2009-12-04 12:01:48 -06:00
scsi_error.c [SCSI] add queue_depth ramp up code 2009-12-04 12:00:44 -06:00
scsi_ioctl.c [SCSI] add scsi target reset support to scsi ioctl 2009-12-04 12:01:33 -06:00
scsi_lib.c [SCSI] scsi_lib: fix potential NULL dereference 2009-12-04 12:00:51 -06:00
scsi_lib_dma.c [SCSI] scsi_lib_dma: fix bug with dma maps on nested scsi objects 2009-12-04 12:01:30 -06:00
scsi_logging.h
scsi_module.c
scsi_netlink.c tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
scsi_priv.h
scsi_proc.c
scsi_sas_internal.h
scsi_scan.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2009-12-09 19:42:25 -08:00
scsi_sysctl.c sysctl: Drop & in front of every proc_handler. 2009-11-18 08:37:40 -08:00
scsi_sysfs.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2009-12-09 19:42:25 -08:00
scsi_tgt_if.c
scsi_tgt_lib.c
scsi_tgt_priv.h
scsi_transport_api.h
scsi_transport_fc.c [SCSI] fc class: fix fc_transport_init error handling 2009-12-10 08:54:11 -06:00
scsi_transport_fc_internal.h
scsi_transport_iscsi.c [SCSI] iscsi class: modify handling of replacement timeout 2009-12-04 12:01:37 -06:00
scsi_transport_sas.c tree-wide: fix assorted typos all over the place 2009-12-04 15:39:55 +01:00
scsi_transport_spi.c
scsi_transport_srp.c
scsi_transport_srp_internal.h
scsi_typedefs.h
scsi_wait_scan.c
scsicam.c
sd.c
sd.h
sd_dif.c [SCSI] sd: Return correct error code for DIF 2009-11-26 08:54:46 -06:00
ses.c
sg.c
sgiwd93.c
sim710.c
sni_53c710.c
sr.c
sr.h
sr_ioctl.c
sr_vendor.c
st.c [SCSI] st: fix mdata->page_order handling 2009-12-10 08:54:13 -06:00
st.h [SCSI] st: fix mdata->page_order handling 2009-12-10 08:54:13 -06:00
st_options.h
stex.c [SCSI] stex: update version to 4.6.0000.4 2009-10-29 13:03:27 -04:00
sun3_NCR5380.c
sun3_scsi.c
sun3_scsi.h
sun3_scsi_vme.c
sun3x_esp.c
sun_esp.c
sym53c416.c
sym53c416.h
t128.c
t128.h
tmscsim.c
tmscsim.h
u14-34f.c
ultrastor.c
ultrastor.h
vmw_pvscsi.c [SCSI] vmw_pvscsi: SCSI driver for VMware's virtual HBA. 2009-12-04 12:00:49 -06:00
vmw_pvscsi.h [SCSI] vmw_pvscsi: SCSI driver for VMware's virtual HBA. 2009-12-04 12:00:49 -06:00
wd33c93.c
wd33c93.h
wd7000.c tree-wide: fix misspelling of "definition" in comments 2009-12-04 23:41:47 +01:00
zalon.c
zorro7xx.c