diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-12 12:50:42 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-12 12:50:42 -0400 |
commit | c9b8af00ff71f86ff3d092cc60ca673e1d0eae5b (patch) | |
tree | 25cc016481cc693552bebb4040041817280c2ccf /fs | |
parent | c59a264c9e932c828d533497e286b89e43c8d1be (diff) | |
parent | 82681a318f9f028ea64e61f24bbd9ac535531921 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (154 commits)
[SCSI] osd: Remove out-of-tree left overs
[SCSI] libosd: Use REQ_QUIET requests.
[SCSI] osduld: use filp_open() when looking up an osd-device
[SCSI] libosd: Define an osd_dev wrapper to retrieve the request_queue
[SCSI] libosd: osd_req_{read,write} takes a length parameter
[SCSI] libosd: Let _osd_req_finalize_data_integrity receive number of out_bytes
[SCSI] libosd: osd_req_{read,write}_kern new API
[SCSI] libosd: Better printout of OSD target system information
[SCSI] libosd: OSD2r05: Attribute definitions
[SCSI] libosd: OSD2r05: Additional command enums
[SCSI] mpt fusion: fix up doc book comments
[SCSI] mpt fusion: Added support for Broadcast primitives Event handling
[SCSI] mpt fusion: Queue full event handling
[SCSI] mpt fusion: RAID device handling and Dual port Raid support is added
[SCSI] mpt fusion: Put IOC into ready state if it not already in ready state
[SCSI] mpt fusion: Code Cleanup patch
[SCSI] mpt fusion: Rescan SAS topology added
[SCSI] mpt fusion: SAS topology scan changes, expander events
[SCSI] mpt fusion: Firmware event implementation using seperate WorkQueue
[SCSI] mpt fusion: rewrite of ioctl_cmds internal generated function
...
Diffstat (limited to 'fs')
-rw-r--r-- | fs/exofs/common.h | 6 | ||||
-rw-r--r-- | fs/exofs/inode.c | 8 | ||||
-rw-r--r-- | fs/exofs/osd.c | 26 |
3 files changed, 4 insertions, 36 deletions
diff --git a/fs/exofs/common.h b/fs/exofs/common.h index b1512c4bb8c7..24667eedc023 100644 --- a/fs/exofs/common.h +++ b/fs/exofs/common.h | |||
@@ -175,10 +175,4 @@ int exofs_async_op(struct osd_request *or, | |||
175 | 175 | ||
176 | int extract_attr_from_req(struct osd_request *or, struct osd_attr *attr); | 176 | int extract_attr_from_req(struct osd_request *or, struct osd_attr *attr); |
177 | 177 | ||
178 | int osd_req_read_kern(struct osd_request *or, | ||
179 | const struct osd_obj_id *obj, u64 offset, void *buff, u64 len); | ||
180 | |||
181 | int osd_req_write_kern(struct osd_request *or, | ||
182 | const struct osd_obj_id *obj, u64 offset, void *buff, u64 len); | ||
183 | |||
184 | #endif /*ifndef __EXOFS_COM_H__*/ | 178 | #endif /*ifndef __EXOFS_COM_H__*/ |
diff --git a/fs/exofs/inode.c b/fs/exofs/inode.c index ba8d9fab4693..77d0a295eb1c 100644 --- a/fs/exofs/inode.c +++ b/fs/exofs/inode.c | |||
@@ -59,10 +59,9 @@ static void _pcol_init(struct page_collect *pcol, unsigned expected_pages, | |||
59 | struct inode *inode) | 59 | struct inode *inode) |
60 | { | 60 | { |
61 | struct exofs_sb_info *sbi = inode->i_sb->s_fs_info; | 61 | struct exofs_sb_info *sbi = inode->i_sb->s_fs_info; |
62 | struct request_queue *req_q = sbi->s_dev->scsi_device->request_queue; | ||
63 | 62 | ||
64 | pcol->sbi = sbi; | 63 | pcol->sbi = sbi; |
65 | pcol->req_q = req_q; | 64 | pcol->req_q = osd_request_queue(sbi->s_dev); |
66 | pcol->inode = inode; | 65 | pcol->inode = inode; |
67 | pcol->expected_pages = expected_pages; | 66 | pcol->expected_pages = expected_pages; |
68 | 67 | ||
@@ -266,7 +265,7 @@ static int read_exec(struct page_collect *pcol, bool is_sync) | |||
266 | goto err; | 265 | goto err; |
267 | } | 266 | } |
268 | 267 | ||
269 | osd_req_read(or, &obj, pcol->bio, i_start); | 268 | osd_req_read(or, &obj, i_start, pcol->bio, pcol->length); |
270 | 269 | ||
271 | if (is_sync) { | 270 | if (is_sync) { |
272 | exofs_sync_op(or, pcol->sbi->s_timeout, oi->i_cred); | 271 | exofs_sync_op(or, pcol->sbi->s_timeout, oi->i_cred); |
@@ -522,7 +521,8 @@ static int write_exec(struct page_collect *pcol) | |||
522 | 521 | ||
523 | *pcol_copy = *pcol; | 522 | *pcol_copy = *pcol; |
524 | 523 | ||
525 | osd_req_write(or, &obj, pcol_copy->bio, i_start); | 524 | pcol_copy->bio->bi_rw |= (1 << BIO_RW); /* FIXME: bio_set_dir() */ |
525 | osd_req_write(or, &obj, i_start, pcol_copy->bio, pcol_copy->length); | ||
526 | ret = exofs_async_op(or, writepages_done, pcol_copy, oi->i_cred); | 526 | ret = exofs_async_op(or, writepages_done, pcol_copy, oi->i_cred); |
527 | if (unlikely(ret)) { | 527 | if (unlikely(ret)) { |
528 | EXOFS_ERR("write_exec: exofs_async_op() Faild\n"); | 528 | EXOFS_ERR("write_exec: exofs_async_op() Faild\n"); |
diff --git a/fs/exofs/osd.c b/fs/exofs/osd.c index 06ca92672eb5..b3d2ccb87aaa 100644 --- a/fs/exofs/osd.c +++ b/fs/exofs/osd.c | |||
@@ -125,29 +125,3 @@ int extract_attr_from_req(struct osd_request *or, struct osd_attr *attr) | |||
125 | 125 | ||
126 | return -EIO; | 126 | return -EIO; |
127 | } | 127 | } |
128 | |||
129 | int osd_req_read_kern(struct osd_request *or, | ||
130 | const struct osd_obj_id *obj, u64 offset, void* buff, u64 len) | ||
131 | { | ||
132 | struct request_queue *req_q = or->osd_dev->scsi_device->request_queue; | ||
133 | struct bio *bio = bio_map_kern(req_q, buff, len, GFP_KERNEL); | ||
134 | |||
135 | if (!bio) | ||
136 | return -ENOMEM; | ||
137 | |||
138 | osd_req_read(or, obj, bio, offset); | ||
139 | return 0; | ||
140 | } | ||
141 | |||
142 | int osd_req_write_kern(struct osd_request *or, | ||
143 | const struct osd_obj_id *obj, u64 offset, void* buff, u64 len) | ||
144 | { | ||
145 | struct request_queue *req_q = or->osd_dev->scsi_device->request_queue; | ||
146 | struct bio *bio = bio_map_kern(req_q, buff, len, GFP_KERNEL); | ||
147 | |||
148 | if (!bio) | ||
149 | return -ENOMEM; | ||
150 | |||
151 | osd_req_write(or, obj, bio, offset); | ||
152 | return 0; | ||
153 | } | ||