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 X-Spam-Level: X-Spam-Status: No, score=-15.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E8B70C433F5 for ; Fri, 3 Sep 2021 06:10:39 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 87DC0610E9 for ; Fri, 3 Sep 2021 06:10:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 87DC0610E9 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id C6DF8900002; Fri, 3 Sep 2021 02:10:38 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BF7E88D0001; Fri, 3 Sep 2021 02:10:38 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id ABF43900002; Fri, 3 Sep 2021 02:10:38 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0009.hostedemail.com [216.40.44.9]) by kanga.kvack.org (Postfix) with ESMTP id 99D818D0001 for ; Fri, 3 Sep 2021 02:10:38 -0400 (EDT) Received: from smtpin24.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 3D1608093A66 for ; Fri, 3 Sep 2021 06:10:38 +0000 (UTC) X-FDA: 78545238156.24.851E906 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by imf30.hostedemail.com (Postfix) with ESMTP id 17392E0016B0 for ; Fri, 3 Sep 2021 06:10:36 +0000 (UTC) X-IronPort-AV: E=McAfee;i="6200,9189,10095"; a="280355073" X-IronPort-AV: E=Sophos;i="5.85,264,1624345200"; d="scan'208";a="280355073" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Sep 2021 23:10:27 -0700 X-IronPort-AV: E=Sophos;i="5.85,264,1624345200"; d="scan'208";a="500162668" Received: from xsang-optiplex-9020.sh.intel.com (HELO xsang-OptiPlex-9020) ([10.239.159.41]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Sep 2021 23:10:25 -0700 Date: Fri, 3 Sep 2021 14:28:00 +0800 From: Oliver Sang To: Christoph Hellwig Cc: "Martin K. Petersen" , LKML , Linux Memory Management List , lkp@lists.01.org, lkp@intel.com Subject: Re: [scsi] 61b3baad24: last_state.load_disk_fail Message-ID: <20210903062800.GB29784@xsang-OptiPlex-9020> References: <20210729082528.GA26618@xsang-OptiPlex-9020> <20210820074013.GC29369@xsang-OptiPlex-9020> <20210820091627.GA6035@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210820091627.GA6035@lst.de> User-Agent: Mutt/1.9.4 (2018-02-28) Authentication-Results: imf30.hostedemail.com; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=intel.com (policy=none); spf=none (imf30.hostedemail.com: domain of oliver.sang@intel.com has no SPF policy when checking 134.134.136.31) smtp.mailfrom=oliver.sang@intel.com X-Stat-Signature: j3py8cjigs9wu9b5tz5h98yawythwpbn X-Rspamd-Queue-Id: 17392E0016B0 X-Rspamd-Server: rspam04 X-HE-Tag: 1630649436-227345 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: Hi, Christoph Hellwig, On Fri, Aug 20, 2021 at 11:16:27AM +0200, Christoph Hellwig wrote: > On Fri, Aug 20, 2021 at 03:40:13PM +0800, Oliver Sang wrote: > > Hi, Christoph Hellwig, > > > > recently we checked this commit again, and find it has a new commit id > > as well as the parent: > > f2542a3be3277 scsi: scsi_ioctl: Move the "block layer" SCSI ioctl handling to drivers/scsi > > 7353dc06c9a8e scsi: scsi_ioctl: Simplify SCSI passthrough permission checking > > > > so we tested it again, and found the issue is still reproduced in > > our environment persistently. > > > > we also tried another platform, and could reproduce, too. > > Intel(R) Xeon(R) CPU E7-8890 v3 @ 2.50GHz > > > > in parent dmesg (attached as dmesg-7353dc06c9.xz), > > it's clear that the disk mounted without problem: > > [ 31.549031][ T1791] XFS (sda1): Mounting V5 Filesystem > > [ 31.591680][ T1791] XFS (sda1): Starting recovery (logdev: internal) > > [ 31.608990][ T1791] XFS (sda1): Ending recovery (logdev: internal) > > [ 31.625155][ T1791] xfs filesystem being mounted at /opt/rootfs supports timestamps until 2038 (0x7fffffff) > > > > but in the dmesg for commit f2542a3be3277 (attached as dmesg-f2542a3be3.xz), > > which is from the identical test environment except kernel, > > just failed like below: > > [ 62.411699][ T1661] can't load the disk /dev/disk/by-id/ata-INTEL_SSDSC2BA400G4_BTHV634503K3400NGN-part1, skip testing... > > Really strange. This message is printed when wait_load_disk fails. > > The kernel has probed all disks before, then apparently something > is installed using dpkg and then it waits for this rootfs (which > obviously isn't the root at that point). > > Also at least on my debian testing and oldstable systems a plain > blkid call never even calls SG_IO or related ioctls (which makes sense > given that it looks at the file system labels). > > Does tis issue just show up on one particular system or on multiple > different ones? we observed this on multiple platforms, and now we confirmed this was fixed by below commit: commit 04a71cdc46a94b13ee876290ad961b4886e24c76 Author: Halil Pasic AuthorDate: Mon Aug 23 15:34:58 2021 +0200 Commit: Martin K. Petersen CommitDate: Tue Aug 24 22:56:32 2021 -0400 scsi: core: scsi_ioctl: Fix error code propagation in SG_IO Link: https://lore.kernel.org/r/20210823133458.3536824-1-pasic@linux.ibm.com Fixes: f2542a3be327 ("scsi: scsi_ioctl: Move the "block layer" SCSI ioctl handling to drivers/scsi") Reviewed-by: Christoph Hellwig Signed-off-by: Halil Pasic Signed-off-by: Martin K. Petersen diff --git a/drivers/scsi/scsi_ioctl.c b/drivers/scsi/scsi_ioctl.c index 7b2b0a1581f4f..6ff2207bd45a0 100644 --- a/drivers/scsi/scsi_ioctl.c +++ b/drivers/scsi/scsi_ioctl.c @@ -874,7 +874,7 @@ static int scsi_ioctl_sg_io(struct scsi_device *sdev, struct gendisk *disk, return error; if (put_sg_io_hdr(&hdr, argp)) return -EFAULT; - return 0; + return error; } /**