History

bcache: use read_cache_page_gfp to read the superblock

Avoid a pointless dependency on buffer heads in bcache by simply open coding reading a single page. Also add a SB_OFFSET define for the byte offset of the superblock instead of using magic numbers.

Christoph Hellwig committed 6 years ago

Commit 6321bef1 parent 475389a2 files · +8 −9Browse files

Showing the changes to include/uapi/linux (1 of 2 files). Show all

Unified · Split

include/uapi/linux/bcache.h+1−0
@@ -148,6 +148,7 @@ static inline struct bkey *bkey_idx(const struct bkey *k, unsigned int nr_keys) · 147 unmodified lines
148#define BCACHE_SB_MAX_VERSION 4148#define BCACHE_SB_MAX_VERSION 4
149 149
150#define SB_SECTOR 8150#define SB_SECTOR 8
151#define SB_OFFSET (SB_SECTOR << SECTOR_SHIFT)
151#define SB_SIZE 4096152#define SB_SIZE 4096
152#define SB_LABEL_SIZE 32153#define SB_LABEL_SIZE 32
153#define SB_JOURNAL_BUCKETS 256U154#define SB_JOURNAL_BUCKETS 256U