mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-18 10:04:20 +03:00
cleanup: use kdev_t header in lvm tree
Reuse libdm header in lvm so we have single definition of MAJOR/MINOR/MKDEV macros in use.
This commit is contained in:
parent
9d4f9defc3
commit
556eba1835
@ -21,9 +21,7 @@
|
|||||||
#define NUMBER_OF_MAJORS 4096
|
#define NUMBER_OF_MAJORS 4096
|
||||||
|
|
||||||
#ifdef __linux__
|
#ifdef __linux__
|
||||||
# define MAJOR(dev) (((dev) & 0xfff00) >> 8)
|
# include "kdev_t.h"
|
||||||
# define MINOR(dev) (((dev) & 0xff) | (((dev) >> 12) & 0xfff00))
|
|
||||||
# define MKDEV(ma,mi) (((mi) & 0xff) | ((ma) << 8) | (((mi) & ~0xff) << 12))
|
|
||||||
#else
|
#else
|
||||||
# define MAJOR(x) major((x))
|
# define MAJOR(x) major((x))
|
||||||
# define MINOR(x) minor((x))
|
# define MINOR(x) minor((x))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user