summaryrefslogtreecommitdiffstats
path: root/fs/ceph/osd_client.h
diff options
context:
space:
mode:
authorYehuda Sadeh2010-04-06 23:51:47 +0200
committerSage Weil2010-10-21 00:36:01 +0200
commit3499e8a5d4dbb083324efd942e2c4fb7eb65f27c (patch)
tree7c3914991f81bcf2a9153047e7f1dad2ae0da74b /fs/ceph/osd_client.h
parentceph: lookup pool in osdmap by name (diff)
downloadkernel-qcow2-linux-3499e8a5d4dbb083324efd942e2c4fb7eb65f27c.tar.gz
kernel-qcow2-linux-3499e8a5d4dbb083324efd942e2c4fb7eb65f27c.tar.xz
kernel-qcow2-linux-3499e8a5d4dbb083324efd942e2c4fb7eb65f27c.zip
ceph: refactor osdc requests creation functions
The osd requests creation are being decoupled from the vino parameter, allowing clients using the osd to use other arbitrary object names that are not necessarily vino based. Also, calc_raw_layout now takes a snap id. Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net> Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph/osd_client.h')
-rw-r--r--fs/ceph/osd_client.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/fs/ceph/osd_client.h b/fs/ceph/osd_client.h
index ce776989ef6a..b687c2ea72e6 100644
--- a/fs/ceph/osd_client.h
+++ b/fs/ceph/osd_client.h
@@ -119,6 +119,31 @@ extern void ceph_osdc_handle_reply(struct ceph_osd_client *osdc,
extern void ceph_osdc_handle_map(struct ceph_osd_client *osdc,
struct ceph_msg *msg);
+extern void ceph_calc_raw_layout(struct ceph_osd_client *osdc,
+ struct ceph_file_layout *layout,
+ u64 snapid,
+ u64 off, u64 len, u64 *bno,
+ struct ceph_osd_request *req);
+
+extern struct ceph_osd_request *ceph_osdc_alloc_request(struct ceph_osd_client *osdc,
+ int flags,
+ struct ceph_snap_context *snapc,
+ int do_sync,
+ bool use_mempool,
+ gfp_t gfp_flags,
+ struct page **pages);
+
+extern void ceph_osdc_build_request(struct ceph_osd_request *req,
+ u64 off, u64 *plen,
+ int opcode,
+ struct ceph_snap_context *snapc,
+ int do_sync,
+ u32 truncate_seq,
+ u64 truncate_size,
+ struct timespec *mtime,
+ const char *oid,
+ int oid_len);
+
extern struct ceph_osd_request *ceph_osdc_new_request(struct ceph_osd_client *,
struct ceph_file_layout *layout,
struct ceph_vino vino,