diff options
author | David Rientjes <rientjes@google.com> | 2014-04-07 18:37:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-07 19:35:54 -0400 |
commit | 539a13b47e462d28c48f076c63871580f694a366 (patch) | |
tree | b0db5d5314b1276d433c3ae826d3a19a8902bec6 /include/linux/res_counter.h | |
parent | f0432d159601f96839f514f286eaa5b75c4112dc (diff) |
res_counter: remove interface for locked charging and uncharging
The res_counter_{charge,uncharge}_locked() variants are not used in the
kernel outside of the resource counter code itself, so remove the
interface.
Signed-off-by: David Rientjes <rientjes@google.com>
Acked-by: Michal Hocko <mhocko@suse.cz>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Christoph Lameter <cl@linux-foundation.org>
Cc: Pekka Enberg <penberg@kernel.org>
Cc: Tejun Heo <tj@kernel.org>
Cc: Mel Gorman <mgorman@suse.de>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Jianguo Wu <wujianguo@huawei.com>
Cc: Tim Hockin <thockin@google.com>
Cc: Christoph Lameter <cl@linux.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/res_counter.h')
-rw-r--r-- | include/linux/res_counter.h | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/include/linux/res_counter.h b/include/linux/res_counter.h index 201a69749659..56b7bc32db4f 100644 --- a/include/linux/res_counter.h +++ b/include/linux/res_counter.h | |||
@@ -104,15 +104,13 @@ void res_counter_init(struct res_counter *counter, struct res_counter *parent); | |||
104 | * units, e.g. numbers, bytes, Kbytes, etc | 104 | * units, e.g. numbers, bytes, Kbytes, etc |
105 | * | 105 | * |
106 | * returns 0 on success and <0 if the counter->usage will exceed the | 106 | * returns 0 on success and <0 if the counter->usage will exceed the |
107 | * counter->limit _locked call expects the counter->lock to be taken | 107 | * counter->limit |
108 | * | 108 | * |
109 | * charge_nofail works the same, except that it charges the resource | 109 | * charge_nofail works the same, except that it charges the resource |
110 | * counter unconditionally, and returns < 0 if the after the current | 110 | * counter unconditionally, and returns < 0 if the after the current |
111 | * charge we are over limit. | 111 | * charge we are over limit. |
112 | */ | 112 | */ |
113 | 113 | ||
114 | int __must_check res_counter_charge_locked(struct res_counter *counter, | ||
115 | unsigned long val, bool force); | ||
116 | int __must_check res_counter_charge(struct res_counter *counter, | 114 | int __must_check res_counter_charge(struct res_counter *counter, |
117 | unsigned long val, struct res_counter **limit_fail_at); | 115 | unsigned long val, struct res_counter **limit_fail_at); |
118 | int res_counter_charge_nofail(struct res_counter *counter, | 116 | int res_counter_charge_nofail(struct res_counter *counter, |
@@ -125,12 +123,10 @@ int res_counter_charge_nofail(struct res_counter *counter, | |||
125 | * @val: the amount of the resource | 123 | * @val: the amount of the resource |
126 | * | 124 | * |
127 | * these calls check for usage underflow and show a warning on the console | 125 | * these calls check for usage underflow and show a warning on the console |
128 | * _locked call expects the counter->lock to be taken | ||
129 | * | 126 | * |
130 | * returns the total charges still present in @counter. | 127 | * returns the total charges still present in @counter. |
131 | */ | 128 | */ |
132 | 129 | ||
133 | u64 res_counter_uncharge_locked(struct res_counter *counter, unsigned long val); | ||
134 | u64 res_counter_uncharge(struct res_counter *counter, unsigned long val); | 130 | u64 res_counter_uncharge(struct res_counter *counter, unsigned long val); |
135 | 131 | ||
136 | u64 res_counter_uncharge_until(struct res_counter *counter, | 132 | u64 res_counter_uncharge_until(struct res_counter *counter, |