From 84ca9c1cae026bc5c87976ff0518c246ca8ff97e Mon Sep 17 00:00:00 2001 From: Willem Jan Withagen Date: Tue, 9 Jun 2020 15:38:32 +0000 Subject: [PATCH] cls: fix missing __le32 definition On platforms that do not the __le* definitions it throws a compiler error. fixes: https://github.com/ceph/ceph/pull/35186 Signed-off-by: Willem Jan Withagen --- src/cls/cas/cls_cas_internal.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cls/cas/cls_cas_internal.h b/src/cls/cas/cls_cas_internal.h index ede334aa124..7fa4b96286e 100644 --- a/src/cls/cas/cls_cas_internal.h +++ b/src/cls/cas/cls_cas_internal.h @@ -228,7 +228,7 @@ struct chunk_refs_by_hash_t : public chunk_refs_t::refs_t { for (auto& i : by_hash) { denc_signed_varint(i.first.first, p); // this may write some bytes past where we move cursor too; harmless! - *(__le32*)p.get_pos_add(hash_bytes) = i.first.second; + *(ceph_le32*)p.get_pos_add(hash_bytes) = i.first.second; denc_varint(i.second, p); } DENC_FINISH(p); @@ -242,7 +242,7 @@ struct chunk_refs_by_hash_t : public chunk_refs_t::refs_t { int hash_bytes = (hash_bits + 7) / 8; while (n--) { int64_t poolid; - __le32 hash; + ceph_le32 hash; uint64_t count; denc_signed_varint(poolid, p); memcpy(&hash, p.get_pos_add(hash_bytes), hash_bytes); -- 2.39.5