All of lore.kernel.org
 help / color / mirror / Atom feed
* [f2fs-dev] [PATCH] f2fs: compress: make num_compress_pages and f2fs_compress_free_page static
@ 2020-05-11 11:51 Ma Feng
  2020-05-12  1:48 ` Chao Yu
  0 siblings, 1 reply; 3+ messages in thread
From: Ma Feng @ 2020-05-11 11:51 UTC (permalink / raw)
  To: chao, jaegeuk; +Cc: Ma Feng, linux-f2fs-devel

Fix the following sparse warning:

fs/f2fs/compress.c:501:5: warning: symbol 'num_compress_pages' was not declared.
 Should it be static?
fs/f2fs/compress.c:530:6: warning: symbol 'f2fs_compress_free_page' was not
declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Ma Feng <mafeng.ma@huawei.com>
---
 fs/f2fs/compress.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c
index 4c7eaee..c7c5a8f 100644
--- a/fs/f2fs/compress.c
+++ b/fs/f2fs/compress.c
@@ -498,7 +498,7 @@ bool f2fs_is_compress_backend_ready(struct inode *inode)
 }

 static mempool_t *compress_page_pool = NULL;
-int num_compress_pages = 512;
+static int num_compress_pages = 512;
 module_param(num_compress_pages, uint, 0444);
 MODULE_PARM_DESC(num_compress_pages,
 		"Number of intermediate compress pages to preallocate");
@@ -527,7 +527,7 @@ static struct page *f2fs_compress_alloc_page(void)
 	return page;
 }

-void f2fs_compress_free_page(struct page *page)
+static void f2fs_compress_free_page(struct page *page)
 {
 	if (!page)
 		return;
--
2.6.2



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [f2fs-dev] [PATCH] f2fs: compress: make num_compress_pages and f2fs_compress_free_page static
  2020-05-11 11:51 [f2fs-dev] [PATCH] f2fs: compress: make num_compress_pages and f2fs_compress_free_page static Ma Feng
@ 2020-05-12  1:48 ` Chao Yu
  2020-05-12  3:38   ` Jaegeuk Kim
  0 siblings, 1 reply; 3+ messages in thread
From: Chao Yu @ 2020-05-12  1:48 UTC (permalink / raw)
  To: Ma Feng, chao, jaegeuk; +Cc: linux-f2fs-devel

Hello Ma,

On 2020/5/11 19:51, Ma Feng wrote:
> Fix the following sparse warning:
> 
> fs/f2fs/compress.c:501:5: warning: symbol 'num_compress_pages' was not declared.
>  Should it be static?
> fs/f2fs/compress.c:530:6: warning: symbol 'f2fs_compress_free_page' was not
> declared. Should it be static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Ma Feng <mafeng.ma@huawei.com>

Thanks for fixing this.

It's better to merge this into original patch, let me know if you mind it.

Thanks,

> ---
>  fs/f2fs/compress.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c
> index 4c7eaee..c7c5a8f 100644
> --- a/fs/f2fs/compress.c
> +++ b/fs/f2fs/compress.c
> @@ -498,7 +498,7 @@ bool f2fs_is_compress_backend_ready(struct inode *inode)
>  }
> 
>  static mempool_t *compress_page_pool = NULL;
> -int num_compress_pages = 512;
> +static int num_compress_pages = 512;
>  module_param(num_compress_pages, uint, 0444);
>  MODULE_PARM_DESC(num_compress_pages,
>  		"Number of intermediate compress pages to preallocate");
> @@ -527,7 +527,7 @@ static struct page *f2fs_compress_alloc_page(void)
>  	return page;
>  }
> 
> -void f2fs_compress_free_page(struct page *page)
> +static void f2fs_compress_free_page(struct page *page)
>  {
>  	if (!page)
>  		return;
> --
> 2.6.2
> 
> 
> 
> _______________________________________________
> Linux-f2fs-devel mailing list
> Linux-f2fs-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
> .
> 


_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [f2fs-dev] [PATCH] f2fs: compress: make num_compress_pages and f2fs_compress_free_page static
  2020-05-12  1:48 ` Chao Yu
@ 2020-05-12  3:38   ` Jaegeuk Kim
  0 siblings, 0 replies; 3+ messages in thread
From: Jaegeuk Kim @ 2020-05-12  3:38 UTC (permalink / raw)
  To: Chao Yu; +Cc: Ma Feng, linux-f2fs-devel

On 05/12, Chao Yu wrote:
> Hello Ma,
> 
> On 2020/5/11 19:51, Ma Feng wrote:
> > Fix the following sparse warning:
> > 
> > fs/f2fs/compress.c:501:5: warning: symbol 'num_compress_pages' was not declared.
> >  Should it be static?
> > fs/f2fs/compress.c:530:6: warning: symbol 'f2fs_compress_free_page' was not
> > declared. Should it be static?
> > 
> > Reported-by: Hulk Robot <hulkci@huawei.com>
> > Signed-off-by: Ma Feng <mafeng.ma@huawei.com>
> 
> Thanks for fixing this.
> 
> It's better to merge this into original patch, let me know if you mind it.

Hi Ma,

Please let me know, if you have any concern on this.
https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/?h=dev&id=5e6bbde95982300d66d78fb282d4ee39df78fc33

Thanks,

> 
> Thanks,
> 
> > ---
> >  fs/f2fs/compress.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> > 
> > diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c
> > index 4c7eaee..c7c5a8f 100644
> > --- a/fs/f2fs/compress.c
> > +++ b/fs/f2fs/compress.c
> > @@ -498,7 +498,7 @@ bool f2fs_is_compress_backend_ready(struct inode *inode)
> >  }
> > 
> >  static mempool_t *compress_page_pool = NULL;
> > -int num_compress_pages = 512;
> > +static int num_compress_pages = 512;
> >  module_param(num_compress_pages, uint, 0444);
> >  MODULE_PARM_DESC(num_compress_pages,
> >  		"Number of intermediate compress pages to preallocate");
> > @@ -527,7 +527,7 @@ static struct page *f2fs_compress_alloc_page(void)
> >  	return page;
> >  }
> > 
> > -void f2fs_compress_free_page(struct page *page)
> > +static void f2fs_compress_free_page(struct page *page)
> >  {
> >  	if (!page)
> >  		return;
> > --
> > 2.6.2
> > 
> > 
> > 
> > _______________________________________________
> > Linux-f2fs-devel mailing list
> > Linux-f2fs-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
> > .
> > 


_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-05-12  3:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-11 11:51 [f2fs-dev] [PATCH] f2fs: compress: make num_compress_pages and f2fs_compress_free_page static Ma Feng
2020-05-12  1:48 ` Chao Yu
2020-05-12  3:38   ` Jaegeuk Kim

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.