From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6F340C001E0 for ; Mon, 17 Jul 2023 07:43:30 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 9E18C6B0072; Mon, 17 Jul 2023 03:43:29 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 96A676B0074; Mon, 17 Jul 2023 03:43:29 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 795928D0001; Mon, 17 Jul 2023 03:43:29 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 634636B0072 for ; Mon, 17 Jul 2023 03:43:29 -0400 (EDT) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 13B271C8B84 for ; Mon, 17 Jul 2023 07:43:29 +0000 (UTC) X-FDA: 81020313738.20.18F94C7 Received: from mail-ed1-f48.google.com (mail-ed1-f48.google.com [209.85.208.48]) by imf03.hostedemail.com (Postfix) with ESMTP id 0394F2000F for ; Mon, 17 Jul 2023 07:43:26 +0000 (UTC) Authentication-Results: imf03.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=o+xwJC6K; spf=pass (imf03.hostedemail.com: domain of ritesh.list@gmail.com designates 209.85.208.48 as permitted sender) smtp.mailfrom=ritesh.list@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1689579807; a=rsa-sha256; cv=none; b=w/fDT/LqVJi5YtQIsDsINJyCs2I6ZV+PRsxmEPni8L41mE4i+pEtZGxWG8T5owXxCDOAFK NXWzKB+QKVuSAXBjUDGc63IOWCoVWDhNMiylfa1Ysj8au7ryqaxbZ/ifnjV9B804tlAdCs iCzUho1ynupMcwgEpPO2OZlXNJn4Uyo= ARC-Authentication-Results: i=1; imf03.hostedemail.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=o+xwJC6K; spf=pass (imf03.hostedemail.com: domain of ritesh.list@gmail.com designates 209.85.208.48 as permitted sender) smtp.mailfrom=ritesh.list@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1689579807; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=412L8optdQyF2m69jgTLAUW787PgjSAnLpeeSwznjPM=; b=0qd/JRv8wc4rHwgVqgB60s0Zk9xUSKEQZgSx2CoOKtiZmla3e85E/wusTsrGnGc2RiM8OX 01PXr0CK4bbp74/uGYGecDYm1BABytGdpHf/CUIHzXPYqAY1+/Z8IdBGwMLEsGzjf/BY4F nxXglB9aOVvbQCBjSwshF/sZfTZxtYU= Received: by mail-ed1-f48.google.com with SMTP id 4fb4d7f45d1cf-51fdf291330so5991468a12.2 for ; Mon, 17 Jul 2023 00:43:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689579805; x=1692171805; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=412L8optdQyF2m69jgTLAUW787PgjSAnLpeeSwznjPM=; b=o+xwJC6KRMrwmiywZUBEsQuD8lcO3tGXuhxJcH/wy4MYAZ2Lp2udX3IW9xNxKKnsBb CM0/hbdxGDVleyCf4mj2ZlRSYkI2ld2mplo99c5M0mx9+V6n32W3yYUCkgTsQL0eifQG ECX0PDpiqDVSg/7Vtp4TOV2Y0BshJaTxqxO/q1lF7hl+3G8UkoHwxc/HknQ5Re0+WCXw nlpC5Jz0Uo778VbgGH9nnosahsKQ6h9nIJCpjTSzBZx1po8J2YfJdesTl5+a6lDmEgtI cv8iLC52UE0WH4UdgXMkxBn8Kew9UOwq8kGjTCVkzNa+pvFH6j9RPePo70PwTg6xh5BL 7vwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689579805; x=1692171805; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=412L8optdQyF2m69jgTLAUW787PgjSAnLpeeSwznjPM=; b=MtJU/cmGzpZoDET77TiuddpHRqvUvEQBNguEPojPHV2sLcYSua1gsQ+bMRsqTq8h8J rSPLDnIZXtT5e1TPHbbxoDXwdPE98fROpERjCDJw9QbUM6advF4mxq8tbDpMyFaQpgcj hW4kTwtHjWZN1j2HJiIbMzaY9STb0VFEAYXwQQw4ip23gWZPTqzCW2gj3m0jhJc9lW4O aT6tI6qBxzrzA7SCMGqJRxJ+Nl/Pz7NASv+J69Osuyg8NJIurDlCIJksNh3gZOJEyFpz GaEiOmo3rMzrpeJ/xHj4F8nj/Rqzsua3T9HF8Rwna7f68I0xL+fTtAnH18BAri2EqZRi JJmg== X-Gm-Message-State: ABy/qLYBs+nZUZhVgwo0IDIDVMV0Tm++DeQX+x2eLhDcleXPHgeJgJo4 tbL0n5AmTuLWqDhrE/iRQBeX6soRrIge5Wt/KP8= X-Google-Smtp-Source: APBJJlHxjNFxxEGiFF6V25YdN6zkdGha8xc6VBef8P6TgMAmCLFtgBcKEBlssPz/99kl2FNL3L8lHP3Kwpu64yiC4eY= X-Received: by 2002:aa7:c6d3:0:b0:51d:9905:6f60 with SMTP id b19-20020aa7c6d3000000b0051d99056f60mr10604635eds.41.1689579805181; Mon, 17 Jul 2023 00:43:25 -0700 (PDT) MIME-Version: 1.0 References: <87o7kbnle9.fsf@doe.com> In-Reply-To: From: Ritesh Harjani Date: Mon, 17 Jul 2023 13:13:13 +0530 Message-ID: Subject: Re: next: kernel BUG at fs/ext4/mballoc.c:4369! To: Ojaswin Mujoo Cc: Naresh Kamboju , open list , linux-mm , lkft-triage@lists.linaro.org, linux-ext4 , LTP List , Andrew Morton , Arnd Bergmann , Dan Carpenter , "Theodore Ts'o" , Andreas Dilger Content-Type: multipart/alternative; boundary="0000000000001b8a160600a9f491" X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 0394F2000F X-Stat-Signature: zd6dsw6u99mcjrdjy635wfzr6g1j7mmn X-Rspam-User: X-HE-Tag: 1689579806-201203 X-HE-Meta: U2FsdGVkX18pnm2OZBYFZZSAEFhfNyUKpBEr4WpJpfxx+Mrbhv1OKPp41sjou2nHYonmyAoEE+zdfsyC0I/vfJZ75885G04JRp7bgggoMPqnFAdYy8nCwkUcwzAYH5PZ/oZZebEsVKMB4hWcy0sk1vgWH8ftO9UEUWHrEPlMKjiPlA3IDyyqty8j849FUTzDXiolmTmH0KNLqJvE2KY1pvL5yj4JJxmEcE+0iww8B4AUbHko5XLCUaQL1DhKfSBC/CKZ5AoP3tPd1JQ0VUgeko/eObFFwEuPRo2kzLuVTg5VeD+gKyxen5beMr3Bxy6syNVA1TaQVtV3yPKnuvPGG5F3bYelvoLqzeO7mUcVmTY+LWpRicEsczS9uAO1fGxqPkMTY3ck22sSerDwed4HEXOKBYd4RjO3P/qgM8Tb8uEgWVnfS93EKbLBn9RNxQM3o3Ea+0QOwcIjCCbRQDgx2uDrAMuiwLMooU3/VVehOCaAKwhdihtunFavC+B+YP4cbqI3YGaEpIUb41jx6ZrunUhvt/co9YzkxvHYS821ns2y11FtOPtuOeMKJOIPR+8KPjdM/3Mm5/brUMXAJHu7ngMYg6u0kZnU+3M3GCMOvh1lWDvnTa2xKDrJo94G+9i9uDJWZVRl6b7cNDITqY/yu/QkgomIm5rEkEakP/kSMiMtNRrRJ4xLiwe52r0H2yEEFgUU7p3UhAYlgDEXTXRyLpVRg9RLgHY6Oc+lXm25iLJzW35Aw2dIsMl/zPkchePpFxrtKtexow2XRe5aRXylfQ+jT89u6P2XQ712FuqEz0ezl0gD4uAiYZaZQHV2jhJWlxvMnq0QCWDYoDdnyPi+0VbZNOCK20dYvMXodXxIEf7NxL1hNNXWM5H0sW3NX4OZ0pzdd0m/Mfsds0jc7GrQRaTxXAek/ENnE8ZC/Lmi3rnu93lVlIxKxzihTL2xaQ3Cgb85y1WAoS39XLDRgwG 5OREW/c5 x5lj+TyRTx3HmKtJ7Ooj+e+GzdEzjCLewvLIAOd0wZg6leDjm0MBaNnquvxh9fS3xYsVAnW6nvyotnVOIAT3ck0KCzyNnmPbeFTJtUsJqbVj3Cak1cCpA2goRx2VkNGgXBqQDEBFbM6ltuNSCYOAhG+bxkL/mRQxoJHgY0MbPtsgJ7XAjHw8Ht+4HJ3XtF2MJh9nfSUFDLwEKg1vlNxuAZPgYs5t2sWr+Q8rMOCe5stBgJBcNUp0NkDYYPvz1BDemzDOohbvdijwjhifdKkle2tTVH+LiNJJROR5i+fWudyhbBWuwQUv6T2P55uGh1N1cGE7S/+EDCxXc9TF06ASIzgqj4N00rew2Xfw2RkkvVbbSlwl4xw9TmzPIjtI6VygbxNBAq0WUGe/AdK1PIrXi3VbmyE/IEBXirDbCQPE8eO0lVWLsLXpcej6FKDsQ5JSSrKsURqRScgvF2oNlbN5LtxV2heSKhwFCrNk5LaFeJzY4V7cpDiscLmiPKGeIIHoemFkCcIND+OYjUrEm6eRuh37tOEYd6j8V9WXvNKaJl/BgwWjthJFW6PkYqBFu1575SeoR1kUZAM/jCGAqwQZPH7Hu0zb9PxAWgTdvHWhPvFssiKnn7PxdtA5xFMS4zDJ8WFun X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: --0000000000001b8a160600a9f491 Content-Type: text/plain; charset="UTF-8" On Mon, Jul 17, 2023, 12:42 PM Ojaswin Mujoo wrote: > On Mon, Jul 17, 2023 at 11:13:10AM +0530, Ritesh Harjani wrote: > > Naresh Kamboju writes: > > > > > Following kernel BUG noticed while testing LTP fs testing on x86_64 > > > arch x86_64 on the Linux next-20230716 built with clang toolchain. > > > > > > I see a similar crash log on arm64 Juno-r2. The logs are shared below. > > > > > > Reported-by: Linux Kernel Functional Testing > > > > > > x86 log: > > > ------- > > > tst_test.c:1634: TINFO: === Testing on ext2 === > > > tst_test.c:1093: TINFO: Formatting /dev/loop0 with ext2 opts='' extra > opts='' > > > mke2fs 1.46.5 (30-Dec-2021) > > > [ 1393.346989] EXT4-fs (loop0): mounting ext2 file system using the > > > ext4 subsystem > > > > ext4 driver is used for ext2 filesystem here. It will be using indirect > > block mapping path. > > > > > [ 1393.396754] EXT4-fs (loop0): mounted filesystem > > > 7ca8e239-bc8f-488c-af12-5e0ef12d17a5 r/w without journal. Quota mode: > > > none. > > > fs_fill.c:115: TINFO: Running 6 writer threads > > > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread6/AOF\", iov, > > > 512): ENOSPC > > > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread5/AOF\", iov, > > > 512): ENOSPC > > > ... > > > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread6/AOF\", iov, > > > 512): ENOSPC > > > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread3/AOF\", iov, > > > 512): ENOSPC > > > tst_fill_fs.c:109: TINF[ 1393.817197] ------------[ cut here > ]------------ > > > [ 1393.823305] kernel BUG at fs/ext4/mballoc.c:4369! > > > > It's hard to trigger the race I guess. But here are some debugging > > information. > > > > [ 955.508751] EXT4-fs (loop1): mounting ext2 file system using the ext4 > subsystem > > [ 955.515527] EXT4-fs (loop1): mounted filesystem > 57096378-d173-4bc5-ac06-9cd53c1dfa1c r/w without journal. Quota mode: none. > > [ 959.289672] EXT4-fs (loop1): unmounting filesystem > 57096378-d173-4bc5-ac06-9cd53c1dfa1c. > > [ 959.490548] EXT4-fs (loop1): mounting ext3 file system using the ext4 > subsystem > > [ 959.503719] EXT4-fs (loop1): mounted filesystem > 841c90bd-4d83-4bc5-be10-39452034e84b r/w with ordered data mode. Quota > mode: none. > > [ 960.553669] ext4_mb_pa_adjust_overlap: ==== This should not happend > ==== left_pa=ffff8881471c7f50 deleted=0 lstart=6144 len=656 > right_pa=0000000000000000 > > [ 960.557437] ext4_mb_pa_adjust_overlap: pa = ffff8881471c7540, > deleted=1 lstart=5872 len=272 pstart=34560 > > [ 960.560659] ext4_mb_pa_adjust_overlap: pa = ffff8881471c7f50, > deleted=0 lstart=6144 len=656 pstart=26848 > > [ 960.563855] ext4_mb_pa_adjust_overlap: pa = ffff8881471c7ee0, > deleted=1 lstart=6623 len=2 pstart=45503 > > > > (This is the rbtree printed ^^^ ) > > > > (gdb) p ac->ac_o_ex > > $8 = { > > fe_logical = 6625, > > fe_start = 27328, > > fe_group = 0, > > fe_len = 1 > > } > > (gdb) p new_start > > $9 = 6144 > > (gdb) p new_end > > $10 = 8192 > > (gdb) p left_pa_end > > $11 = 6800 > > > > > > The bug one happens here - > > > > if (left_pa) { > > left_pa_end = > > left_pa->pa_lstart + EXT4_C2B(sbi, > left_pa->pa_len); > > BUG_ON(left_pa_end > ac->ac_o_ex.fe_logical); > > } > > > > i.e. left_pa_end(6144 + 656 = 6800) > ac->ac_o_ex.fe_logical(6625) > > > > Thought of sharing this info which can save time for others. > > Hi Ritesh, > > Thanks for sharing the information. So it seems there's an overlapping > preallocation already present in which case the request should ideally > be satisfied by it and we shouldn't enter ext4_mb_normalize_request(). > Yes. The undeleted PA in above tree should satisfy the request in ext4_mb_use_preallocated() so it should have never gone into normalization path. And I don't think the PA rbtree can get entries inserted since we must be holding the locks in write path. > Further, the presence of deleted PAs can suggest a group discard is > ongoing which happens low storage scenarios. > Yes it seems the test is doing ENOSPC testing and it's not easy to trigger it. For me, I had kept it for overnight testing with some debug logs added. Although I don't know if it got triggered in few hours or maybe more. I'll try to replicate it in my setup and update here. Sure, I haven't yet looked closely into the code yet. But I feel maybe with the above debug information pasted it will be easy to find out why ext4_mb_use_preallocated() was not successful. -ritesh > Regards, > ojaswin > > > > > O: writev(\"mntpo[ 1393.828041] invalid opcode: 0000 [#1] PREEMPT SMP > PTI > > > [ 1393.834448] CPU: 3 PID: 8606 Comm: fs_fill Not tainted > > > 6.5.0-rc1-next-20230714 #1 > > > [ 1393.841925] Hardware name: Supermicro SYS-5019S-ML/X11SSH-F, BIOS > > > 2.0b 07/27/2017 > > > [ 1393.849396] RIP: 0010:ext4_mb_normalize_request+0x58f/0x5a0 > > > int[/ s1u3b9d3i.r8ode: d7 b4 fc ff 80 4b 59 02 e9 b4 fa ff ff 48 8b 7b > > > 08 48 c7 c6 ba 35 7b 9a 48 c7 c2 75 26 83 9a e8 17 a9 02 00 0f 0b 0f > > > 0b 0f 0b <0f> 0b 66 66 66 66 66 66 2e 0f 1f 84 00 00 00 00 00 90 90 90 > > > 90 90 > > > [ 1393.873879] RSP: 0018:ffffad2c03327708 EFLAGS: 00010212 > > > [ 1393.879098] RAX: 0000000080000000 RBX: 0000000000000000 RCX: > 0000000000000000 > > > [ 1393.886228] RDX: 0000000000000800 RSI: 000000000000c000 RDI: > 000000000000c000 > > > [ 1393.893353] RBP: ffffad2c03327770 R08: 00000000ffffffff R09: > 000000000000bdac > > > [ 1393.900487] R10: ffffa28309e47098 R11: ffffffff991a03a0 R12: > ffffa283232a3620 > > > [ 1393.907611] R13: 0000000000000000 R14: ffffa283232a3658 R15: > ffffa28309e47098 > > > [ 1393.914733] FS: 00007f6963e80640(0000) GS:ffffa2865fd80000(0000) > > > knlGS:0000000000000000 > > > [ 1393.922811] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > > > [ 1393.928550] CR2: 00007f694c008ba8 CR3: 000000012cb72001 CR4: > 00000000003706e0 > > > [ 1393.935681] DR0: 0000000000000000 DR1: 0000000000000000 DR2: > 0000000000000000 > > > [ 1393.942804] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: > 0000000000000400 > > > [ 1393.949930] Call Trace: > > > [ 1393.952374] > > > [ 1393.954472] ? __die_body+0x6c/0xc0 > > > [ 1393.957964] ? die+0xae/0xe0 > > > [ 1393.960841] ? do_trap+0x8d/0x160 > > > [ 1393.964159] ? ext4_mb_normalize_request+0x58f/0x5a0 > > > [ 1393.969119] ? handle_invalid_op+0x7f/0xd0 > > > [ 1393.973218] ? ext4_mb_normalize_request+0x58f/0x5a0 > > > [ 1393.978183] ? exc_invalid_op+0x36/0x50 > > > [ 1393.982023] ? asm_exc_invalid_op+0x1f/0x30 > > > [ 1393.986210] ? __pfx_ext4_dirty_inode+0x10/0x10 > > > [ 1393.990740] ? ext4_mb_normalize_request+0x58f/0x5a0 > > > [ 1393.995698] ? ext4_mb_normalize_request+0x311/0x5a0 > > > [ 1394.000664] ? _raw_read_unlock+0x20/0x40 > > > [ 1394.004676] ext4_mb_new_blocks+0x3c8/0xdf0 > > > [ 1394.008864] ? mark_buffer_dirty_inode+0x26/0xb0 > > > [ 1394.013483] ? __ext4_handle_dirty_metadata+0x7d/0x230 > > > [ 1394.018620] ext4_ind_map_blocks+0x74e/0xc30 > > > [ 1394.022897] ext4_map_blocks+0x2d6/0x640 > > > [ 1394.026821] _ext4_get_block+0x92/0x150 > > > [ 1394.030659] ext4_get_block+0x1b/0x30 > > > [ 1394.034316] __block_write_begin_int+0x193/0x670 > > > [ 1394.038928] ? __pfx_ext4_get_block+0x10/0x10 > > > [ 1394.043277] ? __ext4_journal_start_sb+0x9f/0x210 > > > [ 1394.047974] __block_write_begin+0x1f/0x50 > > > [ 1394.052065] ext4_write_begin+0x1fa/0x520 > > > [ 1394.056072] generic_perform_write+0xb7/0x260 > > > [ 1394.060431] ext4_buffered_write_iter+0xcd/0x150 > > > [ 1394.065049] ext4_file_write_iter+0x341/0x960 > > > [ 1394.069407] ? iovec_from_user+0x53/0x110 > > > [ 1394.073420] do_iter_write+0x202/0x320 > > > [ 1394.077173] vfs_writev+0x19c/0x280 > > > [ 1394.080666] do_writev+0x77/0x110 > > > [ 1394.083978] __x64_sys_writev+0x23/0x30 > > > [ 1394.087816] do_syscall_64+0x48/0xa0 > > > [ 1394.091386] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 > > > [ 1394.096440] RIP: 0033:0x7f696678aa7d > > > [ 1394.100011] Code: 28 89 54 24 1c 48 89 74 24 10 89 7c 24 08 e8 0a > > > 55 f8 ff 8b 54 24 1c 48 8b 74 24 10 41 89 c0 8b 7c 24 08 b8 14 00 00 > > > 00 0f 05 <48> 3d 00 f0 ff ff 77 33 44 89 c7 48 89 44 24 08 e8 5e 55 f8 > > > ff 48 > > > [ 1394.118756] RSP: 002b:00007f6963e7cdd0 EFLAGS: 00000293 ORIG_RAX: > > > 0000000000000014 > > > [ 1394.126315] RAX: ffffffffffffffda RBX: 0000000000000001 RCX: > 00007f696678aa7d > > > [ 1394.133436] RDX: 0000000000000200 RSI: 00007f6963e7ce00 RDI: > 0000000000000007 > > > [ 1394.140562] RBP: 0000000000d4bbe8 R08: 0000000000000000 R09: > 0000000000000180 > > > [ 1394.147684] R10: 0000000000000180 R11: 0000000000000293 R12: > 0000000000000007 > > > [ 1394.154809] R13: 0000000000000003 R14: 00007f6963e805c0 R15: > 0000000000200000 > > > [ 1394.161933] > > > [ 1394.164118] Modules linked in: tun x86_pkg_temp_thermal > > > [ 1394.169352] ---[ end trace 0000000000000000 ]--- > > > > > > > > > Links: > > > - > https://qa-reports.linaro.org/lkft/linux-next-master/build/next-20230714/testrun/18306459/suite/log-parser-test/tests/ > > > - > https://qa-reports.linaro.org/lkft/linux-next-master/build/next-20230714/testrun/18306459/suite/log-parser-test/test/check-kernel-bug/log > > > - https://lkft.validation.linaro.org/scheduler/job/6584529#L2195 > > > - > https://storage.tuxsuite.com/public/linaro/lkft/builds/2SY3QjxEGsLoae4uGpfjPnZqwKC/ > > > > > > > > > Juno-r2 log: > > > ------------ > > > > > > tst_test.c:1634: TINFO: === Testing on ext3 === > > > tst_test.c:1093: TINFO: Formatting /dev/loop0 with ext3 opts='' extra > opts='' > > > mke2fs 1.46.5 (30-Dec-2021) > > > [ 2086.751198] EXT4-fs (loop0): mounting ext3 file system using the > > > ext4 subsystem > > > [ 2086.802353] EXT4-fs (loop0): mounted filesystem > > > 0b1ac79e-51b8-47a0-b8c8-13ff4c4c2459 r/w with ordered data mode. Quota > > > mode: none. > > > [ 2092.630907] > ================================================================== > > > [ 2092.638172] BUG: KASAN: slab-use-after-free in > > > copy_page_from_iter_atomic+0x778/0x8c8 > > > > This seems to be a different issue than above. > > > > > > > [ 2092.646046] Read of size 1024 at addr ffff000834540000 by task > > > kworker/u12:1/15943 > > > [ 2092.653643] > > > [ 2092.655141] CPU: 2 PID: 15943 Comm: kworker/u12:1 Not tainted > > > 6.5.0-rc1-next-20230714 #1 > > > [ 2092.663264] Hardware name: ARM Juno development board (r2) (DT) > > > [ 2092.669204] Workqueue: loop0 loop_rootcg_workfn > > > [ 2092.673773] Call trace: > > > [ 2092.676226] dump_backtrace+0x9c/0x128 > > > [ 2092.679997] show_stack+0x20/0x38 > > > [ 2092.683328] dump_stack_lvl+0x60/0xb0 > > > [ 2092.687009] print_report+0xf4/0x5b0 > > > [ 2092.690607] kasan_report+0xa8/0x100 > > > [ 2092.694204] kasan_check_range+0xe8/0x190 > > > [ 2092.698231] memcpy+0x3c/0xa0 > > > [ 2092.701213] copy_page_from_iter_atomic+0x778/0x8c8 > > > [ 2092.706113] generic_perform_write+0x1b4/0x318 > > > [ 2092.710576] ext4_buffered_write_iter+0x98/0x1a8 > > > [ 2092.715217] ext4_file_write_iter+0xf0/0xb20 > > > [ 2092.719507] do_iter_readv_writev+0x134/0x200 > > > [ 2092.723889] do_iter_write+0xd8/0x390 > > > [ 2092.727572] vfs_iter_write+0x60/0x88 > > > [ 2092.731256] loop_process_work+0x8f0/0x1000 > > > [ 2092.735463] loop_rootcg_workfn+0x28/0x40 > > > [ 2092.739495] process_one_work+0x42c/0x888 > > > [ 2092.743524] worker_thread+0xa4/0x6a8 > > > [ 2092.747203] kthread+0x19c/0x1b0 > > > [ 2092.750450] ret_from_fork+0x10/0x20 > > > [ 2092.754045] > > > [ 2092.755539] Allocated by task 15409: > > > [ 2092.759126] kasan_save_stack+0x2c/0x58 > > > [ 2092.762986] kasan_set_track+0x2c/0x40 > > > [ 2092.766756] kasan_save_alloc_info+0x24/0x38 > > > [ 2092.771044] __kasan_slab_alloc+0xa8/0xb0 > > > [ 2092.775075] kmem_cache_alloc+0x130/0x330 > > > [ 2092.779105] jbd2_alloc+0x78/0x90 > > > [ 2092.782437] do_get_write_access+0x2b8/0x758 > > > [ 2092.786728] jbd2_journal_get_write_access+0xb0/0xf8 > > > [ 2092.791715] __ext4_journal_get_write_access+0xc4/0x250 > > > [ 2092.796968] ext4_reserve_inode_write+0xe0/0x138 > > > [ 2092.801610] __ext4_mark_inode_dirty+0xe4/0x3e8 > > > [ 2092.806164] ext4_dirty_inode+0x8c/0xb8 > > > [ 2092.810021] __mark_inode_dirty+0x84/0x618 > > > [ 2092.814138] generic_write_end+0x170/0x180 > > > [ 2092.818253] ext4_da_write_end+0x120/0x3d0 > > > [ 2092.822372] generic_perform_write+0x1ec/0x318 > > > [ 2092.826835] ext4_buffered_write_iter+0x98/0x1a8 > > > [ 2092.831472] ext4_file_write_iter+0xf0/0xb20 > > > [ 2092.835760] vfs_write+0x450/0x550 > > > [ 2092.839176] ksys_write+0xcc/0x178 > > > [ 2092.842592] __arm64_sys_write+0x4c/0x68 > > > [ 2092.846530] invoke_syscall+0x68/0x198 > > > [ 2092.850303] el0_svc_common.constprop.0+0x12c/0x168 > > > [ 2092.855206] do_el0_svc+0x4c/0xd8 > > > [ 2092.858541] el0_svc+0x30/0x70 > > > [ 2092.861612] el0t_64_sync_handler+0x13c/0x158 > > > [ 2092.865990] el0t_64_sync+0x190/0x198 > > > [ 2092.869668] > > > [ 2092.871163] The buggy address belongs to the object at > ffff000834540000 > > > [ 2092.871163] which belongs to the cache jbd2_1k of size 1024 > > > [ 2092.883459] The buggy address is located 0 bytes inside of > > > [ 2092.883459] freed 1024-byte region [ffff000834540000, > ffff000834540400) > > > [ 2092.895670] > > > [ 2092.897164] The buggy address belongs to the physical page: > > > [ 2092.902751] page:0000000021bf671c refcount:1 mapcount:0 > > > mapping:0000000000000000 index:0xffff000834540000 pfn:0x8b4540 > > > [ 2092.913485] head:0000000021bf671c order:3 entire_mapcount:0 > > > nr_pages_mapped:0 pincount:0 > > > [ 2092.921602] flags: > > > 0xbfffc0000010200(slab|head|node=0|zone=2|lastcpupid=0xffff) > > > [ 2092.928944] page_type: 0xffffffff() > > > [ 2092.932452] raw: 0bfffc0000010200 ffff00082b6c4000 dead000000000122 > > > 0000000000000000 > > > [ 2092.940224] raw: ffff000834540000 000000008010000f 00000001ffffffff > > > 0000000000000000 > > > [ 2092.947989] page dumped because: kasan: bad access detected > > > [ 2092.953576] > > > [ 2092.955070] Memory state around the buggy address: > > > [ 2092.959877] ffff00083453ff00: ff ff ff ff ff ff ff ff ff ff ff ff > > > ff ff ff ff > > > [ 2092.967123] ffff00083453ff80: ff ff ff ff ff ff ff ff ff ff ff ff > > > ff ff ff ff > > > [ 2092.974368] >ffff000834540000: fb fb fb fb fb fb fb fb fb fb fb fb > > > fb fb fb fb > > > [ 2092.981610] ^ > > > [ 2092.984849] ffff000834540080: fb fb fb fb fb fb fb fb fb fb fb fb > > > fb fb fb fb > > > [ 2092.992094] ffff000834540100: fb fb fb fb fb fb fb fb fb fb fb fb > > > fb fb fb fb > > > [ 2092.999336] > ================================================================== > > > [ 2093.006683] Disabling lock debugging due to kernel taint > > > [ 2099.278554] preadv203 (103227): drop_caches: 3 > > > [ 2099.514899] preadv203 (103228): drop_caches: 3 > > > [ 2099.552185] preadv203 (103228): drop_caches: 3 > > > [ 2099.586917] preadv203 (103228): drop_caches: 3 > > > > > > Links: > > > - > https://qa-reports.linaro.org/lkft/linux-next-master/build/next-20230714/testrun/18303379/suite/log-parser-test/tests/ > > > - https://lkft.validation.linaro.org/scheduler/job/6584681#L2640 > > > - > https://storage.tuxsuite.com/public/linaro/lkft/builds/2SY3ZSm0bzBoyQkWFQAYYZru1UJ/ > > > > > > > > > -- > > > Linaro LKFT > > > https://lkft.linaro.org > > > > -ritesh > --0000000000001b8a160600a9f491 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Jul 17, 2023, 12:42 PM Ojaswin Mujoo <ojaswin@linux.ibm.com> wrote:
On Mon, Jul 17, 2023 at 11:13:10AM +0= 530, Ritesh Harjani wrote:
> Naresh Kamboju <naresh.kamboju@linaro.org> writes: >
> > Following kernel BUG noticed while testing LTP fs testing on x86_= 64
> > arch x86_64 on the Linux next-20230716 built with clang toolchain= .
> >
> > I see a similar crash log on arm64 Juno-r2. The logs are shared b= elow.
> >
> > Reported-by: Linux Kernel Functional Testing <lkft@linaro.org= >
> >
> > x86 log:
> > -------
> > tst_test.c:1634: TINFO: =3D=3D=3D Testing on ext2 =3D=3D=3D
> > tst_test.c:1093: TINFO: Formatting /dev/loop0 with ext2 opts=3D&#= 39;' extra opts=3D''
> > mke2fs 1.46.5 (30-Dec-2021)
> > [ 1393.346989] EXT4-fs (loop0): mounting ext2 file system using t= he
> > ext4 subsystem
>
> ext4 driver is used for ext2 filesystem here. It will be using indirec= t
> block mapping path.
>
> > [ 1393.396754] EXT4-fs (loop0): mounted filesystem
> > 7ca8e239-bc8f-488c-af12-5e0ef12d17a5 r/w without journal. Quota m= ode:
> > none.
> > fs_fill.c:115: TINFO: Running 6 writer threads
> > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread6/A= OF\", iov,
> > 512): ENOSPC
> > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread5/A= OF\", iov,
> > 512): ENOSPC
> > ...
> > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread6/A= OF\", iov,
> > 512): ENOSPC
> > tst_fill_fs.c:109: TINFO: writev(\"mntpoint/subdir/thread3/A= OF\", iov,
> > 512): ENOSPC
> > tst_fill_fs.c:109: TINF[ 1393.817197] ------------[ cut here ]---= ---------
> > [ 1393.823305] kernel BUG at fs/ext4/mballoc.c:4369!
>
> It's hard to trigger the race I guess. But here are some debugging=
> information.
>
> [=C2=A0 955.508751] EXT4-fs (loop1): mounting ext2 file system using t= he ext4 subsystem
> [=C2=A0 955.515527] EXT4-fs (loop1): mounted filesystem 57096378-d173-= 4bc5-ac06-9cd53c1dfa1c r/w without journal. Quota mode: none.
> [=C2=A0 959.289672] EXT4-fs (loop1): unmounting filesystem 57096378-d1= 73-4bc5-ac06-9cd53c1dfa1c.
> [=C2=A0 959.490548] EXT4-fs (loop1): mounting ext3 file system using t= he ext4 subsystem
> [=C2=A0 959.503719] EXT4-fs (loop1): mounted filesystem 841c90bd-4d83-= 4bc5-be10-39452034e84b r/w with ordered data mode. Quota mode: none.
> [=C2=A0 960.553669] ext4_mb_pa_adjust_overlap: =3D=3D=3D=3D This shoul= d not happend =3D=3D=3D=3D left_pa=3Dffff8881471c7f50 deleted=3D0 lstart=3D= 6144 len=3D656 right_pa=3D0000000000000000
> [=C2=A0 960.557437] ext4_mb_pa_adjust_overlap: pa =3D ffff8881471c7540= , deleted=3D1 lstart=3D5872 len=3D272 pstart=3D34560
> [=C2=A0 960.560659] ext4_mb_pa_adjust_overlap: pa =3D ffff8881471c7f50= , deleted=3D0 lstart=3D6144 len=3D656 pstart=3D26848
> [=C2=A0 960.563855] ext4_mb_pa_adjust_overlap: pa =3D ffff8881471c7ee0= , deleted=3D1 lstart=3D6623 len=3D2 pstart=3D45503
>
> (This is the rbtree printed ^^^ )
>
> (gdb) p ac->ac_o_ex
> $8 =3D {
>=C2=A0 =C2=A0fe_logical =3D 6625,
>=C2=A0 =C2=A0fe_start =3D 27328,
>=C2=A0 =C2=A0fe_group =3D 0,
>=C2=A0 =C2=A0fe_len =3D 1
> }
> (gdb) p new_start
> $9 =3D 6144
> (gdb) p new_end
> $10 =3D 8192
> (gdb) p left_pa_end
> $11 =3D 6800
>
>
> The bug one happens here -
>
>=C2=A0 =C2=A0 =C2=A0 =C2=A0if (left_pa) {
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0left_pa_end =3D<= br> >=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0left_pa->pa_lstart + EXT4_C2B(sbi, left_pa->pa_len);
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0BUG_ON(left_pa_e= nd > ac->ac_o_ex.fe_logical);
>=C2=A0 =C2=A0 =C2=A0 =C2=A0}
>
> i.e. left_pa_end(6144 + 656 =3D 6800) > ac->ac_o_ex.fe_logical(6= 625)
>
> Thought of sharing this info which can save time for others.

Hi Ritesh,

Thanks for sharing the information. So it seems there's an overlapping<= br> preallocation already present in which case the request should ideally
be satisfied by it and we shouldn't enter ext4_mb_normalize_request().<= br>

Y= es. The undeleted PA in above tree should satisfy the request in ext4_mb_us= e_preallocated() so it should have never gone into normalization path.=C2= =A0

And I don't thin= k the PA rbtree can get entries inserted since we must be holding the locks= in write path.=C2=A0


Further, the presence of deleted PAs can suggest a group discard is
ongoing which happens low storage scenarios.

Yes it seems the test is doing = ENOSPC testing and it's not easy to trigger it. For me, I had kept it f= or overnight testing with some debug logs added. Although I don't know = if it got triggered in few hours or maybe more.=C2=A0

I'll try to replicate it in my setup and update here.

Sure, I haven't ye= t looked closely into the code yet. But I feel maybe with the above debug i= nformation pasted it will be easy to find out why ext4_mb_use_preallocated(= ) was not successful.=C2=A0

-ritesh


Regards,
ojaswin
>
> > O: writev(\"mntpo[ 1393.828041] invalid opcode: 0000 [#1] PR= EEMPT SMP PTI
> > [ 1393.834448] CPU: 3 PID: 8606 Comm: fs_fill Not tainted
> > 6.5.0-rc1-next-20230714 #1
> > [ 1393.841925] Hardware name: Supermicro SYS-5019S-ML/X11SSH-F, B= IOS
> > 2.0b 07/27/2017
> > [ 1393.849396] RIP: 0010:ext4_mb_normalize_request+0x58f/0x5a0 > > int[/ s1u3b9d3i.r8ode: d7 b4 fc ff 80 4b 59 02 e9 b4 fa ff ff 48 = 8b 7b
> > 08 48 c7 c6 ba 35 7b 9a 48 c7 c2 75 26 83 9a e8 17 a9 02 00 0f 0b= 0f
> > 0b 0f 0b <0f> 0b 66 66 66 66 66 66 2e 0f 1f 84 00 00 00 00 = 00 90 90 90
> > 90 90
> > [ 1393.873879] RSP: 0018:ffffad2c03327708 EFLAGS: 00010212
> > [ 1393.879098] RAX: 0000000080000000 RBX: 0000000000000000 RCX: 0= 000000000000000
> > [ 1393.886228] RDX: 0000000000000800 RSI: 000000000000c000 RDI: 0= 00000000000c000
> > [ 1393.893353] RBP: ffffad2c03327770 R08: 00000000ffffffff R09: 0= 00000000000bdac
> > [ 1393.900487] R10: ffffa28309e47098 R11: ffffffff991a03a0 R12: f= fffa283232a3620
> > [ 1393.907611] R13: 0000000000000000 R14: ffffa283232a3658 R15: f= fffa28309e47098
> > [ 1393.914733] FS:=C2=A0 00007f6963e80640(0000) GS:ffffa2865fd800= 00(0000)
> > knlGS:0000000000000000
> > [ 1393.922811] CS:=C2=A0 0010 DS: 0000 ES: 0000 CR0: 000000008005= 0033
> > [ 1393.928550] CR2: 00007f694c008ba8 CR3: 000000012cb72001 CR4: 0= 0000000003706e0
> > [ 1393.935681] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0= 000000000000000
> > [ 1393.942804] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0= 000000000000400
> > [ 1393.949930] Call Trace:
> > [ 1393.952374]=C2=A0 <TASK>
> > [ 1393.954472]=C2=A0 ? __die_body+0x6c/0xc0
> > [ 1393.957964]=C2=A0 ? die+0xae/0xe0
> > [ 1393.960841]=C2=A0 ? do_trap+0x8d/0x160
> > [ 1393.964159]=C2=A0 ? ext4_mb_normalize_request+0x58f/0x5a0
> > [ 1393.969119]=C2=A0 ? handle_invalid_op+0x7f/0xd0
> > [ 1393.973218]=C2=A0 ? ext4_mb_normalize_request+0x58f/0x5a0
> > [ 1393.978183]=C2=A0 ? exc_invalid_op+0x36/0x50
> > [ 1393.982023]=C2=A0 ? asm_exc_invalid_op+0x1f/0x30
> > [ 1393.986210]=C2=A0 ? __pfx_ext4_dirty_inode+0x10/0x10
> > [ 1393.990740]=C2=A0 ? ext4_mb_normalize_request+0x58f/0x5a0
> > [ 1393.995698]=C2=A0 ? ext4_mb_normalize_request+0x311/0x5a0
> > [ 1394.000664]=C2=A0 ? _raw_read_unlock+0x20/0x40
> > [ 1394.004676]=C2=A0 ext4_mb_new_blocks+0x3c8/0xdf0
> > [ 1394.008864]=C2=A0 ? mark_buffer_dirty_inode+0x26/0xb0
> > [ 1394.013483]=C2=A0 ? __ext4_handle_dirty_metadata+0x7d/0x230 > > [ 1394.018620]=C2=A0 ext4_ind_map_blocks+0x74e/0xc30
> > [ 1394.022897]=C2=A0 ext4_map_blocks+0x2d6/0x640
> > [ 1394.026821]=C2=A0 _ext4_get_block+0x92/0x150
> > [ 1394.030659]=C2=A0 ext4_get_block+0x1b/0x30
> > [ 1394.034316]=C2=A0 __block_write_begin_int+0x193/0x670
> > [ 1394.038928]=C2=A0 ? __pfx_ext4_get_block+0x10/0x10
> > [ 1394.043277]=C2=A0 ? __ext4_journal_start_sb+0x9f/0x210
> > [ 1394.047974]=C2=A0 __block_write_begin+0x1f/0x50
> > [ 1394.052065]=C2=A0 ext4_write_begin+0x1fa/0x520
> > [ 1394.056072]=C2=A0 generic_perform_write+0xb7/0x260
> > [ 1394.060431]=C2=A0 ext4_buffered_write_iter+0xcd/0x150
> > [ 1394.065049]=C2=A0 ext4_file_write_iter+0x341/0x960
> > [ 1394.069407]=C2=A0 ? iovec_from_user+0x53/0x110
> > [ 1394.073420]=C2=A0 do_iter_write+0x202/0x320
> > [ 1394.077173]=C2=A0 vfs_writev+0x19c/0x280
> > [ 1394.080666]=C2=A0 do_writev+0x77/0x110
> > [ 1394.083978]=C2=A0 __x64_sys_writev+0x23/0x30
> > [ 1394.087816]=C2=A0 do_syscall_64+0x48/0xa0
> > [ 1394.091386]=C2=A0 entry_SYSCALL_64_after_hwframe+0x6e/0xd8
> > [ 1394.096440] RIP: 0033:0x7f696678aa7d
> > [ 1394.100011] Code: 28 89 54 24 1c 48 89 74 24 10 89 7c 24 08 e8= 0a
> > 55 f8 ff 8b 54 24 1c 48 8b 74 24 10 41 89 c0 8b 7c 24 08 b8 14 00= 00
> > 00 0f 05 <48> 3d 00 f0 ff ff 77 33 44 89 c7 48 89 44 24 08 = e8 5e 55 f8
> > ff 48
> > [ 1394.118756] RSP: 002b:00007f6963e7cdd0 EFLAGS: 00000293 ORIG_R= AX:
> > 0000000000000014
> > [ 1394.126315] RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 0= 0007f696678aa7d
> > [ 1394.133436] RDX: 0000000000000200 RSI: 00007f6963e7ce00 RDI: 0= 000000000000007
> > [ 1394.140562] RBP: 0000000000d4bbe8 R08: 0000000000000000 R09: 0= 000000000000180
> > [ 1394.147684] R10: 0000000000000180 R11: 0000000000000293 R12: 0= 000000000000007
> > [ 1394.154809] R13: 0000000000000003 R14: 00007f6963e805c0 R15: 0= 000000000200000
> > [ 1394.161933]=C2=A0 </TASK>
> > [ 1394.164118] Modules linked in: tun x86_pkg_temp_thermal
> > [ 1394.169352] ---[ end trace 0000000000000000 ]---
> >
> >
> > Links:
> >=C2=A0 - https://qa-reports.linaro.or= g/lkft/linux-next-master/build/next-20230714/testrun/18306459/suite/log-par= ser-test/tests/
> >=C2=A0 - https://q= a-reports.linaro.org/lkft/linux-next-master/build/next-20230714/testrun/183= 06459/suite/log-parser-test/test/check-kernel-bug/log
> >=C2=A0 - https://l= kft.validation.linaro.org/scheduler/job/6584529#L2195
> >=C2=A0 - https://storage.tuxsuite.com/public/linaro/lkft/builds/2SY3QjxE= GsLoae4uGpfjPnZqwKC/
> >
> >
> > Juno-r2 log:
> > ------------
> >
> > tst_test.c:1634: TINFO: =3D=3D=3D Testing on ext3 =3D=3D=3D
> > tst_test.c:1093: TINFO: Formatting /dev/loop0 with ext3 opts=3D&#= 39;' extra opts=3D''
> > mke2fs 1.46.5 (30-Dec-2021)
> > [ 2086.751198] EXT4-fs (loop0): mounting ext3 file system using t= he
> > ext4 subsystem
> > [ 2086.802353] EXT4-fs (loop0): mounted filesystem
> > 0b1ac79e-51b8-47a0-b8c8-13ff4c4c2459 r/w with ordered data mode. = Quota
> > mode: none.
> > [ 2092.630907] =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
> > [ 2092.638172] BUG: KASAN: slab-use-after-free in
> > copy_page_from_iter_atomic+0x778/0x8c8
>
> This seems to be a different issue than above.
>
>
> > [ 2092.646046] Read of size 1024 at addr ffff000834540000 by task=
> > kworker/u12:1/15943
> > [ 2092.653643]
> > [ 2092.655141] CPU: 2 PID: 15943 Comm: kworker/u12:1 Not tainted<= br> > > 6.5.0-rc1-next-20230714 #1
> > [ 2092.663264] Hardware name: ARM Juno development board (r2) (DT= )
> > [ 2092.669204] Workqueue: loop0 loop_rootcg_workfn
> > [ 2092.673773] Call trace:
> > [ 2092.676226]=C2=A0 dump_backtrace+0x9c/0x128
> > [ 2092.679997]=C2=A0 show_stack+0x20/0x38
> > [ 2092.683328]=C2=A0 dump_stack_lvl+0x60/0xb0
> > [ 2092.687009]=C2=A0 print_report+0xf4/0x5b0
> > [ 2092.690607]=C2=A0 kasan_report+0xa8/0x100
> > [ 2092.694204]=C2=A0 kasan_check_range+0xe8/0x190
> > [ 2092.698231]=C2=A0 memcpy+0x3c/0xa0
> > [ 2092.701213]=C2=A0 copy_page_from_iter_atomic+0x778/0x8c8
> > [ 2092.706113]=C2=A0 generic_perform_write+0x1b4/0x318
> > [ 2092.710576]=C2=A0 ext4_buffered_write_iter+0x98/0x1a8
> > [ 2092.715217]=C2=A0 ext4_file_write_iter+0xf0/0xb20
> > [ 2092.719507]=C2=A0 do_iter_readv_writev+0x134/0x200
> > [ 2092.723889]=C2=A0 do_iter_write+0xd8/0x390
> > [ 2092.727572]=C2=A0 vfs_iter_write+0x60/0x88
> > [ 2092.731256]=C2=A0 loop_process_work+0x8f0/0x1000
> > [ 2092.735463]=C2=A0 loop_rootcg_workfn+0x28/0x40
> > [ 2092.739495]=C2=A0 process_one_work+0x42c/0x888
> > [ 2092.743524]=C2=A0 worker_thread+0xa4/0x6a8
> > [ 2092.747203]=C2=A0 kthread+0x19c/0x1b0
> > [ 2092.750450]=C2=A0 ret_from_fork+0x10/0x20
> > [ 2092.754045]
> > [ 2092.755539] Allocated by task 15409:
> > [ 2092.759126]=C2=A0 kasan_save_stack+0x2c/0x58
> > [ 2092.762986]=C2=A0 kasan_set_track+0x2c/0x40
> > [ 2092.766756]=C2=A0 kasan_save_alloc_info+0x24/0x38
> > [ 2092.771044]=C2=A0 __kasan_slab_alloc+0xa8/0xb0
> > [ 2092.775075]=C2=A0 kmem_cache_alloc+0x130/0x330
> > [ 2092.779105]=C2=A0 jbd2_alloc+0x78/0x90
> > [ 2092.782437]=C2=A0 do_get_write_access+0x2b8/0x758
> > [ 2092.786728]=C2=A0 jbd2_journal_get_write_access+0xb0/0xf8
> > [ 2092.791715]=C2=A0 __ext4_journal_get_write_access+0xc4/0x250 > > [ 2092.796968]=C2=A0 ext4_reserve_inode_write+0xe0/0x138
> > [ 2092.801610]=C2=A0 __ext4_mark_inode_dirty+0xe4/0x3e8
> > [ 2092.806164]=C2=A0 ext4_dirty_inode+0x8c/0xb8
> > [ 2092.810021]=C2=A0 __mark_inode_dirty+0x84/0x618
> > [ 2092.814138]=C2=A0 generic_write_end+0x170/0x180
> > [ 2092.818253]=C2=A0 ext4_da_write_end+0x120/0x3d0
> > [ 2092.822372]=C2=A0 generic_perform_write+0x1ec/0x318
> > [ 2092.826835]=C2=A0 ext4_buffered_write_iter+0x98/0x1a8
> > [ 2092.831472]=C2=A0 ext4_file_write_iter+0xf0/0xb20
> > [ 2092.835760]=C2=A0 vfs_write+0x450/0x550
> > [ 2092.839176]=C2=A0 ksys_write+0xcc/0x178
> > [ 2092.842592]=C2=A0 __arm64_sys_write+0x4c/0x68
> > [ 2092.846530]=C2=A0 invoke_syscall+0x68/0x198
> > [ 2092.850303]=C2=A0 el0_svc_common.constprop.0+0x12c/0x168
> > [ 2092.855206]=C2=A0 do_el0_svc+0x4c/0xd8
> > [ 2092.858541]=C2=A0 el0_svc+0x30/0x70
> > [ 2092.861612]=C2=A0 el0t_64_sync_handler+0x13c/0x158
> > [ 2092.865990]=C2=A0 el0t_64_sync+0x190/0x198
> > [ 2092.869668]
> > [ 2092.871163] The buggy address belongs to the object at ffff000= 834540000
> > [ 2092.871163]=C2=A0 which belongs to the cache jbd2_1k of size 1= 024
> > [ 2092.883459] The buggy address is located 0 bytes inside of
> > [ 2092.883459]=C2=A0 freed 1024-byte region [ffff000834540000, ff= ff000834540400)
> > [ 2092.895670]
> > [ 2092.897164] The buggy address belongs to the physical page: > > [ 2092.902751] page:0000000021bf671c refcount:1 mapcount:0
> > mapping:0000000000000000 index:0xffff000834540000 pfn:0x8b4540 > > [ 2092.913485] head:0000000021bf671c order:3 entire_mapcount:0 > > nr_pages_mapped:0 pincount:0
> > [ 2092.921602] flags:
> > 0xbfffc0000010200(slab|head|node=3D0|zone=3D2|lastcpupid=3D0xffff= )
> > [ 2092.928944] page_type: 0xffffffff()
> > [ 2092.932452] raw: 0bfffc0000010200 ffff00082b6c4000 dead0000000= 00122
> > 0000000000000000
> > [ 2092.940224] raw: ffff000834540000 000000008010000f 00000001fff= fffff
> > 0000000000000000
> > [ 2092.947989] page dumped because: kasan: bad access detected > > [ 2092.953576]
> > [ 2092.955070] Memory state around the buggy address:
> > [ 2092.959877]=C2=A0 ffff00083453ff00: ff ff ff ff ff ff ff ff ff= ff ff ff
> > ff ff ff ff
> > [ 2092.967123]=C2=A0 ffff00083453ff80: ff ff ff ff ff ff ff ff ff= ff ff ff
> > ff ff ff ff
> > [ 2092.974368] >ffff000834540000: fb fb fb fb fb fb fb fb fb f= b fb fb
> > fb fb fb fb
> > [ 2092.981610]=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 ^
> > [ 2092.984849]=C2=A0 ffff000834540080: fb fb fb fb fb fb fb fb fb= fb fb fb
> > fb fb fb fb
> > [ 2092.992094]=C2=A0 ffff000834540100: fb fb fb fb fb fb fb fb fb= fb fb fb
> > fb fb fb fb
> > [ 2092.999336] =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
> > [ 2093.006683] Disabling lock debugging due to kernel taint
> > [ 2099.278554] preadv203 (103227): drop_caches: 3
> > [ 2099.514899] preadv203 (103228): drop_caches: 3
> > [ 2099.552185] preadv203 (103228): drop_caches: 3
> > [ 2099.586917] preadv203 (103228): drop_caches: 3
> >
> > Links:
> >=C2=A0 - https://qa-reports.linaro.or= g/lkft/linux-next-master/build/next-20230714/testrun/18303379/suite/log-par= ser-test/tests/
> >=C2=A0 - https://l= kft.validation.linaro.org/scheduler/job/6584681#L2640
> >=C2=A0 - https://storage.tuxsuite.com/public/linaro/lkft/builds/2SY3ZSm0= bzBoyQkWFQAYYZru1UJ/
> >
> >
> > --
> > Linaro LKFT
> > https://lkft.linaro.org
>
> -ritesh
--0000000000001b8a160600a9f491--