* [Ocfs2-devel] [PATCH] ocfs2: clean up unused 'page' parameter in ocfs2_write_end_nolock()
@ 2016-11-19 4:46 piaojun
2016-11-21 1:16 ` Joseph Qi
0 siblings, 1 reply; 2+ messages in thread
From: piaojun @ 2016-11-19 4:46 UTC (permalink / raw)
To: ocfs2-devel
'page' parameter in ocfs2_write_end_nolock() is never used.
Signed-off-by: Jun Piao <piaojun@huawei.com>
---
fs/ocfs2/aops.c | 7 +++----
fs/ocfs2/aops.h | 3 +--
fs/ocfs2/mmap.c | 3 +--
3 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/fs/ocfs2/aops.c b/fs/ocfs2/aops.c
index c5c5b97..9a88984 100644
--- a/fs/ocfs2/aops.c
+++ b/fs/ocfs2/aops.c
@@ -1950,8 +1950,7 @@ static void ocfs2_write_end_inline(struct inode *inode, loff_t pos,
}
int ocfs2_write_end_nolock(struct address_space *mapping,
- loff_t pos, unsigned len, unsigned copied,
- struct page *page, void *fsdata)
+ loff_t pos, unsigned len, unsigned copied, void *fsdata)
{
int i, ret;
unsigned from, to, start = pos & (PAGE_SIZE - 1);
@@ -2064,7 +2063,7 @@ static int ocfs2_write_end(struct file *file, struct address_space *mapping,
int ret;
struct inode *inode = mapping->host;
- ret = ocfs2_write_end_nolock(mapping, pos, len, copied, page, fsdata);
+ ret = ocfs2_write_end_nolock(mapping, pos, len, copied, fsdata);
up_write(&OCFS2_I(inode)->ip_alloc_sem);
ocfs2_inode_unlock(inode, 1);
@@ -2241,7 +2240,7 @@ static int ocfs2_dio_get_block(struct inode *inode, sector_t iblock,
dwc->dw_zero_count++;
}
- ret = ocfs2_write_end_nolock(inode->i_mapping, pos, len, len, NULL, wc);
+ ret = ocfs2_write_end_nolock(inode->i_mapping, pos, len, len, wc);
BUG_ON(ret != len);
ret = 0;
unlock:
diff --git a/fs/ocfs2/aops.h b/fs/ocfs2/aops.h
index b1c9f28..8614ff0 100644
--- a/fs/ocfs2/aops.h
+++ b/fs/ocfs2/aops.h
@@ -44,8 +44,7 @@ int walk_page_buffers( handle_t *handle,
struct buffer_head *bh));
int ocfs2_write_end_nolock(struct address_space *mapping,
- loff_t pos, unsigned len, unsigned copied,
- struct page *page, void *fsdata);
+ loff_t pos, unsigned len, unsigned copied, void *fsdata);
typedef enum {
OCFS2_WRITE_BUFFER = 0,
diff --git a/fs/ocfs2/mmap.c b/fs/ocfs2/mmap.c
index 71545ad..4290887 100644
--- a/fs/ocfs2/mmap.c
+++ b/fs/ocfs2/mmap.c
@@ -120,8 +120,7 @@ static int __ocfs2_page_mkwrite(struct file *file, struct buffer_head *di_bh,
ret = VM_FAULT_NOPAGE;
goto out;
}
- ret = ocfs2_write_end_nolock(mapping, pos, len, len, locked_page,
- fsdata);
+ ret = ocfs2_write_end_nolock(mapping, pos, len, len, fsdata);
BUG_ON(ret != len);
ret = VM_FAULT_LOCKED;
out:
--
1.9.5.msysgit.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [Ocfs2-devel] [PATCH] ocfs2: clean up unused 'page' parameter in ocfs2_write_end_nolock()
2016-11-19 4:46 [Ocfs2-devel] [PATCH] ocfs2: clean up unused 'page' parameter in ocfs2_write_end_nolock() piaojun
@ 2016-11-21 1:16 ` Joseph Qi
0 siblings, 0 replies; 2+ messages in thread
From: Joseph Qi @ 2016-11-21 1:16 UTC (permalink / raw)
To: ocfs2-devel
Looks good to me.
Reviewed-by: Joseph Qi <jiangqi903@gmail.com>
On 16/11/19 12:46, piaojun wrote:
> 'page' parameter in ocfs2_write_end_nolock() is never used.
>
> Signed-off-by: Jun Piao <piaojun@huawei.com>
> ---
> fs/ocfs2/aops.c | 7 +++----
> fs/ocfs2/aops.h | 3 +--
> fs/ocfs2/mmap.c | 3 +--
> 3 files changed, 5 insertions(+), 8 deletions(-)
>
> diff --git a/fs/ocfs2/aops.c b/fs/ocfs2/aops.c
> index c5c5b97..9a88984 100644
> --- a/fs/ocfs2/aops.c
> +++ b/fs/ocfs2/aops.c
> @@ -1950,8 +1950,7 @@ static void ocfs2_write_end_inline(struct inode *inode, loff_t pos,
> }
>
> int ocfs2_write_end_nolock(struct address_space *mapping,
> - loff_t pos, unsigned len, unsigned copied,
> - struct page *page, void *fsdata)
> + loff_t pos, unsigned len, unsigned copied, void *fsdata)
> {
> int i, ret;
> unsigned from, to, start = pos & (PAGE_SIZE - 1);
> @@ -2064,7 +2063,7 @@ static int ocfs2_write_end(struct file *file, struct address_space *mapping,
> int ret;
> struct inode *inode = mapping->host;
>
> - ret = ocfs2_write_end_nolock(mapping, pos, len, copied, page, fsdata);
> + ret = ocfs2_write_end_nolock(mapping, pos, len, copied, fsdata);
>
> up_write(&OCFS2_I(inode)->ip_alloc_sem);
> ocfs2_inode_unlock(inode, 1);
> @@ -2241,7 +2240,7 @@ static int ocfs2_dio_get_block(struct inode *inode, sector_t iblock,
> dwc->dw_zero_count++;
> }
>
> - ret = ocfs2_write_end_nolock(inode->i_mapping, pos, len, len, NULL, wc);
> + ret = ocfs2_write_end_nolock(inode->i_mapping, pos, len, len, wc);
> BUG_ON(ret != len);
> ret = 0;
> unlock:
> diff --git a/fs/ocfs2/aops.h b/fs/ocfs2/aops.h
> index b1c9f28..8614ff0 100644
> --- a/fs/ocfs2/aops.h
> +++ b/fs/ocfs2/aops.h
> @@ -44,8 +44,7 @@ int walk_page_buffers( handle_t *handle,
> struct buffer_head *bh));
>
> int ocfs2_write_end_nolock(struct address_space *mapping,
> - loff_t pos, unsigned len, unsigned copied,
> - struct page *page, void *fsdata);
> + loff_t pos, unsigned len, unsigned copied, void *fsdata);
>
> typedef enum {
> OCFS2_WRITE_BUFFER = 0,
> diff --git a/fs/ocfs2/mmap.c b/fs/ocfs2/mmap.c
> index 71545ad..4290887 100644
> --- a/fs/ocfs2/mmap.c
> +++ b/fs/ocfs2/mmap.c
> @@ -120,8 +120,7 @@ static int __ocfs2_page_mkwrite(struct file *file, struct buffer_head *di_bh,
> ret = VM_FAULT_NOPAGE;
> goto out;
> }
> - ret = ocfs2_write_end_nolock(mapping, pos, len, len, locked_page,
> - fsdata);
> + ret = ocfs2_write_end_nolock(mapping, pos, len, len, fsdata);
> BUG_ON(ret != len);
> ret = VM_FAULT_LOCKED;
> out:
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-11-21 1:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-19 4:46 [Ocfs2-devel] [PATCH] ocfs2: clean up unused 'page' parameter in ocfs2_write_end_nolock() piaojun
2016-11-21 1:16 ` Joseph Qi
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.