aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/ps3rom.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/ps3rom.c')
-rw-r--r--drivers/scsi/ps3rom.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/scsi/ps3rom.c b/drivers/scsi/ps3rom.c
index 0f43d1d046d9..03f19b8d19c9 100644
--- a/drivers/scsi/ps3rom.c
+++ b/drivers/scsi/ps3rom.c
@@ -111,14 +111,14 @@ static int fill_from_dev_buffer(struct scsi_cmnd *cmd, const void *buf)
111 req_len = act_len = 0; 111 req_len = act_len = 0;
112 scsi_for_each_sg(cmd, sgpnt, scsi_sg_count(cmd), k) { 112 scsi_for_each_sg(cmd, sgpnt, scsi_sg_count(cmd), k) {
113 if (active) { 113 if (active) {
114 kaddr = kmap_atomic(sgpnt->page, KM_IRQ0); 114 kaddr = kmap_atomic(sg_page(sgpnt), KM_IRQ0);
115 len = sgpnt->length; 115 len = sgpnt->length;
116 if ((req_len + len) > buflen) { 116 if ((req_len + len) > buflen) {
117 active = 0; 117 active = 0;
118 len = buflen - req_len; 118 len = buflen - req_len;
119 } 119 }
120 memcpy(kaddr + sgpnt->offset, buf + req_len, len); 120 memcpy(kaddr + sgpnt->offset, buf + req_len, len);
121 flush_kernel_dcache_page(sgpnt->page); 121 flush_kernel_dcache_page(sg_page(sgpnt));
122 kunmap_atomic(kaddr, KM_IRQ0); 122 kunmap_atomic(kaddr, KM_IRQ0);
123 act_len += len; 123 act_len += len;
124 } 124 }
@@ -147,7 +147,7 @@ static int fetch_to_dev_buffer(struct scsi_cmnd *cmd, void *buf)
147 147
148 req_len = fin = 0; 148 req_len = fin = 0;
149 scsi_for_each_sg(cmd, sgpnt, scsi_sg_count(cmd), k) { 149 scsi_for_each_sg(cmd, sgpnt, scsi_sg_count(cmd), k) {
150 kaddr = kmap_atomic(sgpnt->page, KM_IRQ0); 150 kaddr = kmap_atomic(sg_page(sgpnt->page), KM_IRQ0);
151 len = sgpnt->length; 151 len = sgpnt->length;
152 if ((req_len + len) > buflen) { 152 if ((req_len + len) > buflen) {
153 len = buflen - req_len; 153 len = buflen - req_len;