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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C1271CD6E56 for ; Wed, 3 Jun 2026 10:59:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:content-type: Content-Transfer-Encoding:MIME-Version:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=gUOUj2uQfA2vt7AFIl1y5TD83w2VwUTO4xUveVofnp8=; b=bbS+Ijk/2Vq2Ia1DsIiiCNYqfp zjvz6c8wBCLIVLKMkvDByaBnEertf3E2IoHrBk/lm0eEzFuFSOAv15R5x8goCwXRuEV9XeLeYpu2x 9hOTYmrs92OfqJvVUNX5hkAbE1iekcHy1GQws6GoxNIvZEEA9n7D+GJEIiDBVFYwW4d6obW7lM8eR uzei7fYyzFQZDnr+NvNHtum40DY63Hwx1QKitjrv3u2nW1Tfuzx+nV46LRCBMFelNNALj0k9H1dOg eifVarwWOqTUkQTTKNM8sK+pLHmzHF5wllLzNwQj40hzvIZNCcNaHrANKQpO/HQgnPu8Cqmm1C2/g XpBQZWag==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1wUjJZ-0000000ErAA-3ATR; Wed, 03 Jun 2026 10:59:13 +0000 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1wUjJX-0000000Er9h-3AzR for ath11k@lists.infradead.org; Wed, 03 Jun 2026 10:59:13 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1780484350; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gUOUj2uQfA2vt7AFIl1y5TD83w2VwUTO4xUveVofnp8=; b=VucOllwPr4a1wXnxi93eKOKgHnehShrDKwDrLBKwE3jRWphU655R13HGda/Or7oDopJ3u6 71g73G91sPPvDP8wt08OKJ9RGRJqf9buasJsHCBjza072GX2jHa8csAPT0umdOkEysPyQ6 fsMgH3La6DncMOIwc1FqFvfxLCgqRZM= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-277-U-giJPGxMgSEXrRIli0tUQ-1; Wed, 03 Jun 2026 06:59:05 -0400 X-MC-Unique: U-giJPGxMgSEXrRIli0tUQ-1 X-Mimecast-MFC-AGG-ID: U-giJPGxMgSEXrRIli0tUQ_1780484343 Received: from mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.17]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id B8AE71956060; Wed, 3 Jun 2026 10:59:02 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.44.48.81]) by mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 26C721956095; Wed, 3 Jun 2026 10:58:57 +0000 (UTC) From: Jose Ignacio Tornos Martinez To: bhelgaas@google.com, alex@shazbot.org Cc: jjohnson@kernel.org, mani@kernel.org, linux-pci@vger.kernel.org, linux-wireless@vger.kernel.org, ath11k@lists.infradead.org, ath12k@lists.infradead.org, mhi@lists.linux.dev, linux-kernel@vger.kernel.org, Jose Ignacio Tornos Martinez Subject: [PATCH v7 0/3] PCI: Add d3cold and device-specific reset for Qualcomm devices Date: Wed, 3 Jun 2026 12:58:50 +0200 Message-ID: <20260603105853.326290-1-jtornosm@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.17 X-Mimecast-MFC-PROC-ID: WSZM9eThOQdEYGyRfGkr5yqpHnf0Zj6P-NzI5Jcjv34_1780484343 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit content-type: text/plain; charset="US-ASCII"; x-default=true X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260603_035911_858340_38848D33 X-CRM114-Status: UNSURE ( 7.74 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath11k@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "ath11k" Errors-To: ath11k-bounces+ath11k=archiver.kernel.org@lists.infradead.org Some PCIe devices lack working reset methods for VFIO passthrough scenarios. These devices typically have no FLR, advertise NoSoftRst+ (blocking PM reset), and have broken or unavailable bus reset. When a VM crashes, VFIO cannot reset the device for reuse without a working reset method. This series addresses the problem by adding general d3cold infrastructure and device-specific reset for Qualcomm devices: **Patch 1/3: d3cold reset method** Adds D3cold as a general reset method with strict _PR3 requirement. Only attempts true power cycling via platform control (ACPI _PR3), never falls back to D3hot. This provides genuine power-off reset on platforms that support it. **Patch 2/3: device-specific reset for Qualcomm devices** Adds device-specific reset entries for Qualcomm WCN6855/WCN7850 WiFi cards and SDX62/SDX65 modems using D3cold power cycling with automatic D3hot fallback. Uses pci_set_power_state(D3cold) which automatically falls back to D3hot on platforms without _PR3. Extracts shared pci_dev_d3cold_d0_cycle() helper to avoid code duplication with general d3cold method. Device-specific reset is position #1 in reset hierarchy, providing immediate working reset for these Qualcomm devices. **Patch 3/3: Qualcomm quirk_no_bus_reset** Disables broken bus reset for Qualcomm devices. Testing proves this is device-specific: MediaTek MT7925e works correctly with bus reset using the same passive M.2-to-PCIe adapters where Qualcomm devices fail, confirming PERST# is properly wired and the issue is not deployment-specific. Acts as safety net to prevent broken SBR if users override via sysfs. v7: Address the comments from Jeff Johnson: the problem was detected for the specific devices WCN6855 and WCN7850, use the name of the devices instead of the related drivers ath11k and ath12k, which support a large number of devices (patches 2/3 and 3/3). v6: https://lore.kernel.org/all/20260602160024.1171949-1-jtornosm@redhat.com/ Jose Ignacio Tornos Martinez (3): PCI: Add d3cold as general reset method PCI: Add device-specific reset for Qualcomm devices PCI: Disable broken bus reset on Qualcomm devices -- 2.53.0