Browse Source

libceph: fix ceph_eversion encoding

eversion_t is version+epoch in userspace and is encoded in that order.
ceph_eversion is defined as epoch+version in rados.h, yet we memcpy it
in __send_request().  Reoder ceph_eversion fields.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Ilya Dryomov 9 years ago
parent
commit
985c167388
1 changed files with 1 additions and 1 deletions
  1. 1 1
      include/linux/ceph/rados.h

+ 1 - 1
include/linux/ceph/rados.h

@@ -114,8 +114,8 @@ struct ceph_object_layout {
  * compound epoch+version, used by storage layer to serialize mutations
  * compound epoch+version, used by storage layer to serialize mutations
  */
  */
 struct ceph_eversion {
 struct ceph_eversion {
-	__le32 epoch;
 	__le64 version;
 	__le64 version;
+	__le32 epoch;
 } __attribute__ ((packed));
 } __attribute__ ((packed));
 
 
 /*
 /*