summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/bcache.h2
-rw-r--r--include/linux/blkdev.h2
-rw-r--r--include/linux/generic-radix-tree.h13
-rw-r--r--include/linux/percpu-refcount.h5
4 files changed, 11 insertions, 11 deletions
diff --git a/include/linux/bcache.h b/include/linux/bcache.h
index dbb0274..d70e2e3 100644
--- a/include/linux/bcache.h
+++ b/include/linux/bcache.h
@@ -821,7 +821,7 @@ struct bch_sb_field {
__le32 type;
};
-enum bch_sb_field_types {
+enum bch_sb_field_type {
BCH_SB_FIELD_journal = 0,
BCH_SB_FIELD_members = 1,
BCH_SB_FIELD_crypt = 2,
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 3c18594..217ff09 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -110,6 +110,7 @@ struct super_block {
* NOTE! These match bits 12..15 of stat.st_mode
* (ie "(i_mode >> 12) & 15").
*/
+#ifndef DT_UNKNOWN
#define DT_UNKNOWN 0
#define DT_FIFO 1
#define DT_CHR 2
@@ -119,6 +120,7 @@ struct super_block {
#define DT_LNK 10
#define DT_SOCK 12
#define DT_WHT 14
+#endif
/*
* This is the "filldir" function type, used by readdir() to let
diff --git a/include/linux/generic-radix-tree.h b/include/linux/generic-radix-tree.h
index 1a951e9..6ea2deb 100644
--- a/include/linux/generic-radix-tree.h
+++ b/include/linux/generic-radix-tree.h
@@ -8,7 +8,6 @@
* interior nodes.
*/
-#include <linux/page.h>
#include <linux/bug.h>
#include <linux/kernel.h>
#include <linux/log2.h>
@@ -41,20 +40,14 @@ struct __genradix {
* genradix.
*/
-#define DECLARE_GENRADIX_TYPE(_name, _type) \
-struct _name { \
- struct __genradix tree; \
- _type type[0] __aligned(1); \
-}
-
-#define DECLARE_GENRADIX(_name, _type) \
+#define GENRADIX(_type) \
struct { \
struct __genradix tree; \
_type type[0] __aligned(1); \
-} _name
+}
#define DEFINE_GENRADIX(_name, _type) \
- DECLARE_GENRADIX(_name, _type) = __GENRADIX_INITIALIZER
+ GENRADIX(_type) _name = __GENRADIX_INITIALIZER
#define genradix_init(_radix) \
do { \
diff --git a/include/linux/percpu-refcount.h b/include/linux/percpu-refcount.h
index 5a98618..2bbd097 100644
--- a/include/linux/percpu-refcount.h
+++ b/include/linux/percpu-refcount.h
@@ -180,4 +180,9 @@ static inline bool percpu_ref_is_zero(struct percpu_ref *ref)
return !atomic_long_read(&ref->count);
}
+static inline bool percpu_ref_is_dying(struct percpu_ref *ref)
+{
+ return percpu_ref_is_zero(ref);
+}
+
#endif /* __TOOLS_LINUX_PERCPU_REFCOUNT_H */