Parcourir la 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 il y a 9 ans
Parent
commit
985c167388
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  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
  */
 struct ceph_eversion {
-	__le32 epoch;
 	__le64 version;
+	__le32 epoch;
 } __attribute__ ((packed));
 
 /*