linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [akpm-mm:mm-unstable 360/372] include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr'
@ 2024-04-11  4:25 kernel test robot
  2024-04-11  4:36 ` Barry Song
  0 siblings, 1 reply; 3+ messages in thread
From: kernel test robot @ 2024-04-11  4:25 UTC (permalink / raw)
  To: Chuanhua Han
  Cc: llvm, oe-kbuild-all, Andrew Morton, Linux Memory Management List,
	Barry Song

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-unstable
head:   de14d5f2a9ff2df737a01575ee95bc5a35f5853d
commit: ca23b4d4cae5d32a9d22fb3c39550dcf43df83f9 [360/372] mm: swap: introduce swap_free_nr() for batched swap_free()
config: x86_64-allnoconfig (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202404111223.DDjEQDHj-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from arch/x86/kernel/asm-offsets.c:14:
   In file included from include/linux/suspend.h:5:
>> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         |      ^
   include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         | ^
         | static 
   1 warning generated.
--
   In file included from arch/x86/kernel/reboot.c:33:
   In file included from arch/x86/include/asm/efi.h:7:
   In file included from arch/x86/include/asm/tlb.h:8:
   In file included from include/asm-generic/tlb.h:15:
>> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         |      ^
   include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         | ^
         | static 
   arch/x86/kernel/reboot.c:972:20: warning: unused function 'nmi_shootdown_cpus_on_restart' [-Wunused-function]
     972 | static inline void nmi_shootdown_cpus_on_restart(void) { }
         |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   2 warnings generated.
--
   In file included from arch/x86/kernel/asm-offsets.c:14:
   In file included from include/linux/suspend.h:5:
>> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         |      ^
   include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
         | ^
         | static 
   1 warning generated.


vim +/swap_free_nr +565 include/linux/swap.h

   564	
 > 565	void swap_free_nr(swp_entry_t entry, int nr_pages)
   566	{
   567	}
   568	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


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

* Re: [akpm-mm:mm-unstable 360/372] include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr'
  2024-04-11  4:25 [akpm-mm:mm-unstable 360/372] include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' kernel test robot
@ 2024-04-11  4:36 ` Barry Song
  2024-04-11  9:57   ` Liu, Yujie
  0 siblings, 1 reply; 3+ messages in thread
From: Barry Song @ 2024-04-11  4:36 UTC (permalink / raw)
  To: kernel test robot
  Cc: Chuanhua Han, llvm, oe-kbuild-all, Andrew Morton,
	Linux Memory Management List, Barry Song

On Thu, Apr 11, 2024 at 4:27 PM kernel test robot <lkp@intel.com> wrote:
>
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-unstable
> head:   de14d5f2a9ff2df737a01575ee95bc5a35f5853d
> commit: ca23b4d4cae5d32a9d22fb3c39550dcf43df83f9 [360/372] mm: swap: introduce swap_free_nr() for batched swap_free()
> config: x86_64-allnoconfig (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/config)
> compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/reproduce)
>
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202404111223.DDjEQDHj-lkp@intel.com/
>
> All warnings (new ones prefixed by >>):
>
>    In file included from arch/x86/kernel/asm-offsets.c:14:
>    In file included from include/linux/suspend.h:5:
> >> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          |      ^
>    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          | ^
>          | static
>    1 warning generated.
> --
>    In file included from arch/x86/kernel/reboot.c:33:
>    In file included from arch/x86/include/asm/efi.h:7:
>    In file included from arch/x86/include/asm/tlb.h:8:
>    In file included from include/asm-generic/tlb.h:15:
> >> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          |      ^
>    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          | ^
>          | static
>    arch/x86/kernel/reboot.c:972:20: warning: unused function 'nmi_shootdown_cpus_on_restart' [-Wunused-function]
>      972 | static inline void nmi_shootdown_cpus_on_restart(void) { }
>          |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>    2 warnings generated.
> --
>    In file included from arch/x86/kernel/asm-offsets.c:14:
>    In file included from include/linux/suspend.h:5:
> >> include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          |      ^
>    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
>          | ^
>          | static
>    1 warning generated.
>
>
> vim +/swap_free_nr +565 include/linux/swap.h
>
>    564
>  > 565  void swap_free_nr(swp_entry_t entry, int nr_pages)
>    566  {
>    567  }
>    568

Hi,
thank you!

SeongJae reported this and fixed it with a patch here:
https://lore.kernel.org/linux-mm/20240410233759.274907-1-sj@kernel.org/

Can you please test it?

 >
> --
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki
>


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

* Re: [akpm-mm:mm-unstable 360/372] include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr'
  2024-04-11  4:36 ` Barry Song
@ 2024-04-11  9:57   ` Liu, Yujie
  0 siblings, 0 replies; 3+ messages in thread
From: Liu, Yujie @ 2024-04-11  9:57 UTC (permalink / raw)
  To: 21cnbao, lkp
  Cc: v-songbaohua, linux-mm, hanchuanhua, llvm, oe-kbuild-all, akpm

On Thu, 2024-04-11 at 16:36 +1200, Barry Song wrote:
> On Thu, Apr 11, 2024 at 4:27 PM kernel test robot <lkp@intel.com> wrote:
> > 
> > tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-unstable
> > head:   de14d5f2a9ff2df737a01575ee95bc5a35f5853d
> > commit: ca23b4d4cae5d32a9d22fb3c39550dcf43df83f9 [360/372] mm: swap: introduce swap_free_nr() for batched swap_free()
> > config: x86_64-allnoconfig (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/config)
> > compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
> > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240411/202404111223.DDjEQDHj-lkp@intel.com/reproduce)
> > 
> > If you fix the issue in a separate patch/commit (i.e. not just a new version of
> > the same patch/commit), kindly add following tags
> > > Reported-by: kernel test robot <lkp@intel.com>
> > > Closes: https://lore.kernel.org/oe-kbuild-all/202404111223.DDjEQDHj-lkp@intel.com/
> > 
> > All warnings (new ones prefixed by >>):
> > 
> >    In file included from arch/x86/kernel/asm-offsets.c:14:
> >    In file included from include/linux/suspend.h:5:
> > > > include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          |      ^
> >    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          | ^
> >          | static
> >    1 warning generated.
> > --
> >    In file included from arch/x86/kernel/reboot.c:33:
> >    In file included from arch/x86/include/asm/efi.h:7:
> >    In file included from arch/x86/include/asm/tlb.h:8:
> >    In file included from include/asm-generic/tlb.h:15:
> > > > include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          |      ^
> >    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          | ^
> >          | static
> >    arch/x86/kernel/reboot.c:972:20: warning: unused function 'nmi_shootdown_cpus_on_restart' [-Wunused-function]
> >      972 | static inline void nmi_shootdown_cpus_on_restart(void) { }
> >          |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >    2 warnings generated.
> > --
> >    In file included from arch/x86/kernel/asm-offsets.c:14:
> >    In file included from include/linux/suspend.h:5:
> > > > include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' [-Wmissing-prototypes]
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          |      ^
> >    include/linux/swap.h:565:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> >      565 | void swap_free_nr(swp_entry_t entry, int nr_pages)
> >          | ^
> >          | static
> >    1 warning generated.
> > 
> > 
> > vim +/swap_free_nr +565 include/linux/swap.h
> > 
> >    564
> >  > 565  void swap_free_nr(swp_entry_t entry, int nr_pages)
> >    566  {
> >    567  }
> >    568
> 
> Hi,
> thank you!
> 
> SeongJae reported this and fixed it with a patch here:
> https://lore.kernel.org/linux-mm/20240410233759.274907-1-sj@kernel.org/
> 
> Can you please test it?

We tested SJ's patch and it fixes the build issues in this report.

Tested-by: Yujie Liu <yujie.liu@intel.com>

Thanks

>  >
> > --
> > 0-DAY CI Kernel Test Service
> > https://github.com/intel/lkp-tests/wiki
> > 
> 


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

end of thread, other threads:[~2024-04-11  9:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-11  4:25 [akpm-mm:mm-unstable 360/372] include/linux/swap.h:565:6: warning: no previous prototype for function 'swap_free_nr' kernel test robot
2024-04-11  4:36 ` Barry Song
2024-04-11  9:57   ` Liu, Yujie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox