All of lore.kernel.org
 help / color / mirror / Atom feed
* [djwong-xfs:xfile-page-caching 185/274] fs/xfs/xfs_health.c:511 xfs_btree_mark_sick() warn: bitwise AND condition is false here
@ 2023-03-17  7:30 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-03-17  7:30 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp, Dan Carpenter

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: "Darrick J. Wong" <darrick.wong@oracle.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git xfile-page-caching
head:   67bb67e9a9941400f950d75d77991bf99c54ed05
commit: ae51167d499b9ebb1db39a608b3948f43d6fad28 [185/274] xfs: support in-memory btrees
:::::: branch date: 2 days ago
:::::: commit date: 2 days ago
config: ia64-randconfig-m031-20230312 (https://download.01.org/0day-ci/archive/20230317/202303171552.nXhSeyBh-lkp@intel.com/config)
compiler: ia64-linux-gcc (GCC) 12.1.0

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Link: https://lore.kernel.org/r/202303171552.nXhSeyBh-lkp@intel.com/

New smatch warnings:
fs/xfs/xfs_health.c:511 xfs_btree_mark_sick() warn: bitwise AND condition is false here
fs/xfs/xfs_buf.c:2495 xfs_buftarg_nr_sectors() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:163 __xfs_btree_check_lblock() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:88 xfs_btree_check_lblock_siblings() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:232 __xfs_btree_check_sblock() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:118 xfs_btree_check_sblock_siblings() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:294 xfs_btree_check_lptr() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:308 xfs_btree_check_sptr() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:324 xfs_btree_check_ptr() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:484 xfs_btree_del_cursor() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:498 xfs_btree_buftarg() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:508 xfs_btree_bbsize() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:995 xfs_btree_readahead_lblock() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:1023 xfs_btree_readahead_sblock() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:1086 xfs_btree_ptr_to_daddr() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:1295 xfs_btree_init_block_cur() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:1337 xfs_btree_buf_to_ptr() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:1878 xfs_btree_check_block_owner() warn: bitwise AND condition is false here

Old smatch warnings:
fs/xfs/xfs_buf.c:745 xfs_buf_get_map() error: we previously assumed 'bp' could be null (see line 727)
fs/xfs/xfs_buf.c:1638 _xfs_buf_ioapply() warn: bitwise AND condition is false here
fs/xfs/xfs_buf.c:2012 xfs_free_buftarg() warn: bitwise AND condition is false here
fs/xfs/libxfs/xfs_btree.c:486 xfs_btree_del_cursor() warn: bitwise AND condition is false here

vim +511 fs/xfs/xfs_health.c

63aada3d098b77 Darrick J. Wong 2023-03-06  503  
63aada3d098b77 Darrick J. Wong 2023-03-06  504  /* Record observations of btree corruption with the health tracking system. */
63aada3d098b77 Darrick J. Wong 2023-03-06  505  void
63aada3d098b77 Darrick J. Wong 2023-03-06  506  xfs_btree_mark_sick(
63aada3d098b77 Darrick J. Wong 2023-03-06  507  	struct xfs_btree_cur		*cur)
63aada3d098b77 Darrick J. Wong 2023-03-06  508  {
63aada3d098b77 Darrick J. Wong 2023-03-06  509  	unsigned int			mask;
63aada3d098b77 Darrick J. Wong 2023-03-06  510  
ae51167d499b9e Darrick J. Wong 2023-03-06 @511  	if (cur->bc_flags & XFS_BTREE_IN_XFILE)
ae51167d499b9e Darrick J. Wong 2023-03-06  512  		return;
ae51167d499b9e Darrick J. Wong 2023-03-06  513  
63aada3d098b77 Darrick J. Wong 2023-03-06  514  	switch (cur->bc_btnum) {
63aada3d098b77 Darrick J. Wong 2023-03-06  515  	case XFS_BTNUM_BMAP:
63aada3d098b77 Darrick J. Wong 2023-03-06  516  		xfs_bmap_mark_sick(cur->bc_ino.ip, cur->bc_ino.whichfork);
63aada3d098b77 Darrick J. Wong 2023-03-06  517  		return;
63aada3d098b77 Darrick J. Wong 2023-03-06  518  	case XFS_BTNUM_BNO:
63aada3d098b77 Darrick J. Wong 2023-03-06  519  		mask = XFS_SICK_AG_BNOBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  520  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  521  	case XFS_BTNUM_CNT:
63aada3d098b77 Darrick J. Wong 2023-03-06  522  		mask = XFS_SICK_AG_CNTBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  523  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  524  	case XFS_BTNUM_INO:
63aada3d098b77 Darrick J. Wong 2023-03-06  525  		mask = XFS_SICK_AG_INOBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  526  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  527  	case XFS_BTNUM_FINO:
63aada3d098b77 Darrick J. Wong 2023-03-06  528  		mask = XFS_SICK_AG_FINOBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  529  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  530  	case XFS_BTNUM_RMAP:
63aada3d098b77 Darrick J. Wong 2023-03-06  531  		mask = XFS_SICK_AG_RMAPBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  532  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  533  	case XFS_BTNUM_REFC:
63aada3d098b77 Darrick J. Wong 2023-03-06  534  		mask = XFS_SICK_AG_REFCNTBT;
63aada3d098b77 Darrick J. Wong 2023-03-06  535  		break;
63aada3d098b77 Darrick J. Wong 2023-03-06  536  	default:
63aada3d098b77 Darrick J. Wong 2023-03-06  537  		ASSERT(0);
63aada3d098b77 Darrick J. Wong 2023-03-06  538  		return;
63aada3d098b77 Darrick J. Wong 2023-03-06  539  	}
63aada3d098b77 Darrick J. Wong 2023-03-06  540  
63aada3d098b77 Darrick J. Wong 2023-03-06  541  	xfs_ag_mark_sick(cur->bc_ag.pag, mask);
63aada3d098b77 Darrick J. Wong 2023-03-06  542  }
a7408201d76488 Darrick J. Wong 2023-03-06  543  

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

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

only message in thread, other threads:[~2023-03-17  7:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-17  7:30 [djwong-xfs:xfile-page-caching 185/274] fs/xfs/xfs_health.c:511 xfs_btree_mark_sick() warn: bitwise AND condition is false here kernel test robot

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.