summaryrefslogtreecommitdiff
path: root/fs/ceph/ioctl.c
diff options
context:
space:
mode:
authorYan, Zheng <zyan@redhat.com>2016-03-07 09:35:06 +0800
committerIlya Dryomov <idryomov@gmail.com>2016-07-28 02:55:38 +0200
commit779fe0fb8e1883d5c479ac6bd85fbd237deed1f7 (patch)
treece9876a5f4201a7aa9f2daef838ccf7ff1827128 /fs/ceph/ioctl.c
parentcd08e0a274ba6215b79c83809b331e8af17196ba (diff)
ceph: rados pool namespace support
This patch adds codes that decode pool namespace information in cap message and request reply. Pool namespace is saved in i_layout, it will be passed to libceph when doing read/write. Signed-off-by: Yan, Zheng <zyan@redhat.com>
Diffstat (limited to 'fs/ceph/ioctl.c')
-rw-r--r--fs/ceph/ioctl.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ceph/ioctl.c b/fs/ceph/ioctl.c
index 843dd31a02cd..6a30101b55ef 100644
--- a/fs/ceph/ioctl.c
+++ b/fs/ceph/ioctl.c
@@ -213,9 +213,12 @@ static long ceph_ioctl_get_dataloc(struct file *file, void __user *arg)
ceph_ino(inode), dl.object_no);
oloc.pool = ci->i_layout.pool_id;
+ oloc.pool_ns = ceph_try_get_string(ci->i_layout.pool_ns);
ceph_oid_printf(&oid, "%s", dl.object_name);
r = ceph_object_locator_to_pg(osdc->osdmap, &oid, &oloc, &pgid);
+
+ ceph_oloc_destroy(&oloc);
if (r < 0) {
up_read(&osdc->lock);
return r;