From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fout-b2-smtp.messagingengine.com (fout-b2-smtp.messagingengine.com [202.12.124.145]) (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 69D4D46AEE8; Tue, 31 Mar 2026 23:01:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.12.124.145 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774998117; cv=none; b=HyII1jTCHDiZcj17ni54igSXZlJCdp3WfddeFDY4ero4xJkbInSu0cISwFbFPd2TST4sIK7xtBawQRBlwq6I3mket0eRWEASHrsAUS/5ZFnWo1MggJgrbd9JEmkiwd1u5kSwRPMddj5SipugxOOT5g7tKEYsfK0MGe94v1HC7SI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774998117; c=relaxed/simple; bh=uhwpHP2Ttf1/01lqwrO31sK/lvNvQg/Kd/276OzWF2Q=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=lqxKAJPwAMKPyngGy4xbLy0frI9luH7auzuCollsmJcZ4SzRNXvxQQzsCQL359JWwGAHW6JaqH6D9BrY512Kgd5IHdLDvu+fabm9YPfLe9ydKoRq0rfZNjbneCiNIsQbMGBUCf0Sjy1wWkkl6SjB0jkwTixmcoe6rcK+x0E2qiw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=shazbot.org; spf=pass smtp.mailfrom=shazbot.org; dkim=pass (2048-bit key) header.d=shazbot.org header.i=@shazbot.org header.b=pep+ZU7Z; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=gmQnSYAh; arc=none smtp.client-ip=202.12.124.145 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=shazbot.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=shazbot.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=shazbot.org header.i=@shazbot.org header.b="pep+ZU7Z"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="gmQnSYAh" Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfout.stl.internal (Postfix) with ESMTP id 13EE01D000CA; Tue, 31 Mar 2026 19:01:54 -0400 (EDT) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-02.internal (MEProxy); Tue, 31 Mar 2026 19:01:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shazbot.org; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1774998113; x=1775084513; bh=lBuwiN4qeR4cp/7SH69mL0nqRv1FXISJ3o63/YTRGfg=; b= pep+ZU7ZC3w9Knw2+EVJlg2x63zg4wT3UdZrVqlDEE7Vq2NuVK6V58imjucxc+9d SCoehZTAGBC/3mQZpy5MNXpLhTQGLlfC8bFvgCfOtAKAHv/Z5aN2sexAssHYLS1r Y2pTMWBejAZ1AbridVRr2HEfGqjKnQ9bDjSsvaFNa45dpWao08Ax/IsDbWQgj5CL yo6NraMeq96MzEb6iLYsKls9IXreZ2QyHUrAoxvAymLGhpW82iO90zdk998JSM0Q 4jtgjj4CVGOZBQmtFKq0dscJtHvylQattMcrqMpzGOvESf+pORryb+hlTXVBTRXE cMhc+Jw92552e7z+lJFfKQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1774998113; x= 1775084513; bh=lBuwiN4qeR4cp/7SH69mL0nqRv1FXISJ3o63/YTRGfg=; b=g mQnSYAhgsyOrSnAkj/YHViJUvj8OiAmpYwFkw24F6NVsIu5WMlskx6uvqqHzY6fL 8PppWhL8dPTtie07AOWs0oaVCALp464pZ6hwDPm1qoqI0DQ11mv7sZ8ERBDZNAmr OASopWF885SkfcilJZXeykIfuanC3/Vi/Y001T4qAirq5crfQDhX7GFQfnrV7Pfj /RO4y0l2E3IQ4Msn9lg4d4K0hib9eCKDBJlTbrNRG8aWnANpOrW+gN+HOllg52+u HfbtPBUckTY6IpeevPhdzT019cpRtbyA5c0TuiPPwLORKOccCIgMw+DbAAJTiGpS oarPL1G4UhzL4ake8RacQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefhedrtddtgddugeejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceurghi lhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurh epfffhvfevuffkjghfofggtgfgsehtjeertdertddvnecuhfhrohhmpeetlhgvgicuhghi lhhlihgrmhhsohhnuceorghlvgigsehshhgriigsohhtrdhorhhgqeenucggtffrrghtth gvrhhnpedvkeefjeekvdduhfduhfetkedugfduieettedvueekvdehtedvkefgudegveeu ueenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrlh gvgiesshhhrgiisghothdrohhrghdpnhgspghrtghpthhtohepuddvpdhmohguvgepshhm thhpohhuthdprhgtphhtthhopehluhhkrghsseifuhhnnhgvrhdruggvpdhrtghpthhtoh epsggvrhhnugessghstghhuhdruggvpdhrtghpthhtoheptggrrhhnihhlseguvggsihgr nhdrohhrghdprhgtphhtthhopegshhgvlhhgrggrshesghhoohhglhgvrdgtohhmpdhrtg hpthhtoheprhgrfhgrvghlsehkvghrnhgvlhdrohhrghdprhgtphhtthhopehmrghrihho rdhlihhmohhntghivghllhhosegrmhgurdgtohhmpdhrtghpthhtohepuddufedutddvhe essghughhsrdguvggsihgrnhdrohhrghdprhgtphhtthhopehrvghgrhgvshhsihhonhhs sehlihhsthhsrdhlihhnuhigrdguvghvpdhrtghpthhtohepshhtrggslhgvsehvghgvrh drkhgvrhhnvghlrdhorhhg X-ME-Proxy: Feedback-ID: i03f14258:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 31 Mar 2026 19:01:52 -0400 (EDT) Date: Tue, 31 Mar 2026 17:01:49 -0600 From: Alex Williamson To: Lukas Wunner Cc: Bernd Schumacher , Salvatore Bonaccorso , Bjorn Helgaas , "Rafael J. Wysocki" , Mario Limonciello , 1131025@bugs.debian.org, regressions@lists.linux.dev, stable@vger.kernel.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, alex@shazbot.org Subject: Re: [6.12.y regression] Regression with 58130e7ce6cb ("PCI/ERR: Ensure error recoverability at all times"): echo vfio-pci >driver_override does not work for DVB Adapter Message-ID: <20260331170149.3ee222aa@shazbot.org> In-Reply-To: References: <177373189751.7987.7156982489427825197.reportbug@obelix-trixie.bs.de> <74bcd84500e5efcca035624f325e400dd8a21f44.camel@bschu.de> <5f9386146f426e2847550681cb7188471205607f.camel@bschu.de> X-Mailer: Claws Mail 4.3.1 (GTK 3.24.51; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-pci@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Tue, 31 Mar 2026 15:09:34 +0200 Lukas Wunner wrote: > On Mon, Mar 30, 2026 at 08:14:53AM +0200, Bernd Schumacher wrote: > > [ 0.318903] pci 0000:07:00.0: [dd01:0003] type 00 class 0x048000 PCIe Endpoint > > [ 0.318939] pci 0000:07:00.0: BAR 0 [mem 0xfffffffffc500000-0xfffffffffc50ffff 64bit] > > BIOS initially sets the BAR address to an incorrect value (the top 32 bits > should be all zeroes instead of all ones)... > > > [ 0.339685] pci 0000:07:00.0: BAR 0 [mem 0xfffffffffc500000-0xfffffffffc50ffff 64bit]: can't claim; no compatible bridge window > [...] > > [ 0.311065] pci 0000:02:03.0: [1022:57a3] type 01 class 0x060400 PCIe Switch Downstream Port > > [ 0.311107] pci 0000:02:03.0: PCI bridge to [bus 07] > > [ 0.311118] pci 0000:02:03.0: bridge window [mem 0xfc500000-0xfc5fffff] > > ... this doesn't fit into the window of the bridge above the DVB card, > which has the top 32 bits set to all zeroes... > > > [ 0.357346] pci 0000:07:00.0: BAR 0 [mem 0xfc500000-0xfc50ffff 64bit]: assigned > > ... the kernel fixes the incorrect BAR, but it seems there's an ordering > issue such that pci_save_state() is called beforehand. It's weird that > this doen't occur with newer kernels and it would be good to understand why. > I'm not seeing the ordering issue despite staring at the code for a while. Do we know this isn't occurring on newer kernels? If we have a bogus BAR address that later gets fixed, this seems like a fairly unique setup. AIUI, we're saving the state via the call chain invoked by subsys_initcall(pcibios_init), but I think we're doing the resource fixes in fs_initcall(pcibios_assign_resources). That suggests that the saved state would have the bogus BAR values. If we toss PM runtime into that mix, pci_pm_default_resume_early() will call pci_restore_state() however pci_save_state() in that file is mostly wrapped around pci_dev->state_saved guards. This suggests we likely won't save the reallocated state, but we will restore the pre-reallocated state. Maybe this can be quickly validated by loading vfio-pci with the disable_idle_d3=1 option to avoid the PM transition. Thanks, Alex