[bug report] ext4, project: expand inode extra size if possible

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

 



Hello Miao Xie,

The patch c03b45b853f5: "ext4, project: expand inode extra size if
possible" from Aug 6, 2017, leads to the following static checker
warning:

    fs/ext4/inode.c:5708 ext4_expand_extra_isize()
    warn: inconsistent returns 'EXT4_I(inode)->xattr_sem'.
      Locked on  : 5708
      Unlocked on: 5708

fs/ext4/inode.c
  5681          handle = ext4_journal_start(inode, EXT4_HT_INODE,
  5682                                      EXT4_DATA_TRANS_BLOCKS(inode->i_sb));
  5683          if (IS_ERR(handle)) {
  5684                  error = PTR_ERR(handle);
  5685                  brelse(iloc->bh);
  5686                  return error;
  5687          }
  5688  
  5689          ext4_write_lock_xattr(inode, &no_expand);
  5690  
  5691          BUFFER_TRACE(iloc->bh, "get_write_access");
  5692          error = ext4_journal_get_write_access(handle, iloc->bh);
  5693          if (error) {
  5694                  brelse(iloc->bh);
  5695                  goto out_stop;

Shouldn't this goto the ext4_write_unlock_xattr()?

  5696          }
  5697  
  5698          error = __ext4_expand_extra_isize(inode, new_extra_isize, iloc,
  5699                                            handle, &no_expand);
  5700  
  5701          rc = ext4_mark_iloc_dirty(handle, inode, iloc);
  5702          if (!error)
  5703                  error = rc;
  5704  
  5705          ext4_write_unlock_xattr(inode, &no_expand);
  5706  out_stop:
  5707          ext4_journal_stop(handle);
  5708          return error;
  5709  }


regards,
dan carpenter



[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux