History

libceph: mon_get_version request infrastructure

Add support for mon_get_version requests to libceph. This reuses much of the ceph_mon_generic_request infrastructure, with one exception. Older OSDs don't set mon_get_version reply hdr->tid even if the original request had a non-zero tid, which makes it impossible to lookup ceph_mon_generic_request contexts by tid in get_generic_reply() for such replies. As a workaround, we allocate a reply message on the reply path. This can probably interfere with revoke, but I don't see a better way.

Ilya Dryomov committed 12 years ago

Commit 513a8241 parent 002b36b4 files · +128 −8Browse files

Showing the changes to include/linux/ceph (1 of 4 files). Show all

Unified · Split

include/linux/ceph/mon_client.h+6−3
@@ -40,9 +40,9 @@ struct ceph_mon_request { · 39 unmodified lines
4040 };
4141
4242 /*
43− * ceph_mon_generic_request is being used for the statfs and poolop requests
44− * which are bening done a bit differently because we need to get data back
45− * to the caller
43+ * ceph_mon_generic_request is being used for the statfs, poolop and
44+ * mon_get_version requests which are being done a bit differently
45+ * because we need to get data back to the caller
4646 */
4747 struct ceph_mon_generic_request {
4848 struct kref kref;
@@ -108,6 +108,9 @@ extern void ceph_monc_request_next_osdmap(struct ceph_mon_client *monc); · 59 unmodified lines
108108 extern int ceph_monc_do_statfs(struct ceph_mon_client *monc,
109109 struct ceph_statfs *buf);
110110
111+extern int ceph_monc_do_get_version(struct ceph_mon_client *monc,
112+ const char *what, u64 *newest);
113+
111114 extern int ceph_monc_open_session(struct ceph_mon_client *monc);
112115
113116 extern int ceph_monc_validate_auth(struct ceph_mon_client *monc);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t