From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E53344C81; Thu, 15 Jan 2026 17:38:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768498701; cv=none; b=OKndvsyEuqmCGi5DsXkzmBK8dX8CIMMfOSPkWjcnaBfgrhoCMP/9jGPwxQJOTEXLBWZnEYC5P8r4/q7HxvzOlSx5Z5FmHDvmqGSSiUU3qk8dI+qzXnUu5v+w70MniU3g90sbZ8W9ZSuKYA6V6hXV3VQ363zhXbDVIRKl9Am2X4U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768498701; c=relaxed/simple; bh=iYtxQi8hR/CI073jcZbRNlMBHCVKqGjXtwez2OlKiLw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Aa3RZhEW8m5hQV05UK8CVcgiHAzs+DkOpzvya5/iEYV5igsefCRXcnSq3AZI/MaiE6NnWNaa8/K+40kZFSp3R0400w6o0zZeapnCrHr+oJuX0fiSerUR8nNPJu1fjfO2fBlTKP2kGw2bmEWi8V1IXyo0ZBZsaL5K2PuaRYtRUEE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=iTzK9uhP; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="iTzK9uhP" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 73755C116D0; Thu, 15 Jan 2026 17:38:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1768498700; bh=iYtxQi8hR/CI073jcZbRNlMBHCVKqGjXtwez2OlKiLw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=iTzK9uhPT7bQAkAYv/4TvjRrN0WjMVRKSKpuunkIS50P9dN53KnvofgDCK6b7cy7u EuNs8caTE4k97z30Ot7+6lDfsFtzmV6B1D7565PlrYxzX+iSsh3lmF2kFDNhUG21LY aPqN14J4HMO07ekjO7lnVNDIuHPgOIC3869msEzg= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Xingui Yang , Jason Yan , John Garry , "Martin K. Petersen" , Sasha Levin Subject: [PATCH 5.15 522/554] scsi: Revert "scsi: libsas: Fix exp-attached device scan after probe failure scanned in again after probe failed" Date: Thu, 15 Jan 2026 17:49:48 +0100 Message-ID: <20260115164305.223045938@linuxfoundation.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20260115164246.225995385@linuxfoundation.org> References: <20260115164246.225995385@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Xingui Yang [ Upstream commit 278712d20bc8ec29d1ad6ef9bdae9000ef2c220c ] This reverts commit ab2068a6fb84751836a84c26ca72b3beb349619d. When probing the exp-attached sata device, libsas/libata will issue a hard reset in sas_probe_sata() -> ata_sas_async_probe(), then a broadcast event will be received after the disk probe fails, and this commit causes the probe will be re-executed on the disk, and a faulty disk may get into an indefinite loop of probe. Therefore, revert this commit, although it can fix some temporary issues with disk probe failure. Signed-off-by: Xingui Yang Reviewed-by: Jason Yan Reviewed-by: John Garry Link: https://patch.msgid.link/20251202065627.140361-1-yangxingui@huawei.com Signed-off-by: Martin K. Petersen Signed-off-by: Sasha Levin --- drivers/scsi/libsas/sas_internal.h | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/drivers/scsi/libsas/sas_internal.h b/drivers/scsi/libsas/sas_internal.h index 5028bc394c4f9..d7a1fb5c10c6e 100644 --- a/drivers/scsi/libsas/sas_internal.h +++ b/drivers/scsi/libsas/sas_internal.h @@ -111,20 +111,6 @@ static inline void sas_fail_probe(struct domain_device *dev, const char *func, i func, dev->parent ? "exp-attached" : "direct-attached", SAS_ADDR(dev->sas_addr), err); - - /* - * If the device probe failed, the expander phy attached address - * needs to be reset so that the phy will not be treated as flutter - * in the next revalidation - */ - if (dev->parent && !dev_is_expander(dev->dev_type)) { - struct sas_phy *phy = dev->phy; - struct domain_device *parent = dev->parent; - struct ex_phy *ex_phy = &parent->ex_dev.ex_phy[phy->number]; - - memset(ex_phy->attached_sas_addr, 0, SAS_ADDR_SIZE); - } - sas_unregister_dev(dev->port, dev); } -- 2.51.0