linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [linux-next:master 9529/10007] mm/hugetlb.c:1591:9: warning: no previous prototype for function 'hugetlb_basepage_index'
@ 2021-06-15 15:58 kernel test robot
  2021-06-15 16:03 ` Matthew Wilcox
  0 siblings, 1 reply; 6+ messages in thread
From: kernel test robot @ 2021-06-15 15:58 UTC (permalink / raw)
  To: Hugh Dickins
  Cc: kbuild-all, clang-built-linux, Linux Memory Management List,
	Matthew Wilcox (Oracle), Andrew Morton

[-- Attachment #1: Type: text/plain, Size: 2506 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   19ae1f2bd9c091059f80646604ccef8a1e614f57
commit: 1878ae46bd82ef0403393aee4935f29c07d5848b [9529/10007] mm, futex: fix shared futex pgoff on shmem huge page
config: arm64-randconfig-r014-20210615 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 64720f57bea6a6bf033feef4a5751ab9c0c3b401)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install arm64 cross compiling tool for clang build
        # apt-get install binutils-aarch64-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=1878ae46bd82ef0403393aee4935f29c07d5848b
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 1878ae46bd82ef0403393aee4935f29c07d5848b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> mm/hugetlb.c:1591:9: warning: no previous prototype for function 'hugetlb_basepage_index' [-Wmissing-prototypes]
   pgoff_t hugetlb_basepage_index(struct page *page)
           ^
   mm/hugetlb.c:1591:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   pgoff_t hugetlb_basepage_index(struct page *page)
   ^
   static 
   include/linux/types.h:131:17: note: expanded from macro 'pgoff_t'
   #define pgoff_t unsigned long
                   ^
   1 warning generated.


vim +/hugetlb_basepage_index +1591 mm/hugetlb.c

  1590	
> 1591	pgoff_t hugetlb_basepage_index(struct page *page)
  1592	{
  1593		struct page *page_head = compound_head(page);
  1594		pgoff_t index = page_index(page_head);
  1595		unsigned long compound_idx;
  1596	
  1597		if (compound_order(page_head) >= MAX_ORDER)
  1598			compound_idx = page_to_pfn(page) - page_to_pfn(page_head);
  1599		else
  1600			compound_idx = page - page_head;
  1601	
  1602		return (index << compound_order(page_head)) + compound_idx;
  1603	}
  1604	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39030 bytes --]

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

end of thread, other threads:[~2021-06-15 23:37 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-15 15:58 [linux-next:master 9529/10007] mm/hugetlb.c:1591:9: warning: no previous prototype for function 'hugetlb_basepage_index' kernel test robot
2021-06-15 16:03 ` Matthew Wilcox
2021-06-15 18:32   ` Nathan Chancellor
2021-06-15 18:50     ` Nick Desaulniers
2021-06-15 19:01       ` Matthew Wilcox
2021-06-15 23:37         ` Hugh Dickins

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).