diff options
author | Tejun Heo <tj@kernel.org> | 2012-06-05 07:40:55 +0400 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2012-06-25 13:53:49 +0400 |
commit | a06e05e6afab70b4b23c0a7975aaeae24b195cd6 (patch) | |
tree | ec20f68e82542ebee27e914b04f356dc164bbe48 /block/blk-cgroup.c | |
parent | 86072d8112595ea1b6beeb33f578e7c2839e014e (diff) | |
download | linux-a06e05e6afab70b4b23c0a7975aaeae24b195cd6.tar.xz |
block: refactor get_request[_wait]()
Currently, there are two request allocation functions - get_request()
and get_request_wait(). The former tries to allocate a request once
and the latter keeps retrying until it succeeds. The latter wraps the
former and keeps retrying until allocation succeeds.
The combination of two functions deliver fallible non-wait allocation,
fallible wait allocation and unfailing wait allocation. However,
given that forward progress is guaranteed, fallible wait allocation
isn't all that useful and in fact nobody uses it.
This patch simplifies the interface as follows.
* get_request() is renamed to __get_request() and is only used by the
wrapper function.
* get_request_wait() is renamed to get_request(). It now takes
@gfp_mask and retries iff it contains %__GFP_WAIT.
This patch doesn't introduce any functional change and is to prepare
for further updates to request allocation path.
Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-cgroup.c')
0 files changed, 0 insertions, 0 deletions