Skip to content

Commit a5cf5a4

Browse files
author
Kent Overstreet
committed
bcachefs: bcachefs_format.h should be using __u64
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
1 parent a0f8fae commit a5cf5a4

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

fs/bcachefs/bcachefs_format.h

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -695,7 +695,7 @@ struct bch_reservation {
695695
/* Maximum size (in u64s) a single pointer could be: */
696696
#define BKEY_EXTENT_PTR_U64s_MAX\
697697
((sizeof(struct bch_extent_crc128) + \
698-
sizeof(struct bch_extent_ptr)) / sizeof(u64))
698+
sizeof(struct bch_extent_ptr)) / sizeof(__u64))
699699

700700
/* Maximum possible size of an entire extent value: */
701701
#define BKEY_EXTENT_VAL_U64s_MAX \
@@ -707,7 +707,7 @@ struct bch_reservation {
707707
/* Btree pointers don't carry around checksums: */
708708
#define BKEY_BTREE_PTR_VAL_U64s_MAX \
709709
((sizeof(struct bch_btree_ptr_v2) + \
710-
sizeof(struct bch_extent_ptr) * BCH_REPLICAS_MAX) / sizeof(u64))
710+
sizeof(struct bch_extent_ptr) * BCH_REPLICAS_MAX) / sizeof(__u64))
711711
#define BKEY_BTREE_PTR_U64s_MAX \
712712
(BKEY_U64s + BKEY_BTREE_PTR_VAL_U64s_MAX)
713713

@@ -749,7 +749,7 @@ struct bch_inode_v3 {
749749
} __packed __aligned(8);
750750

751751
#define INODEv3_FIELDS_START_INITIAL 6
752-
#define INODEv3_FIELDS_START_CUR (offsetof(struct bch_inode_v3, fields) / sizeof(u64))
752+
#define INODEv3_FIELDS_START_CUR (offsetof(struct bch_inode_v3, fields) / sizeof(__u64))
753753

754754
struct bch_inode_generation {
755755
struct bch_val v;
@@ -916,7 +916,7 @@ struct bch_dirent {
916916
#define DT_SUBVOL 16
917917
#define BCH_DT_MAX 17
918918

919-
#define BCH_NAME_MAX ((unsigned) (U8_MAX * sizeof(u64) - \
919+
#define BCH_NAME_MAX ((unsigned) (U8_MAX * sizeof(__u64) - \
920920
sizeof(struct bkey) - \
921921
offsetof(struct bch_dirent, d_name)))
922922

@@ -1009,7 +1009,7 @@ struct bch_alloc_v4 {
10091009
} __packed __aligned(8);
10101010

10111011
#define BCH_ALLOC_V4_U64s_V0 6
1012-
#define BCH_ALLOC_V4_U64s (sizeof(struct bch_alloc_v4) / sizeof(u64))
1012+
#define BCH_ALLOC_V4_U64s (sizeof(struct bch_alloc_v4) / sizeof(__u64))
10131013

10141014
BITMASK(BCH_ALLOC_V4_NEED_DISCARD, struct bch_alloc_v4, flags, 0, 1)
10151015
BITMASK(BCH_ALLOC_V4_NEED_INC_GEN, struct bch_alloc_v4, flags, 1, 2)
@@ -1289,10 +1289,10 @@ struct bch_key {
12891289
};
12901290

12911291
#define BCH_KEY_MAGIC \
1292-
(((u64) 'b' << 0)|((u64) 'c' << 8)| \
1293-
((u64) 'h' << 16)|((u64) '*' << 24)| \
1294-
((u64) '*' << 32)|((u64) 'k' << 40)| \
1295-
((u64) 'e' << 48)|((u64) 'y' << 56))
1292+
(((__u64) 'b' << 0)|((__u64) 'c' << 8)| \
1293+
((__u64) 'h' << 16)|((__u64) '*' << 24)| \
1294+
((__u64) '*' << 32)|((__u64) 'k' << 40)| \
1295+
((__u64) 'e' << 48)|((__u64) 'y' << 56))
12961296

12971297
struct bch_encrypted_key {
12981298
__le64 magic;
@@ -2272,7 +2272,7 @@ static inline __u64 BTREE_NODE_ID(struct btree_node *n)
22722272
return BTREE_NODE_ID_LO(n) | (BTREE_NODE_ID_HI(n) << 4);
22732273
}
22742274

2275-
static inline void SET_BTREE_NODE_ID(struct btree_node *n, u64 v)
2275+
static inline void SET_BTREE_NODE_ID(struct btree_node *n, __u64 v)
22762276
{
22772277
SET_BTREE_NODE_ID_LO(n, v);
22782278
SET_BTREE_NODE_ID_HI(n, v >> 4);

0 commit comments

Comments
 (0)