mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-21 14:11:20 +00:00
[PATCH] separate bdi congestion functions from queue congestion functions
Separate out the concept of "queue congestion" from "backing-dev congestion". Congestion is a backing-dev concept, not a queue concept. The blk_* congestion functions are retained, as wrappers around the core backing-dev congestion functions. This proper layering is needed so that NFS can cleanly use the congestion functions, and so that CONFIG_BLOCK=n actually links. Cc: "Thomas Maier" <balagi@justmail.de> Cc: "Jens Axboe" <jens.axboe@oracle.com> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Cc: David Howells <dhowells@redhat.com> Cc: Peter Osterlund <petero2@telia.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
79e2de4bc5
commit
3fcfab16c5
17 changed files with 126 additions and 104 deletions
|
@ -10,6 +10,8 @@
|
|||
|
||||
#include <asm/atomic.h>
|
||||
|
||||
struct page;
|
||||
|
||||
/*
|
||||
* Bits in backing_dev_info.state
|
||||
*/
|
||||
|
@ -88,6 +90,11 @@ static inline int bdi_rw_congested(struct backing_dev_info *bdi)
|
|||
(1 << BDI_write_congested));
|
||||
}
|
||||
|
||||
void clear_bdi_congested(struct backing_dev_info *bdi, int rw);
|
||||
void set_bdi_congested(struct backing_dev_info *bdi, int rw);
|
||||
long congestion_wait(int rw, long timeout);
|
||||
void congestion_end(int rw);
|
||||
|
||||
#define bdi_cap_writeback_dirty(bdi) \
|
||||
(!((bdi)->capabilities & BDI_CAP_NO_WRITEBACK))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue