diff options
author | Tejun Heo <tj@kernel.org> | 2014-09-07 20:51:30 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2014-09-07 20:51:30 -0400 |
commit | a34375ef9e65340a138fc0be287de5c940d260fc (patch) | |
tree | 2e21b63d7c9240620a59090aa97e1d7c6df95b8c /include | |
parent | 20ae00792c6f1f18fc4fc5965445a145df92827e (diff) |
percpu-refcount: add @gfp to percpu_ref_init()
Percpu allocator now supports allocation mask. Add @gfp to
percpu_ref_init() so that !GFP_KERNEL allocation masks can be used
with percpu_refs too.
This patch doesn't make any functional difference.
v2: blk-mq conversion was missing. Updated.
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Kent Overstreet <koverstreet@google.com>
Cc: Benjamin LaHaise <bcrl@kvack.org>
Cc: Li Zefan <lizefan@huawei.com>
Cc: Nicholas A. Bellinger <nab@linux-iscsi.org>
Cc: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/percpu-refcount.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/percpu-refcount.h b/include/linux/percpu-refcount.h index 3dfbf237cd8f..ee8325122dbd 100644 --- a/include/linux/percpu-refcount.h +++ b/include/linux/percpu-refcount.h | |||
@@ -49,6 +49,7 @@ | |||
49 | #include <linux/kernel.h> | 49 | #include <linux/kernel.h> |
50 | #include <linux/percpu.h> | 50 | #include <linux/percpu.h> |
51 | #include <linux/rcupdate.h> | 51 | #include <linux/rcupdate.h> |
52 | #include <linux/gfp.h> | ||
52 | 53 | ||
53 | struct percpu_ref; | 54 | struct percpu_ref; |
54 | typedef void (percpu_ref_func_t)(struct percpu_ref *); | 55 | typedef void (percpu_ref_func_t)(struct percpu_ref *); |
@@ -66,7 +67,7 @@ struct percpu_ref { | |||
66 | }; | 67 | }; |
67 | 68 | ||
68 | int __must_check percpu_ref_init(struct percpu_ref *ref, | 69 | int __must_check percpu_ref_init(struct percpu_ref *ref, |
69 | percpu_ref_func_t *release); | 70 | percpu_ref_func_t *release, gfp_t gfp); |
70 | void percpu_ref_reinit(struct percpu_ref *ref); | 71 | void percpu_ref_reinit(struct percpu_ref *ref); |
71 | void percpu_ref_exit(struct percpu_ref *ref); | 72 | void percpu_ref_exit(struct percpu_ref *ref); |
72 | void percpu_ref_kill_and_confirm(struct percpu_ref *ref, | 73 | void percpu_ref_kill_and_confirm(struct percpu_ref *ref, |