From nobody Thu Sep 10 05:48:08 2026 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4hgRY45SBqz6rQJY for ; Thu, 10 Sep 2026 05:48:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hgRY44s0zz4lVw for ; Thu, 10 Sep 2026 05:48:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1789019288; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iXHFREVBw89N7Zlsm1HO6F20EK9FqwKPOPtX3b+u37U=; b=mLN9/Mh5dlVtXYmHws+MfIVEXNrNPAej+QiHzmIyyJ0jKAYOopB4zdEUZIlgntJHpUY6RX A7R/u3vyoupifkDBgEaStCDp9rY4Dz+qNYdM24lr/LM/5ClT2qaXv1kQZZFHN1luseEd3Z 3LdTf/dQFQJ5MdslCoQm8zfGhNrcJaB/XacXLMQIuZJbqAkguMouInD3h8PpBwGZu2lQ/M tBizB/9c5jNN8yIOj6OPbL4+Rks2MUMHX4TmKmYGBmndIKQn9slmLziVUv7KJFikph8sqC fbHbgsbugbE2W7og/zIgTHHST9abrszP6RRpDcz24ldzGMOFRjl3HT/guvzBRQ== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1789019288; b=WOxPkuConra3PND1TSxPeXFF8spNck/ae6FksLs6vcYuFQEZi87TEOV6nS+ZK7j18+UjKb XPeUFRZRZkhaOeRgUWKVxMO4kT9hf97oEMkdtF2MqUFFfBdnqcZoOF5qBmn6ljWbq3Ep4E qYLaIrzLAMlPiNgl2i2IPsQpzVxSzDFtsY3GT44UAItVS9VDPtfDr+qJSE+E2AImAoPTW2 /h7PDRQLjbxUlyetKt2YHc9ofvk1ae5Vir+33rcQTA4wegVvPLEpm5s0gkGybd5eGo4BiX 2SqH/1IBNoQsQv61sEcjdjHpnFyU/ZhNxxkmyv67Bd1D94xjd5IMO7SbG3cWDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1789019288; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iXHFREVBw89N7Zlsm1HO6F20EK9FqwKPOPtX3b+u37U=; b=yxfxD1deUAsgUuLiC6C4+1EzD3jelzkD8pfsMjdBvjC365y0uaXPjZbR2EL4ZxHNXd6gpy 76f/xagJH1+XjCPihqV12TRbg+uzaJHpw8sryNiHjvEFO0oiYHu/bbgPkN/K7C1MaKnban 0MH3rDO873D/4iRBWtlDHHbhBpn+QeFJ0TEIAxlglVK30cijAMZEy5ddMGIEyVOT3kXcF8 c5KApLghEB1+x7Ja2JrkjBrepISoV6J3SiuxLQAuq3vtWNx7X23iPhZnvciD5RFhYSk9NL 640MHF+8EbCGZVxcWGiH+8VgfNCvLPKqFbSN7AGu9gdxj9oT6evMCuujezqpXg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hgRY43wtyzF6j for ; Thu, 10 Sep 2026 05:48:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3c57f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Thu, 10 Sep 2026 05:48:08 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kevin Bowling Subject: git: 9b348b17001a - stable/15 - acpi_pci: Do not match SR-IOV VFs to ACPI devices List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 9b348b17001aa20ba5d20bfc530a34721aaaef0e Auto-Submitted: auto-generated Date: Thu, 10 Sep 2026 05:48:08 +0000 Message-Id: <6aa24498.3c57f.1f94730e@gitrepo.freebsd.org> The branch stable/15 has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=9b348b17001aa20ba5d20bfc530a34721aaaef0e commit 9b348b17001aa20ba5d20bfc530a34721aaaef0e Author: Kevin Bowling AuthorDate: 2026-08-18 02:39:41 +0000 Commit: Kevin Bowling CommitDate: 2026-09-10 04:03:25 +0000 acpi_pci: Do not match SR-IOV VFs to ACPI devices SR-IOV VFs are instantiated dynamically from their PF rather than enumerated from ACPI. A VF's runtime slot and function can match an unrelated _ADR below the bridge. acpi_pci_save_handle() stores that handle in the VF's devinfo before acpi_pci_update_device() runs. If the handle is already bound to another device_t whose parent is not acpi0, acpi_pci_update_device() panics under INVARIANTS. Without INVARIANTS, the VF retains the unrelated handle, so subsequent ACPI lookups, including NUMA and power-management operations, can act on the wrong namespace node. Skip ACPI namespace matching for VFs. Reviewed by: jhb Sponsored by: BBOX.io Differential Revision: https://reviews.freebsd.org/D59061 (cherry picked from commit 8b74806161a188103666387013cdd93fb3f5dc07) --- sys/dev/acpica/acpi_pci.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/dev/acpica/acpi_pci.c b/sys/dev/acpica/acpi_pci.c index 1912350bbc48..0ff938cfd6b8 100644 --- a/sys/dev/acpica/acpi_pci.c +++ b/sys/dev/acpica/acpi_pci.c @@ -338,6 +338,18 @@ acpi_pci_save_handle(ACPI_HANDLE handle, UINT32 level, void *context, void acpi_pci_child_added(device_t dev, device_t child) { + struct acpi_pci_devinfo *dinfo; + + dinfo = device_get_ivars(child); + + /* + * VFs are instantiated dynamically from their PF rather than enumerated + * from ACPI. A VF's runtime slot and function can match an unrelated + * _ADR below the bridge, causing the ACPI handle for that device to be + * attached to the VF. + */ + if ((dinfo->ap_dinfo.cfg.flags & PCICFG_VF) != 0) + return; /* * PCI devices are added via the bus scan in the normal PCI