From nobody Tue Dec 16 03:22:13 2025 Received: from rosemary.ibugone.net (unknown [202.38.75.2]) (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 4906750A75 for ; Fri, 15 Mar 2024 20:00:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.38.75.2 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710532858; cv=none; b=McBB/HZGOBIzmcJY2QZiimuj9QF9RW24egKjr7FBp43zyfhQes2GW3dOZst3985CYyvyi0KJtgPZAE+iRpiLtvOFwRhdvEIlGTaSwNWZLuAITeHDq72do5cNjI3+Y5c3Y4Yty1eoWE2OTuNPjWNNnld9dJ59Ru97fvpo9cfPmOE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710532858; c=relaxed/simple; bh=DWuHyDQ7KaouzyzHkM8sjp+zITuNkADl5Pm6V4ABgBU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=cKgiSDSBYqX+N2tqcnidLjkSwjOUvqHWRNtXVcj/09gdLxWfLyLZqR+9NkoxpqOzNO+lkRd/i0Q4TVVtOE6awqGWFVKMAuWjVTMiTyC7dYK8YBE1wxxk6Wq5PoPaJaPuInRZZYt4jFxJB+F+wIbMIbbRC+a2Jwwxte2d7c57bAs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ibugone.com; spf=pass smtp.mailfrom=ibugone.com; arc=none smtp.client-ip=202.38.75.2 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ibugone.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ibugone.com Received: by rosemary.ibugone.net (Postfix, from userid 1000) id 4D2CE7A56F4; Sat, 16 Mar 2024 03:32:09 +0800 (CST) From: iBug To: kbusch@kernel.org, axboe@kernel.dk, hch@lst.de, sagi@grimberg.me, linux-nvme@lists.infradead.org Cc: linux-kernel@vger.kernel.org, "Jiawei Fu (iBug)" Subject: [PATCH] drivers/nvme: Add quirks for device 126f:2262 Date: Sat, 16 Mar 2024 03:27:49 +0800 Message-ID: <20240315192747.1749119-3-i@ibugone.com> X-Mailer: git-send-email 2.43.2 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: "Jiawei Fu (iBug)" This commit adds NVME_QUIRK_NO_DEEPEST_PS and NVME_QUIRK_BOGUS_NID for device [126f:2262], which appears to be a generic VID:PID pair used for many SSDs based on the Silicon Motion SM2262/SM2262EN controller. Two of my SSDs with this VID:PID pair exhibit the same behavior: * They frequently have trouble exiting the deepest power state (5), resulting in the entire disk unresponsive. Verified by setting nvme_core.default_ps_max_latency_us=3D10000 and observing them behaving normally. * They produce all-zero nguid and eui64 with `nvme id-ns` command. The offending products are: * HP SSD EX950 1TB * HIKVISION C2000Pro 2TB Signed-off-by: Jiawei Fu Reviewed-by: Christoph Hellwig Reviewed-by: Sagi Grimberg --- drivers/nvme/host/pci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c index e6267a6aa380..8e0bb9692685 100644 --- a/drivers/nvme/host/pci.c +++ b/drivers/nvme/host/pci.c @@ -3363,6 +3363,9 @@ static const struct pci_device_id nvme_id_table[] =3D= { NVME_QUIRK_BOGUS_NID, }, { PCI_VDEVICE(REDHAT, 0x0010), /* Qemu emulated controller */ .driver_data =3D NVME_QUIRK_BOGUS_NID, }, + { PCI_DEVICE(0x126f, 0x2262), /* Silicon Motion generic */ + .driver_data =3D NVME_QUIRK_NO_DEEPEST_PS | + NVME_QUIRK_BOGUS_NID, }, { PCI_DEVICE(0x126f, 0x2263), /* Silicon Motion unidentified */ .driver_data =3D NVME_QUIRK_NO_NS_DESC_LIST | NVME_QUIRK_BOGUS_NID, }, --=20 2.43.2