mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
NFS: clean up the unstable write code
Get rid of the inlined #ifdefs. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
7ab77e03c1
commit
8e821cad12
2 changed files with 71 additions and 76 deletions
|
@ -49,8 +49,6 @@ struct nfs_page {
|
|||
};
|
||||
|
||||
#define NFS_WBACK_BUSY(req) (test_bit(PG_BUSY,&(req)->wb_flags))
|
||||
#define NFS_NEED_COMMIT(req) (test_bit(PG_NEED_COMMIT,&(req)->wb_flags))
|
||||
#define NFS_NEED_RESCHED(req) (test_bit(PG_NEED_RESCHED,&(req)->wb_flags))
|
||||
|
||||
extern struct nfs_page *nfs_create_request(struct nfs_open_context *ctx,
|
||||
struct inode *inode,
|
||||
|
@ -121,34 +119,6 @@ nfs_list_remove_request(struct nfs_page *req)
|
|||
req->wb_list_head = NULL;
|
||||
}
|
||||
|
||||
static inline int
|
||||
nfs_defer_commit(struct nfs_page *req)
|
||||
{
|
||||
return !test_and_set_bit(PG_NEED_COMMIT, &req->wb_flags);
|
||||
}
|
||||
|
||||
static inline void
|
||||
nfs_clear_commit(struct nfs_page *req)
|
||||
{
|
||||
smp_mb__before_clear_bit();
|
||||
clear_bit(PG_NEED_COMMIT, &req->wb_flags);
|
||||
smp_mb__after_clear_bit();
|
||||
}
|
||||
|
||||
static inline int
|
||||
nfs_defer_reschedule(struct nfs_page *req)
|
||||
{
|
||||
return !test_and_set_bit(PG_NEED_RESCHED, &req->wb_flags);
|
||||
}
|
||||
|
||||
static inline void
|
||||
nfs_clear_reschedule(struct nfs_page *req)
|
||||
{
|
||||
smp_mb__before_clear_bit();
|
||||
clear_bit(PG_NEED_RESCHED, &req->wb_flags);
|
||||
smp_mb__after_clear_bit();
|
||||
}
|
||||
|
||||
static inline struct nfs_page *
|
||||
nfs_list_entry(struct list_head *head)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue