Lines Matching +full:8 +full:k

12 static inline __u64 name(const type *k)				\
13 { return (k->field >> offset) & ~(~0ULL << size); } \
15 static inline void SET_##name(type *k, __u64 v) \
17 k->field &= ~(~(~0ULL << size) << offset); \
18 k->field |= (v & ~(~0ULL << size)) << offset; \
33 static inline __u64 name(const struct bkey *k, unsigned int i) \
34 { return (k->ptr[i] >> offset) & ~(~0ULL << size); } \
36 static inline void SET_##name(struct bkey *k, unsigned int i, __u64 v) \
38 k->ptr[i] &= ~(~(~0ULL << size) << offset); \
39 k->ptr[i] |= (v & ~(~0ULL << size)) << offset; \
43 #define KEY_MAX_U64S 8
56 static inline __u64 KEY_OFFSET(const struct bkey *k) in KEY_OFFSET() argument
58 return k->low; in KEY_OFFSET()
61 static inline void SET_KEY_OFFSET(struct bkey *k, __u64 v) in SET_KEY_OFFSET() argument
63 k->low = v; in SET_KEY_OFFSET()
83 #define KEY_START(k) (KEY_OFFSET(k) - KEY_SIZE(k)) argument
84 #define START_KEY(k) KEY(KEY_INODE(k), KEY_START(k), 0) argument
89 PTR_FIELD(PTR_OFFSET, 8, 43)
90 PTR_FIELD(PTR_GEN, 0, 8)
95 ((((__u64) dev) << 51) | ((__u64) offset) << 8 | gen)
99 static inline unsigned long bkey_u64s(const struct bkey *k) in bkey_u64s() argument
101 return (sizeof(struct bkey) / sizeof(__u64)) + KEY_PTRS(k); in bkey_u64s()
104 static inline unsigned long bkey_bytes(const struct bkey *k) in bkey_bytes() argument
106 return bkey_u64s(k) * sizeof(__u64); in bkey_bytes()
118 static inline struct bkey *bkey_next(const struct bkey *k) in bkey_next() argument
120 __u64 *d = (void *) k; in bkey_next()
122 return (struct bkey *) (d + bkey_u64s(k)); in bkey_next()
125 static inline struct bkey *bkey_idx(const struct bkey *k, unsigned int nr_keys) in bkey_idx() argument
127 __u64 *d = (void *) k; in bkey_idx()
132 #define BKEY_PAD 8
153 #define SB_SECTOR 8
159 #define MAX_CACHES_PER_SET 8