Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp199076pxb; Thu, 2 Sep 2021 23:32:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxkUtylf0UmUD21OF8J3/ToLFMQH4pktnOxCdZ7eakTwd36Fej4QR1QRQt644KV/1MfpGv5 X-Received: by 2002:aa7:ca0e:: with SMTP id y14mr2290111eds.249.1630650759179; Thu, 02 Sep 2021 23:32:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630650759; cv=none; d=google.com; s=arc-20160816; b=HbiFBqDD6t4YR8HUm2L/f5q9sWj7/KkIYPObig3Jg+9Ef0xTHg2kwybx3W3+HzIayD PfmC1a4LMuUi5G84dvHb2OHWZzSSGikee78eAHQAjuaalsqxiMR1mBdE3jj291VjgZB5 3ahjiINHLfmwG6hcy6XvHIeBvaF2WSnSIsTbIyD92aGBSCkkPhTbIIqKWCL9Xz6JIFL7 bh1DOn0rVtAtp5zdwbZifQXcDEqjjnHocuaxZ6uuOaiQHvdwUarboSEsx0FclkC53nhj hwmZseCcWjwhkHnUW/Z1YfFdwT8t+DYuoljRDzB883+a5NebPP8rjbHdH+pMQI6TxWrl BBHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=GNDW/LHJwv/JK89OuoWyLgFYrlZLVzYs/ur1sFKjat4=; b=yK0mAGZeTn25FtuXmmZR38nrx+b1AMg94xcWi91YFTxGhAzgLZVNbmCsHObqEkEfmw 0l3EFpj3lRpwxwSHKyuo+uXIDjY2a7Qm62uyfGMLhwYImdeqiNJSTLkF4y33r2uGwKCr 4HnfhhbixDM1NIKQs0Ks2VMQmIjjXBdSzsJewIwyM8wgnsY+cPb7fe8v8Iyku3gn5PuJ xfq6kVcm75+VgQe0Gt8fK0l6tuleQdcph5n/lAB5gLhxTUyuqj/2fp74PgATPgVWKX2t 8RYsRisaPmnzvQGiiIaMzBvU7AXr803aWET96A2qx12n1JFdko3FhlgZxVkK2lXa0vLa qTYg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d26si4839566ejo.421.2021.09.02.23.32.14; Thu, 02 Sep 2021 23:32:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237064AbhICGL1 (ORCPT + 99 others); Fri, 3 Sep 2021 02:11:27 -0400 Received: from mga03.intel.com ([134.134.136.65]:40596 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234109AbhICGL0 (ORCPT ); Fri, 3 Sep 2021 02:11:26 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10095"; a="219399067" X-IronPort-AV: E=Sophos;i="5.85,264,1624345200"; d="scan'208";a="219399067" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga103.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) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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; } /**