linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [akpm-mm:mm-unstable 333/334] include/linux/mmzone.h:1816:8: warning: left shift count is negative
@ 2025-05-09  7:48 kernel test robot
  2025-05-09 20:43 ` Juan Yescas
  0 siblings, 1 reply; 4+ messages in thread
From: kernel test robot @ 2025-05-09  7:48 UTC (permalink / raw)
  To: Juan Yescas; +Cc: oe-kbuild-all, Andrew Morton, Linux Memory Management List

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-unstable
head:   930c125f685d7e8eef566fcd563390b76a28d824
commit: 16994f2b09a22523885d371caa59f17999686805 [333/334] mm: add CONFIG_PAGE_BLOCK_ORDER to select page block order
config: powerpc64-randconfig-003-20250509 (https://download.01.org/0day-ci/archive/20250509/202505091548.FuKO4b4v-lkp@intel.com/config)
compiler: powerpc64-linux-gcc (GCC) 10.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250509/202505091548.FuKO4b4v-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/202505091548.FuKO4b4v-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from include/vdso/const.h:5,
                    from include/linux/const.h:4,
                    from include/linux/bits.h:5,
                    from include/linux/ratelimit_types.h:5,
                    from include/linux/printk.h:9,
                    from include/asm-generic/bug.h:22,
                    from arch/powerpc/include/asm/bug.h:116,
                    from include/linux/bug.h:5,
                    from include/linux/mmdebug.h:5,
                    from include/linux/mm.h:6,
                    from mm/sparse.c:5:
   mm/sparse.c: In function 'usemap_size':
>> include/linux/mmzone.h:1816:8: warning: left shift count is negative [-Wshift-count-negative]
    1816 |  ((1UL << (PFN_SECTION_SHIFT - pageblock_order)) * NR_PAGEBLOCK_BITS)
         |        ^~
   include/uapi/linux/const.h:51:40: note: in definition of macro '__KERNEL_DIV_ROUND_UP'
      51 | #define __KERNEL_DIV_ROUND_UP(n, d) (((n) + (d) - 1) / (d))
         |                                        ^
   mm/sparse.c:301:9: note: in expansion of macro 'BITS_TO_LONGS'
     301 |  return BITS_TO_LONGS(SECTION_BLOCKFLAGS_BITS) * sizeof(unsigned long);
         |         ^~~~~~~~~~~~~
   mm/sparse.c:301:23: note: in expansion of macro 'SECTION_BLOCKFLAGS_BITS'
     301 |  return BITS_TO_LONGS(SECTION_BLOCKFLAGS_BITS) * sizeof(unsigned long);
         |                       ^~~~~~~~~~~~~~~~~~~~~~~


vim +1816 include/linux/mmzone.h

d41dee369bff3b Andy Whitcroft 2005-06-23  1814  
835c134ec4dd75 Mel Gorman     2007-10-16  1815  #define SECTION_BLOCKFLAGS_BITS \
d9c2340052278d Mel Gorman     2007-10-16 @1816  	((1UL << (PFN_SECTION_SHIFT - pageblock_order)) * NR_PAGEBLOCK_BITS)
835c134ec4dd75 Mel Gorman     2007-10-16  1817  

:::::: The code at line 1816 was first introduced by commit
:::::: d9c2340052278d8eb2ffb16b0484f8f794def4de Do not depend on MAX_ORDER when grouping pages by mobility

:::::: TO: Mel Gorman <mel@csn.ul.ie>
:::::: CC: Linus Torvalds <torvalds@woody.linux-foundation.org>

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


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

end of thread, other threads:[~2025-05-12 19:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-05-09  7:48 [akpm-mm:mm-unstable 333/334] include/linux/mmzone.h:1816:8: warning: left shift count is negative kernel test robot
2025-05-09 20:43 ` Juan Yescas
2025-05-12  1:10   ` Philip Li
2025-05-12 19:06     ` Juan Yescas

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