From 1715907c6a910e34f693de3bfa893ba5e8ded2f7 Mon Sep 17 00:00:00 2001 From: Jeff Layton Date: Wed, 14 Sep 2016 10:51:07 -0400 Subject: [PATCH] Revert "client: move the device bitshift handling macros to Client.h" This reverts commit 2115de04a417e6df4272fc836829b70bd6a2b97e. This is unnecessary now that we're using dev_t's in ceph_statx. Signed-off-by: Jeff Layton --- src/client/Client.h | 8 -------- src/client/fuse_ll.cc | 7 +++++++ 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/client/Client.h b/src/client/Client.h index 8b674464a900c..1a047bcb8ae26 100644 --- a/src/client/Client.h +++ b/src/client/Client.h @@ -93,14 +93,6 @@ struct CommandOp std::string *outs; }; -/* Device bit shift handling */ -#define MINORBITS 20 -#define MINORMASK ((1U << MINORBITS) - 1) - -#define MAJOR(dev) ((unsigned int) ((dev) >> MINORBITS)) -#define MINOR(dev) ((unsigned int) ((dev) & MINORMASK)) -#define MKDEV(ma,mi) (((ma) << MINORBITS) | (mi)) - /* error code for ceph_fuse */ #define CEPH_FUSE_NO_MDS_UP -(1<<2) /* no mds up deteced in ceph_fuse */ diff --git a/src/client/fuse_ll.cc b/src/client/fuse_ll.cc index 6c3bf7c0a2da7..1d4719ba30d6e 100644 --- a/src/client/fuse_ll.cc +++ b/src/client/fuse_ll.cc @@ -41,6 +41,13 @@ #define FINO_STAG(x) ((x) >> 48) #define MAKE_FINO(i,s) ((i) | ((s) << 48)) +#define MINORBITS 20 +#define MINORMASK ((1U << MINORBITS) - 1) + +#define MAJOR(dev) ((unsigned int) ((dev) >> MINORBITS)) +#define MINOR(dev) ((unsigned int) ((dev) & MINORMASK)) +#define MKDEV(ma,mi) (((ma) << MINORBITS) | (mi)) + static uint32_t new_encode_dev(dev_t dev) { unsigned major = MAJOR(dev);