* [PATCH] nilfs2: remove redundant pointer sbufs
@ 2021-12-28 17:27 ` Ryusuke Konishi
0 siblings, 0 replies; 6+ messages in thread
From: Ryusuke Konishi @ 2021-12-28 17:27 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-nilfs, LKML
From: Colin Ian King <colin.i.king@gmail.com>
Pointer sbufs is being assigned a value but it's not being used
later on. The pointer is redundant and can be removed. Cleans up
scan-build static analysis warning:
fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
is used in the enclosing expression, the value is never actually read
from 'sbufs' [deadcode.DeadStores]
sbh = sbufs = page_buffers(src);
Link: https://lkml.kernel.org/r/20211211180955.550380-1-colin.i.king@gmail.com
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
---
fs/nilfs2/page.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
index bc3e2cd4117f..063dd16d75b5 100644
--- a/fs/nilfs2/page.c
+++ b/fs/nilfs2/page.c
@@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
*/
static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
{
- struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
+ struct buffer_head *dbh, *dbufs, *sbh;
unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
BUG_ON(PageWriteback(dst));
- sbh = sbufs = page_buffers(src);
+ sbh = page_buffers(src);
if (!page_has_buffers(dst))
create_empty_buffers(dst, sbh->b_size, 0);
--
1.8.3.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH] nilfs2: remove redundant pointer sbufs
@ 2021-12-28 17:27 ` Ryusuke Konishi
0 siblings, 0 replies; 6+ messages in thread
From: Ryusuke Konishi @ 2021-12-28 17:27 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-nilfs, LKML
From: Colin Ian King <colin.i.king-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Pointer sbufs is being assigned a value but it's not being used
later on. The pointer is redundant and can be removed. Cleans up
scan-build static analysis warning:
fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
is used in the enclosing expression, the value is never actually read
from 'sbufs' [deadcode.DeadStores]
sbh = sbufs = page_buffers(src);
Link: https://lkml.kernel.org/r/20211211180955.550380-1-colin.i.king-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
Signed-off-by: Colin Ian King <colin.i.king-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Signed-off-by: Ryusuke Konishi <konishi.ryusuke-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
fs/nilfs2/page.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
index bc3e2cd4117f..063dd16d75b5 100644
--- a/fs/nilfs2/page.c
+++ b/fs/nilfs2/page.c
@@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
*/
static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
{
- struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
+ struct buffer_head *dbh, *dbufs, *sbh;
unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
BUG_ON(PageWriteback(dst));
- sbh = sbufs = page_buffers(src);
+ sbh = page_buffers(src);
if (!page_has_buffers(dst))
create_empty_buffers(dst, sbh->b_size, 0);
--
1.8.3.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] nilfs2: remove redundant pointer sbufs
2021-12-28 17:27 ` Ryusuke Konishi
(?)
@ 2021-12-28 17:37 ` Ryusuke Konishi
-1 siblings, 0 replies; 6+ messages in thread
From: Ryusuke Konishi @ 2021-12-28 17:37 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-nilfs, LKML
Hi Andrew,
Please queue this for the next merge window.
Thank you,
Ryusuke Konishi
On Wed, Dec 29, 2021 at 2:27 AM Ryusuke Konishi
<konishi.ryusuke@gmail.com> wrote:
>
> From: Colin Ian King <colin.i.king@gmail.com>
>
> Pointer sbufs is being assigned a value but it's not being used
> later on. The pointer is redundant and can be removed. Cleans up
> scan-build static analysis warning:
>
> fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
> is used in the enclosing expression, the value is never actually read
> from 'sbufs' [deadcode.DeadStores]
> sbh = sbufs = page_buffers(src);
>
> Link: https://lkml.kernel.org/r/20211211180955.550380-1-colin.i.king@gmail.com
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
> Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
> ---
> fs/nilfs2/page.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
> index bc3e2cd4117f..063dd16d75b5 100644
> --- a/fs/nilfs2/page.c
> +++ b/fs/nilfs2/page.c
> @@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
> */
> static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
> {
> - struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
> + struct buffer_head *dbh, *dbufs, *sbh;
> unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
>
> BUG_ON(PageWriteback(dst));
>
> - sbh = sbufs = page_buffers(src);
> + sbh = page_buffers(src);
> if (!page_has_buffers(dst))
> create_empty_buffers(dst, sbh->b_size, 0);
>
> --
> 1.8.3.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] nilfs2: remove redundant pointer sbufs
@ 2021-12-12 15:51 ` Ryusuke Konishi
0 siblings, 0 replies; 6+ messages in thread
From: Ryusuke Konishi @ 2021-12-12 15:51 UTC (permalink / raw)
To: Colin Ian King; +Cc: linux-nilfs, kernel-janitors, LKML
On Sun, Dec 12, 2021 at 3:09 AM Colin Ian King <colin.i.king@gmail.com> wrote:
>
> Pointer sbufs is being assigned a value but it's not being used
> later on. The pointer is redundant and can be removed. Cleans up
> scan-build static analysis warning:
>
> fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
> is used in the enclosing expression, the value is never actually read
> from 'sbufs' [deadcode.DeadStores]
> sbh = sbufs = page_buffers(src);
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Looks good.
Will apply, thank you.
Ryusuke Konishi
> ---
> fs/nilfs2/page.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
> index bc3e2cd4117f..063dd16d75b5 100644
> --- a/fs/nilfs2/page.c
> +++ b/fs/nilfs2/page.c
> @@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
> */
> static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
> {
> - struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
> + struct buffer_head *dbh, *dbufs, *sbh;
> unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
>
> BUG_ON(PageWriteback(dst));
>
> - sbh = sbufs = page_buffers(src);
> + sbh = page_buffers(src);
> if (!page_has_buffers(dst))
> create_empty_buffers(dst, sbh->b_size, 0);
>
> --
> 2.33.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] nilfs2: remove redundant pointer sbufs
@ 2021-12-12 15:51 ` Ryusuke Konishi
0 siblings, 0 replies; 6+ messages in thread
From: Ryusuke Konishi @ 2021-12-12 15:51 UTC (permalink / raw)
To: Colin Ian King; +Cc: linux-nilfs, kernel-janitors-u79uwXL29TY76Z2rM5mHXA, LKML
On Sun, Dec 12, 2021 at 3:09 AM Colin Ian King <colin.i.king-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
> Pointer sbufs is being assigned a value but it's not being used
> later on. The pointer is redundant and can be removed. Cleans up
> scan-build static analysis warning:
>
> fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
> is used in the enclosing expression, the value is never actually read
> from 'sbufs' [deadcode.DeadStores]
> sbh = sbufs = page_buffers(src);
>
> Signed-off-by: Colin Ian King <colin.i.king-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Looks good.
Will apply, thank you.
Ryusuke Konishi
> ---
> fs/nilfs2/page.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
> index bc3e2cd4117f..063dd16d75b5 100644
> --- a/fs/nilfs2/page.c
> +++ b/fs/nilfs2/page.c
> @@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
> */
> static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
> {
> - struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
> + struct buffer_head *dbh, *dbufs, *sbh;
> unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
>
> BUG_ON(PageWriteback(dst));
>
> - sbh = sbufs = page_buffers(src);
> + sbh = page_buffers(src);
> if (!page_has_buffers(dst))
> create_empty_buffers(dst, sbh->b_size, 0);
>
> --
> 2.33.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] nilfs2: remove redundant pointer sbufs
@ 2021-12-11 18:09 Colin Ian King
2021-12-12 15:51 ` Ryusuke Konishi
0 siblings, 1 reply; 6+ messages in thread
From: Colin Ian King @ 2021-12-11 18:09 UTC (permalink / raw)
To: Ryusuke Konishi, linux-nilfs; +Cc: kernel-janitors, linux-kernel
Pointer sbufs is being assigned a value but it's not being used
later on. The pointer is redundant and can be removed. Cleans up
scan-build static analysis warning:
fs/nilfs2/page.c:203:8: warning: Although the value stored to 'sbufs'
is used in the enclosing expression, the value is never actually read
from 'sbufs' [deadcode.DeadStores]
sbh = sbufs = page_buffers(src);
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
fs/nilfs2/page.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
index bc3e2cd4117f..063dd16d75b5 100644
--- a/fs/nilfs2/page.c
+++ b/fs/nilfs2/page.c
@@ -195,12 +195,12 @@ void nilfs_page_bug(struct page *page)
*/
static void nilfs_copy_page(struct page *dst, struct page *src, int copy_dirty)
{
- struct buffer_head *dbh, *dbufs, *sbh, *sbufs;
+ struct buffer_head *dbh, *dbufs, *sbh;
unsigned long mask = NILFS_BUFFER_INHERENT_BITS;
BUG_ON(PageWriteback(dst));
- sbh = sbufs = page_buffers(src);
+ sbh = page_buffers(src);
if (!page_has_buffers(dst))
create_empty_buffers(dst, sbh->b_size, 0);
--
2.33.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-12-28 17:38 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-28 17:27 [PATCH] nilfs2: remove redundant pointer sbufs Ryusuke Konishi
2021-12-28 17:27 ` Ryusuke Konishi
2021-12-28 17:37 ` Ryusuke Konishi
-- strict thread matches above, loose matches on Subject: below --
2021-12-11 18:09 Colin Ian King
2021-12-12 15:51 ` Ryusuke Konishi
2021-12-12 15:51 ` Ryusuke Konishi
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.