fs/fs-writeback.c:1433:20: sparse: context imbalance in 'writeback_single_inode' - different lock contexts for basic block
From: kbuild test robot
Date: Tue May 09 2017 - 12:46:38 EST
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 2868b2513aa732a99ea4a0a6bf10dc93c1f3dac2
commit: d7b627277b57370223d682cede979a279284b12a radix-tree: Fix __rcu annotations
date: 3 months ago
reproduce:
# apt-get install sparse
git checkout d7b627277b57370223d682cede979a279284b12a
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__
sparse warnings: (new ones prefixed by >>)
fs/fs-writeback.c:364:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:364:9: expected void **slot
fs/fs-writeback.c:364:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:364:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:364:9: expected void **slot
fs/fs-writeback.c:364:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:366:69: sparse: incorrect type in argument 1 (different address spaces)
fs/fs-writeback.c:366:69: expected void [noderef] <asn:4>**slot
fs/fs-writeback.c:366:69: got void **slot
fs/fs-writeback.c:364:9: sparse: incorrect type in argument 1 (different address spaces)
fs/fs-writeback.c:364:9: expected void [noderef] <asn:4>**slot
fs/fs-writeback.c:364:9: got void **slot
fs/fs-writeback.c:364:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:364:9: expected void **slot
fs/fs-writeback.c:364:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:374:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:374:9: expected void **slot
fs/fs-writeback.c:374:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:374:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:374:9: expected void **slot
fs/fs-writeback.c:374:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:376:69: sparse: incorrect type in argument 1 (different address spaces)
fs/fs-writeback.c:376:69: expected void [noderef] <asn:4>**slot
fs/fs-writeback.c:376:69: got void **slot
fs/fs-writeback.c:374:9: sparse: incorrect type in argument 1 (different address spaces)
fs/fs-writeback.c:374:9: expected void [noderef] <asn:4>**slot
fs/fs-writeback.c:374:9: got void **slot
fs/fs-writeback.c:374:9: sparse: incorrect type in assignment (different address spaces)
fs/fs-writeback.c:374:9: expected void **slot
fs/fs-writeback.c:374:9: got void [noderef] <asn:4>**
fs/fs-writeback.c:536:15: sparse: context imbalance in 'wbc_attach_and_unlock_inode' - unexpected unlock
include/linux/rcupdate.h:927:9: sparse: context imbalance in 'inode_congested' - different lock contexts for basic block
>> fs/fs-writeback.c:1433:20: sparse: context imbalance in 'writeback_single_inode' - different lock contexts for basic block
fs/fs-writeback.c:1616:9: sparse: context imbalance in 'writeback_sb_inodes' - different lock contexts for basic block
fs/fs-writeback.c:2027:9: sparse: context imbalance in 'block_dump___mark_inode_dirty' - different lock contexts for basic block
vim +/writeback_single_inode +1433 fs/fs-writeback.c
4f8ad655 Jan Kara 2012-05-03 1417
cd8ed2a4 Yan Hong 2012-10-08 1418 ret = __writeback_single_inode(inode, wbc);
^1da177e Linus Torvalds 2005-04-16 1419
b16b1deb Tejun Heo 2015-06-02 1420 wbc_detach_inode(wbc);
aaf25593 Tejun Heo 2016-03-18 1421
aaf25593 Tejun Heo 2016-03-18 1422 wb = inode_to_wb_and_lock_list(inode);
250df6ed Dave Chinner 2011-03-22 1423 spin_lock(&inode->i_lock);
4f8ad655 Jan Kara 2012-05-03 1424 /*
4f8ad655 Jan Kara 2012-05-03 1425 * If inode is clean, remove it from writeback lists. Otherwise don't
4f8ad655 Jan Kara 2012-05-03 1426 * touch it. See comment above for explanation.
4f8ad655 Jan Kara 2012-05-03 1427 */
0ae45f63 Theodore Ts'o 2015-02-02 1428 if (!(inode->i_state & I_DIRTY_ALL))
c7f54084 Dave Chinner 2015-03-04 1429 inode_io_list_del_locked(inode, wb);
4f8ad655 Jan Kara 2012-05-03 1430 spin_unlock(&wb->list_lock);
1c0eeaf5 Joern Engel 2007-10-16 1431 inode_sync_complete(inode);
4f8ad655 Jan Kara 2012-05-03 1432 out:
4f8ad655 Jan Kara 2012-05-03 @1433 spin_unlock(&inode->i_lock);
^1da177e Linus Torvalds 2005-04-16 1434 return ret;
^1da177e Linus Torvalds 2005-04-16 1435 }
^1da177e Linus Torvalds 2005-04-16 1436
a88a341a Tejun Heo 2015-05-22 1437 static long writeback_chunk_size(struct bdi_writeback *wb,
1a12d8bd Wu Fengguang 2010-08-29 1438 struct wb_writeback_work *work)
d46db3d5 Wu Fengguang 2011-05-04 1439 {
d46db3d5 Wu Fengguang 2011-05-04 1440 long pages;
d46db3d5 Wu Fengguang 2011-05-04 1441
:::::: The code at line 1433 was first introduced by commit
:::::: 4f8ad655dbc82cf05d2edc11e66b78a42d38bf93 writeback: Refactor writeback_single_inode()
:::::: TO: Jan Kara <jack@xxxxxxx>
:::::: CC: Fengguang Wu <fengguang.wu@xxxxxxxxx>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation