]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ext4: add lockdep annotations for i_data_sem
authorTheodore Ts'o <tytso@mit.edu>
Fri, 1 Apr 2016 05:31:28 +0000 (01:31 -0400)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 26 May 2016 22:46:44 +0000 (15:46 -0700)
commitb76545f14356dce6dd2da8a34002bc73790b9754
tree20f409d165c2bb7ebc8ecba1361048fc83919713
parent91aca509929f05840d6a93550eea4c5f0630d9c0
ext4: add lockdep annotations for i_data_sem

Orabug: 23331167

[ Upstream commit daf647d2dd58cec59570d7698a45b98e580f2076 ]

With the internal Quota feature, mke2fs creates empty quota inodes and
quota usage tracking is enabled as soon as the file system is mounted.
Since quotacheck is no longer preallocating all of the blocks in the
quota inode that are likely needed to be written to, we are now seeing
a lockdep false positive caused by needing to allocate a quota block
from inside ext4_map_blocks(), while holding i_data_sem for a data
inode.  This results in this complaint:

  Possible unsafe locking scenario:

        CPU0                    CPU1
        ----                    ----
   lock(&ei->i_data_sem);
                                lock(&s->s_dquot.dqio_mutex);
                                lock(&ei->i_data_sem);
   lock(&s->s_dquot.dqio_mutex);

Google-Bug-Id: 27907753

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@vger.kernel.org
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit 031b34ddc5b7714d957f7e8ed229e1c1a4c22a8f)

Signed-off-by: Dan Duval <dan.duval@oracle.com>
fs/ext4/ext4.h
fs/ext4/move_extent.c
fs/ext4/super.c