From nobody Thu Dec 18 15:30:31 2025 Received: from smtpbgau1.qq.com (smtpbgau1.qq.com [54.206.16.166]) (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 11C0E18C02F for ; Thu, 29 Aug 2024 09:51:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=54.206.16.166 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724925095; cv=none; b=pohoSZLUtIlMMYGz8EqNRJvthlu7d+wPWZk2QUsWxH3vhSShEXTO8xy1EUO8XveOVmp2by5+r8NSJefhnGRcGvQ/Z4e5SKjTiUR5dZzaroko3NI3NKZlobe30qOWwnP/WZ1+L/d5+iZG+RP/nGMvUoMcJ2bi46f5JIlspcmHbfM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724925095; c=relaxed/simple; bh=7TylQoddSxB9ZHHf9DNZGW9iD+hOgef4/KVkWYwfLMI=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=X5CyWjwMTzUKnsoUHEp0vuFh29PNbbGOsavOh0F/wH1c7hi6UN6tFNWuCkV610qCK07p9GycF09FGuuSbTchOSRaLFxU4AdVoL8VI3Qqs4MQVq4muoNn2s8u/fid8H4lMwAkAJ1G0GDRXxH1751sDv6dmk9Ebl2GWhKphsXWxv4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=uniontech.com; spf=pass smtp.mailfrom=uniontech.com; dkim=pass (1024-bit key) header.d=uniontech.com header.i=@uniontech.com header.b=dbvY0W0l; arc=none smtp.client-ip=54.206.16.166 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=uniontech.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=uniontech.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=uniontech.com header.i=@uniontech.com header.b="dbvY0W0l" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uniontech.com; s=onoh2408; t=1724925058; bh=C8Ap7JInDIabgSxCYPM4pbBC80uSwTy3ex4duXRFaHU=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=dbvY0W0lIQ2corqG+YFAbmQT95lfzQ2SGB+jB9KnsEP3NHi+ZINQ4cBJbGf+JSFqm XHKQGwZQ+VlKchCHodc383UTNdBZREPmuGMp53GfQWD8aFjPGuDCoj/ghZwTBPtRv5 VNMByx94GtyFo5J5xezvJGmDEYlX82miUdHtHKqM= X-QQ-mid: bizesmtp90t1724925034t64mciaj X-QQ-Originating-IP: EJmO/ueDMiuaxusWmcU8TWgM5tfiwk54zZSXTUIcmM4= Received: from localhost.localdomain ( [113.57.152.160]) by bizesmtp.qq.com (ESMTP) with id ; Thu, 29 Aug 2024 17:50:31 +0800 (CST) X-QQ-SSF: 0000000000000000000000000000000 X-QQ-GoodBg: 1 X-BIZMAIL-ID: 17652668555461779045 From: WangYuli To: mathias.nyman@intel.com, gregkh@linuxfoundation.org Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, guanwentao@uniontech.com, WangYuli , Chen Baozi , Wang Zhimin , Chen Zhenhua , Wang Yinfeng , Jiakun Shuai Subject: [PATCH v2] usb: xHCI: add XHCI_RESET_ON_RESUME quirk for Phytium xHCI host Date: Thu, 29 Aug 2024 17:50:28 +0800 Message-ID: <196A709D168A9A04+20240829095028.345047-1-wangyuli@uniontech.com> X-Mailer: git-send-email 2.43.4 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 X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:uniontech.com:qybglogicsvrgz:qybglogicsvrgz8a-1 Content-Type: text/plain; charset="utf-8" The resume operation of Phytium Px210 xHCI host would failed to restore state. Use the XHCI_RESET_ON_RESUME quirk to skip it and reset the controller after resume. Co-developed-by: Chen Baozi Signed-off-by: Chen Baozi Co-developed-by: Wang Zhimin Signed-off-by: Wang Zhimin Co-developed-by: Chen Zhenhua Signed-off-by: Chen Zhenhua Co-developed-by: Wang Yinfeng Signed-off-by: Wang Yinfeng Co-developed-by: Jiakun Shuai Signed-off-by: Jiakun Shuai Signed-off-by: WangYuli --- drivers/usb/host/xhci-pci.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/usb/host/xhci-pci.c b/drivers/usb/host/xhci-pci.c index b5705ed01d83..fabae8420ce9 100644 --- a/drivers/usb/host/xhci-pci.c +++ b/drivers/usb/host/xhci-pci.c @@ -55,6 +55,9 @@ #define PCI_DEVICE_ID_INTEL_ALDER_LAKE_PCH_XHCI 0x51ed #define PCI_DEVICE_ID_INTEL_ALDER_LAKE_N_PCH_XHCI 0x54ed =20 +#define PCI_VENDOR_ID_PHYTIUM 0x1db7 +#define PCI_DEVICE_ID_PHYTIUM_XHCI 0xdc27 + /* Thunderbolt */ #define PCI_DEVICE_ID_INTEL_MAPLE_RIDGE_XHCI 0x1138 #define PCI_DEVICE_ID_INTEL_ALPINE_RIDGE_2C_XHCI 0x15b5 @@ -407,6 +410,10 @@ static void xhci_pci_quirks(struct device *dev, struct= xhci_hcd *xhci) if (pdev->vendor =3D=3D PCI_VENDOR_ID_VIA) xhci->quirks |=3D XHCI_RESET_ON_RESUME; =20 + if (pdev->vendor =3D=3D PCI_VENDOR_ID_PHYTIUM || + pdev->device =3D=3D PCI_DEVICE_ID_PHYTIUM_XHCI) + xhci->quirks |=3D XHCI_RESET_ON_RESUME; + /* See https://bugzilla.kernel.org/show_bug.cgi?id=3D79511 */ if (pdev->vendor =3D=3D PCI_VENDOR_ID_VIA && pdev->device =3D=3D 0x3432) --=20 2.43.4