Received: by 2002:a25:86ce:0:0:0:0:0 with SMTP id y14csp296548ybm; Wed, 22 May 2019 03:22:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqy09KxklClWzXTaZNcsSveDi9fhNOGGQ3UJyFCctsx6HJVzh5iD4krcN/pGMzwSZBS5o77X X-Received: by 2002:a63:2c01:: with SMTP id s1mr89630494pgs.261.1558520520182; Wed, 22 May 2019 03:22:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558520520; cv=none; d=google.com; s=arc-20160816; b=c6g/avYv0cF/mgACoXEE5pDb87fVW+MRQMVmJ7Atzwa0DXjCcW0WqNGHoTvtrUz9s+ piUAXbChp5lBWxFBRwVb6ZuMh9akyjzBntZZfwA3lMJNqOkGG5bvM0PaYZnpd60YZnK0 C+FlqdjyjmDu8YTwu2GO8tT3nyZG0r9bNwL8te5BdvDuAzitdYaY7eYbVdTyxqgRtLHr +k0YReeuwbhE8OGyw796Ru0vHd4XnKRxrQIkzvJL4hjWEsyljdblXnd/4cqlDksQcmY7 Tv96pmhkjM+mz+pt9d5gFbHynRFx9b/lFFn8gA8acjHHSjAGx/fd6cDHOFMiOSYKiaNK 66ZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=I6Y5uva2ZOylkepfkW7JjoryC+I9mnJT08CLLH1/zB4=; b=StFPlmeIUmYRDien5eWzvCQ2qK/AyHVtZiJg9LYGPKUuuzS1qF69WtfCtbD4sVloI0 LpuifsS+05UzZc63H6vQS8cBpTYBSu3W7yT1KwepcWFlJsxQ/s6m69eJi1gE6uXYMSZX BwobTaR2D9gLoegwQzwvVKz6m3atdOXwOc4fRgk9gMnTWHgqxMR0sxeiOODPtKcW/Zwb CNgnLungltT+QsF8fx4DZk4BQpCYaqj3C8g0XnbHjpWVG6L4gy7VbJJ7sJUalZMNVN0K IUpD30sqg9CLMogqcE3oDqrXIlBzuG8j/rlczdJ1lDeBNOFxFGbuXJttKoTrLC5zgREA KmOg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zavVrEDe; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ay8si24676441plb.218.2019.05.22.03.21.40; Wed, 22 May 2019 03:22:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zavVrEDe; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728527AbfEVKUy (ORCPT + 99 others); Wed, 22 May 2019 06:20:54 -0400 Received: from mail-lj1-f195.google.com ([209.85.208.195]:44177 "EHLO mail-lj1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728802AbfEVKUu (ORCPT ); Wed, 22 May 2019 06:20:50 -0400 Received: by mail-lj1-f195.google.com with SMTP id e13so1531953ljl.11 for ; Wed, 22 May 2019 03:20:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=I6Y5uva2ZOylkepfkW7JjoryC+I9mnJT08CLLH1/zB4=; b=zavVrEDe37Qme7JszDwtBit8a9goL7Xf7lo7dzYs9F/s32qJMMV7ciqBvmraiaXv0z 1z3SGu/sXwQJ1PJmUaUHUlv2qKFBXe95+hZWV3jIDL13S66YAp9x3vdJ+Fn6BuT9VU8u NOBZwoAp6T7manfujvUuR9RbpVzziZD+GjSMxlsGQWytCUClTW4rehuBUJjupvskHUr5 kkJC7rbA7qka6A7HM8y0PHco+9oNkv0LZrTNeFi/W/MkRmVZ39mK5bOW4nSVp1i03h5/ 0214MndB/t3uNnBA7L4B/uS6WoXe29jOMrI0wiGoFHJkTYyz2kReyg2TfKgbDZfWpW6q QOZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=I6Y5uva2ZOylkepfkW7JjoryC+I9mnJT08CLLH1/zB4=; b=afaYxmFcBx8OzqlSd4lvdrLUmuT3+T640w8W7qMB0JL9krJOCOKb9gCGvPAbZeoe5d Pi18Y7ZzTwd1/ppz/ojzHD5k4+QiXajlTBXcbWoPpE+9iIgTa4UGztSDv10l3I/tviCE q/gNiqcZiy0yhvXj/HWkvoRfkKIFJuWnq1ALKgaOF+0EOx05lT8EJYMzVNH2G7EJaQda IlUiQAjVQPdyHi/Srn2GLNq10Qs6ky5gfLyNjT0CjvSXOMiF8X6WGxZN5Aibn39KDU0p LLHcASpS8MC2aUKN3gxgfzooUfu0C/D6SQhLiD3SDp704jifYTNHjadI+jSPhkJnRKV5 WRPg== X-Gm-Message-State: APjAAAX3mKpKs9KJSUeeXH8mG3sGXqMWLEtTloGw+Ir6UIBlVOS8dCIZ frv7efjfyA84Ay7udlYUxJ48bZoHivqZ4jbjjesrTw== X-Received: by 2002:a2e:7411:: with SMTP id p17mr2152330ljc.24.1558520448161; Wed, 22 May 2019 03:20:48 -0700 (PDT) MIME-Version: 1.0 References: <20190520115247.060821231@linuxfoundation.org> <20190520222342.wtsjx227c6qbkuua@xps.therub.org> <20190521085956.GC31445@kroah.com> <20190521093849.GA9806@kroah.com> <20190521162142.GA2591@mit.edu> <20190522050511.GB4943@mit.edu> In-Reply-To: <20190522050511.GB4943@mit.edu> From: Naresh Kamboju Date: Wed, 22 May 2019 15:50:37 +0530 Message-ID: Subject: Re: ext4 regression (was Re: [PATCH 4.19 000/105] 4.19.45-stable review) To: "Theodore Ts'o" , Naresh Kamboju , Greg Kroah-Hartman , open list , Linus Torvalds , Andrew Morton , Guenter Roeck , Shuah Khan , patches@kernelci.org, Ben Hutchings , lkft-triage@lists.linaro.org, linux- stable , linux-ext4@vger.kernel.org, Arthur Marsh , Richard Weinberger , ltp@lists.linux.it, Jan Stancek Content-Type: text/plain; charset="UTF-8" Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Wed, 22 May 2019 at 10:36, Theodore Ts'o wrote: > > On Tue, May 21, 2019 at 11:27:21PM +0530, Naresh Kamboju wrote: > > Steps to reproduce is, > > running LTP three test cases in sequence on x86 device. > > # cd ltp/runtest > > # cat syscalls ( only three test case) > > open12 open12 > > madvise06 madvise06 > > poll02 poll02 > > # > > > > as Dan referring to, > > > > LTP is run using '/opt/ltp/runltp -d /scratch -f syscalls', where the > > syscalls file has been replaced with three test case names, and > > /scratch is an ext4 SATA drive. /scratch is created using 'mkfs -t ext4 > > /dev/disk/by-id/ata-TOSHIBA_MG03ACA100_37O9KGKWF' and mounted to > > /scratch. > > I'm still having trouble reproducing the problem. I've followed the > above exactly, and it doesn't trigger on my system. I think I know > what is happening, but even given my theory, I'm still not able to > trigger it. So, I'm not 100% sure this is the appropriate fix. If > you can reproduce it, can you see if this patch, applied on top of the > Linus's tip, fixes the problem for you? Applied your patch on mainline master branch and tested on x86_64 and confirms that the reported problem fixed. Thanks for your fix patch. LTP syscalls full test output log, https://lkft.validation.linaro.org/scheduler/job/739075 --- Fixes: 345c0dbf3a30 ("ext4: protect journal inode's blocks using block_validity") Reported-by: Dan Rue Signed-off-by: Theodore Ts'o diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c index f2c62e2a0c98..d40ed940001e 100644 --- a/fs/ext4/extents.c +++ b/fs/ext4/extents.c @@ -518,10 +518,14 @@ __read_extent_tree_block(const char *function, unsigned int line, } if (buffer_verified(bh) && !(flags & EXT4_EX_FORCE_CACHE)) return bh; - err = __ext4_ext_check(function, line, inode, - ext_block_hdr(bh), depth, pblk); - if (err) - goto errout; + if (!ext4_has_feature_journal(inode->i_sb) || + (inode->i_ino != + le32_to_cpu(EXT4_SB(inode->i_sb)->s_es->s_journal_inum))) { + err = __ext4_ext_check(function, line, inode, + ext_block_hdr(bh), depth, pblk); + if (err) + goto errout; + } set_buffer_verified(bh); /* * If this is a leaf block, cache all of its entries - Naresh