public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
* [bcachefs:bcachefs-testing 60/60] fs/bcachefs/error.c:121:3: warning: label followed by a declaration is a C23 extension
@ 2024-06-03  5:01 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-06-03  5:01 UTC (permalink / raw)
  To: Kent Overstreet; +Cc: llvm, oe-kbuild-all, Kent Overstreet

tree:   https://evilpiepirate.org/git/bcachefs.git bcachefs-testing
head:   567b09eb98ef6d174e26c491b35ac086f133fa2f
commit: 567b09eb98ef6d174e26c491b35ac086f133fa2f [60/60] bcachefs: Unlock trans when waiting for user input in fsck
config: hexagon-allmodconfig (https://download.01.org/0day-ci/archive/20240603/202406031346.mFOD4vkX-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project bafda89a0944d947fc4b3b5663185e07a397ac30)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240603/202406031346.mFOD4vkX-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/202406031346.mFOD4vkX-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from fs/bcachefs/error.c:2:
   In file included from fs/bcachefs/bcachefs.h:188:
   In file included from include/linux/bio.h:10:
   In file included from include/linux/blk_types.h:10:
   In file included from include/linux/bvec.h:10:
   In file included from include/linux/highmem.h:10:
   In file included from include/linux/mm.h:2253:
   include/linux/vmstat.h:514:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
     514 |         return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
         |                               ~~~~~~~~~~~ ^ ~~~
   In file included from fs/bcachefs/error.c:2:
   In file included from fs/bcachefs/bcachefs.h:188:
   In file included from include/linux/bio.h:10:
   In file included from include/linux/blk_types.h:10:
   In file included from include/linux/bvec.h:10:
   In file included from include/linux/highmem.h:12:
   In file included from include/linux/hardirq.h:11:
   In file included from ./arch/hexagon/include/generated/asm/hardirq.h:1:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:14:
   In file included from arch/hexagon/include/asm/io.h:328:
   include/asm-generic/io.h:548:31: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     548 |         val = __raw_readb(PCI_IOBASE + addr);
         |                           ~~~~~~~~~~ ^
   include/asm-generic/io.h:561:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     561 |         val = __le16_to_cpu((__le16 __force)__raw_readw(PCI_IOBASE + addr));
         |                                                         ~~~~~~~~~~ ^
   include/uapi/linux/byteorder/little_endian.h:37:51: note: expanded from macro '__le16_to_cpu'
      37 | #define __le16_to_cpu(x) ((__force __u16)(__le16)(x))
         |                                                   ^
   In file included from fs/bcachefs/error.c:2:
   In file included from fs/bcachefs/bcachefs.h:188:
   In file included from include/linux/bio.h:10:
   In file included from include/linux/blk_types.h:10:
   In file included from include/linux/bvec.h:10:
   In file included from include/linux/highmem.h:12:
   In file included from include/linux/hardirq.h:11:
   In file included from ./arch/hexagon/include/generated/asm/hardirq.h:1:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:14:
   In file included from arch/hexagon/include/asm/io.h:328:
   include/asm-generic/io.h:574:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     574 |         val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
         |                                                         ~~~~~~~~~~ ^
   include/uapi/linux/byteorder/little_endian.h:35:51: note: expanded from macro '__le32_to_cpu'
      35 | #define __le32_to_cpu(x) ((__force __u32)(__le32)(x))
         |                                                   ^
   In file included from fs/bcachefs/error.c:2:
   In file included from fs/bcachefs/bcachefs.h:188:
   In file included from include/linux/bio.h:10:
   In file included from include/linux/blk_types.h:10:
   In file included from include/linux/bvec.h:10:
   In file included from include/linux/highmem.h:12:
   In file included from include/linux/hardirq.h:11:
   In file included from ./arch/hexagon/include/generated/asm/hardirq.h:1:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:14:
   In file included from arch/hexagon/include/asm/io.h:328:
   include/asm-generic/io.h:585:33: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     585 |         __raw_writeb(value, PCI_IOBASE + addr);
         |                             ~~~~~~~~~~ ^
   include/asm-generic/io.h:595:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     595 |         __raw_writew((u16 __force)cpu_to_le16(value), PCI_IOBASE + addr);
         |                                                       ~~~~~~~~~~ ^
   include/asm-generic/io.h:605:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
     605 |         __raw_writel((u32 __force)cpu_to_le32(value), PCI_IOBASE + addr);
         |                                                       ~~~~~~~~~~ ^
>> fs/bcachefs/error.c:121:3: warning: label followed by a declaration is a C23 extension [-Wc23-extensions]
     121 |                 unsigned long t = unlock_long_at
         |                 ^
   8 warnings generated.


vim +121 fs/bcachefs/error.c

    99	
   100	#ifdef __KERNEL__
   101	static enum ask_yn bch2_fsck_ask_yn(struct bch_fs *c, struct btree_trans *trans)
   102	{
   103		struct stdio_redirect *stdio = c->stdio;
   104	
   105		if (c->stdio_filter && c->stdio_filter != current)
   106			stdio = NULL;
   107	
   108		if (!stdio)
   109			return YN_NO;
   110	
   111		if (trans)
   112			bch2_trans_unlock(trans);
   113	
   114		unsigned long unlock_long_at = trans ? jiffies + HZ * 2 : 0;
   115		darray_char line = {};
   116		int ret;
   117	
   118		do {
   119			bch2_print(c, " (y,n, or Y,N for all errors of this type) ");
   120	rewait:
 > 121			unsigned long t = unlock_long_at
   122				? max_t(long, unlock_long_at - jiffies, 0)
   123				: MAX_SCHEDULE_TIMEOUT;
   124	
   125			int r = bch2_stdio_redirect_readline_timeout(stdio, &line, t);
   126			if (r == -ETIME) {
   127				bch2_trans_unlock_long(trans);
   128				unlock_long_at = 0;
   129				goto rewait;
   130			}
   131	
   132			if (r < 0) {
   133				ret = YN_NO;
   134				break;
   135			}
   136	
   137			darray_last(line) = '\0';
   138		} while ((ret = parse_yn_response(line.data)) < 0);
   139	
   140		darray_exit(&line);
   141		return ret;
   142	}
   143	#else
   144	

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-06-03  5:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-03  5:01 [bcachefs:bcachefs-testing 60/60] fs/bcachefs/error.c:121:3: warning: label followed by a declaration is a C23 extension kernel test robot

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