aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAlex Elder <elder@inktank.com>2013-04-05 15:46:02 -0400
committerSage Weil <sage@inktank.com>2013-05-02 00:18:35 -0400
commit04017e29bbcf0673d8a6af616c56e395d05f5971 (patch)
tree09bd1c613cf85e4410755e2931cf3c21fa5da488 /include
parent90af36022aecdeeb1b9c0755461187de717c86dd (diff)
libceph: make method call data be a separate data item
Right now the data for a method call is specified via a pointer and length, and it's copied--along with the class and method name--into a pagelist data item to be sent to the osd. Instead, encode the data in a data item separate from the class and method names. This will allow large amounts of data to be supplied to methods without copying. Only rbd uses the class functionality right now, and when it really needs this it will probably need to use a page array rather than a page list. But this simple implementation demonstrates the functionality on the osd client, and that's enough for now. This resolves: http://tracker.ceph.com/issues/4104 Signed-off-by: Alex Elder <elder@inktank.com> Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/ceph/osd_client.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/linux/ceph/osd_client.h b/include/linux/ceph/osd_client.h
index 4ec46c0ceaf7..2a68a7465c18 100644
--- a/include/linux/ceph/osd_client.h
+++ b/include/linux/ceph/osd_client.h
@@ -92,10 +92,9 @@ struct ceph_osd_req_op {
92 struct { 92 struct {
93 const char *class_name; 93 const char *class_name;
94 const char *method_name; 94 const char *method_name;
95 const void *request_data;
96 struct ceph_osd_data request_info; 95 struct ceph_osd_data request_info;
96 struct ceph_osd_data request_data;
97 struct ceph_osd_data response_data; 97 struct ceph_osd_data response_data;
98 u32 request_data_len;
99 __u8 class_len; 98 __u8 class_len;
100 __u8 method_len; 99 __u8 method_len;
101 __u8 argc; 100 __u8 argc;
@@ -259,6 +258,9 @@ extern void osd_req_op_extent_osd_data_bio(struct ceph_osd_request *,
259 struct bio *bio, size_t bio_length); 258 struct bio *bio, size_t bio_length);
260#endif /* CONFIG_BLOCK */ 259#endif /* CONFIG_BLOCK */
261 260
261extern void osd_req_op_cls_request_data_pagelist(struct ceph_osd_request *,
262 unsigned int which,
263 struct ceph_pagelist *pagelist);
262extern void osd_req_op_cls_response_data_pages(struct ceph_osd_request *, 264extern void osd_req_op_cls_response_data_pages(struct ceph_osd_request *,
263 unsigned int which, 265 unsigned int which,
264 struct page **pages, u64 length, 266 struct page **pages, u64 length,
@@ -267,9 +269,7 @@ extern void osd_req_op_cls_response_data_pages(struct ceph_osd_request *,
267 269
268extern void osd_req_op_cls_init(struct ceph_osd_request *osd_req, 270extern void osd_req_op_cls_init(struct ceph_osd_request *osd_req,
269 unsigned int which, u16 opcode, 271 unsigned int which, u16 opcode,
270 const char *class, const char *method, 272 const char *class, const char *method);
271 const void *request_data,
272 size_t request_data_size);
273extern void osd_req_op_watch_init(struct ceph_osd_request *osd_req, 273extern void osd_req_op_watch_init(struct ceph_osd_request *osd_req,
274 unsigned int which, u16 opcode, 274 unsigned int which, u16 opcode,
275 u64 cookie, u64 version, int flag); 275 u64 cookie, u64 version, int flag);