Re: [PATCH 4/9] btrfs: use assertion helpers for spinning readers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Mar 16, 2019 at 12:18:30AM +0800, kbuild test robot wrote:
> Hi David,
> 
> I love your patch! Yet something to improve:
> 
> [auto build test ERROR on kdave/for-next]
> [also build test ERROR on next-20190306]
> [cannot apply to v5.0]
> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
> 
> url:    https://github.com/0day-ci/linux/commits/David-Sterba/Extent-buffer-locking-cleanups/20190315-231346
> base:   https://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux.git for-next
> config: i386-randconfig-x011-201910 (attached as .config)
> compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
> reproduce:
>         # save the attached .config to linux build tree
>         make ARCH=i386 
> 
> All errors (new ones prefixed by >>):
> 
>    fs/btrfs/locking.c: In function 'btrfs_clear_lock_blocking_read':
> >> fs/btrfs/locking.c:97:18: error: 'struct extent_buffer' has no member named 'spinning_readers'; did you mean 'blocking_readers'?
>      atomic_inc(&eb->spinning_readers);
>                      ^~~~~~~~~~~~~~~~
>                      blocking_readers
> 
> vim +97 fs/btrfs/locking.c
> 
> b4ce94de Chris Mason  2009-02-04   85  
> aa12c027 David Sterba 2018-04-04   86  void btrfs_clear_lock_blocking_read(struct extent_buffer *eb)
> aa12c027 David Sterba 2018-04-04   87  {
> b4ce94de Chris Mason  2009-02-04   88  	/*
> aa12c027 David Sterba 2018-04-04   89  	 * No lock is required.  The lock owner may change if we have a read
> aa12c027 David Sterba 2018-04-04   90  	 * lock, but it won't change to or away from us.  If we have the write
> aa12c027 David Sterba 2018-04-04   91  	 * lock, we are the owner and it'll never change.
> b4ce94de Chris Mason  2009-02-04   92  	 */
> aa12c027 David Sterba 2018-04-04   93  	if (eb->lock_nested && current->pid == eb->lock_owner)
> aa12c027 David Sterba 2018-04-04   94  		return;
> aa12c027 David Sterba 2018-04-04   95  	BUG_ON(atomic_read(&eb->blocking_readers) == 0);
> aa12c027 David Sterba 2018-04-04   96  	read_lock(&eb->lock);
> aa12c027 David Sterba 2018-04-04  @97  	atomic_inc(&eb->spinning_readers);

Thanks for the report.  There's the right code in my branch that
compiles (and also got tested), with and without the config option, so I
must have sent branch with the uncommited fixup.



[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux