[6.17-rc0 regression] WARNING: CPU: 15 PID: 321705 at fs/xfs/xfs_trans.c:256 xfs_trans_alloc+0x19b/0x280

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

 



Hi folks,

Just pulled the latest Linus kernel and running it through
check-parallel on a 1kB block size filesystem throws a lots of these
warnings:

 ------------[ cut here ]------------
 WARNING: CPU: 15 PID: 321705 at fs/xfs/xfs_trans.c:256 xfs_trans_alloc+0x19b/0x280
 Modules linked in:
 CPU: 15 UID: 0 PID: 321705 Comm: kworker/15:9 Tainted: G        W           6.16.0-dgc+ #349 PREEMPT(full)
 Tainted: G   WARN
 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
 Workqueue: xfs-inodegc/loop124 xfs_inodegc_worker
 RIP: 0010:xfs_trans_alloc+0x19b/0x280
 Code: 00 49 c7 47 20 00 00 00 00 41 c7 07 00 00 00 00 41 80 67 18 fb 41 bc e4 ff ff ff 83 7d d4 00 0f 85 4e ff ff ff e9 5f ff ff ff <0f> 0b e9 b8 fe ff ff 31 ff 48 c7 c6 61 b0 eb 82 48 c7 c2 04 4b e5
 RSP: 0018:ffffc9001b24fd10 EFLAGS: 00010246
 RIP: 0010:xfs_trans_alloc+0x19b/0x280
 RAX: ffff888244cc2000 RBX: 0000000000000000 RCX: 0000000000000000
 RDX: 0000000000000000 RSI: ffff88828f9ee39c RDI: ffff88828f9ee000
 Code: 00 49 c7 47 20 00 00 00 00 41 c7 07 00 00 00 00 41 80 67 18 fb 41 bc e4 ff ff ff 83 7d d4 00 0f 85 4e ff ff ff e9 5f ff ff ff <0f> 0b e9 b8 fe ff ff 31 ff 48 c7 c6 61 b0 eb 82 48 c7 c2 04 4b e5
 RBP: ffffc9001b24fd68 R08: 0000000000000000 R09: ffffc9001b24fd78
 R10: 0000000000343231 R11: ffffffff81abf660 R12: ffff88828f9ee000
 R13: ffff88828f9ee39c R14: ffff88828f9ee000 R15: ffff88828f9ee000
 FS:  0000000000000000(0000) GS:ffff88889a82e000(0000) knlGS:0000000000000000
 CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
 CR2: 0000559141e5a0c8 CR3: 0000000866625000 CR4: 0000000000350ef0
 Call Trace:
  <TASK>
  xfs_free_eofblocks+0x88/0x1b0
  xfs_inactive+0x1ad/0x3b0
  xfs_inodegc_worker+0xaa/0x180
  process_scheduled_works+0x1d6/0x400
  worker_thread+0x202/0x2e0
  kthread+0x20c/0x240
  ret_from_fork+0x77/0x140
  ret_from_fork_asm+0x1a/0x30
  </TASK>
 ---[ end trace 0000000000000000 ]---


I'm also seeing them from inodegc worker threads via:

  xfs_reflink_cancel_cow_range+0x79/0x200
  xfs_inactive+0x188/0x3b0
  xfs_inodegc_worker+0xaa/0x180
  process_scheduled_works+0x1d6/0x400

The warning is:

	WARN_ON(mp->m_super->s_writers.frozen == SB_FREEZE_COMPLETE);

Which indicates that we are doing inodegc on a frozen filesystem.
We should have called xfs_inodegc_stop() from xfs_fs_sync_fs() once
all data modification had been frozen and written back at
SB_FREEZE_PAGEFAULT level....

Ah, just got the same warning from xfs_quota_normap config, which is
running a 4kB block size filesystem. So it has nothing to do with
the filesystem block size. Looks like a freeze regression, then?

Hmmm - this warning is in code that was modified in this merge
window.  Specifically, commit 83a80e95e797 ("xfs: decouple
xfs_trans_alloc_empty from xfs_trans_alloc") that was merged in the
merge window changes how this specific warning is triggered...

Christoph, looks like this is one for you - these transactions
previously got caught in sb_start_intwrite() before the freeze state
warning check (i.e. modifications get blocked once freeze starts, so
never get to the warning whilst the fs is frozen). The new code
checks the freeze state and emits the warning before the transaction
can (correctly) account/block on freeze state via
sb_start_intwrite().

-Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx




[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux