summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2018-09-29 13:46:21 +1000
committerDave Chinner <david@fromorbit.com>2018-09-29 13:46:21 +1000
commit8683edb7755b853f0dd92e07fe2e7a7e675a84d7 (patch)
treee5532cf7ac21ddc84ebd1cb321ff51f1a19831bf /init
parent95808459b110f16b50f03a70ecfa72bb14bd8a96 (diff)
downloadlinux-8683edb7755b853f0dd92e07fe2e7a7e675a84d7.tar.bz2
xfs: avoid lockdep false positives in xfs_trans_alloc
We've had a few reports of lockdep tripping over memory reclaim context vs filesystem freeze "deadlocks". They all have looked to be false positives on analysis, but it seems that they are being tripped because we take freeze references before we run a GFP_KERNEL allocation for the struct xfs_trans. We can avoid this false positive vector just by re-ordering the operations in xfs_trans_alloc(). That is. we need allocate the structure before we take the freeze reference and enter the GFP_NOFS allocation context that follows the xfs_trans around. This prevents lockdep from seeing the GFP_KERNEL allocation inside the transaction context, and that prevents it from triggering the freeze level vs alloc context vs reclaim warnings. Signed-off-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions