lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250811224659.GA168102@bhelgaas>
Date: Mon, 11 Aug 2025 17:46:59 -0500
From: Bjorn Helgaas <helgaas@...nel.org>
To: Nam Cao <namcao@...utronix.de>
Cc: Nirmal Patel <nirmal.patel@...ux.intel.com>,
	Jonathan Derrick <jonathan.derrick@...ux.dev>,
	Lorenzo Pieralisi <lpieralisi@...nel.org>,
	Krzysztof WilczyƄski <kwilczynski@...nel.org>,
	Manivannan Sadhasivam <mani@...nel.org>,
	Rob Herring <robh@...nel.org>, Bjorn Helgaas <bhelgaas@...gle.com>,
	Thomas Gleixner <tglx@...utronix.de>, linux-pci@...r.kernel.org,
	linux-kernel@...r.kernel.org, Ammar Faizi <ammarfaizi2@...weeb.org>
Subject: Re: [PATCH] PCI: vmd: Remove MSI-X check on child devices

On Mon, Aug 11, 2025 at 07:39:35AM +0200, Nam Cao wrote:
> Commit d7d8ab87e3e7 ("PCI: vmd: Switch to msi_create_parent_irq_domain()")
> added a WARN_ON sanity check that child devices support MSI-X, because VMD
> document says [1]:
> 
>     "Intel VMD only supports MSIx Interrupts from child devices and
>     therefore the BIOS must enable PCIe Hot Plug and MSIx interrups [sic]."

Can VMD tell the difference between an incoming MSI MWr transaction
and an MSI-X MWr?

I wonder if "MSIx" was meant to mean "VMD only supports MSI or MSI-X
interrupts, not INTx interrupts, from child devices"?

I put this on pci/for-linus for v6.17, but it seems like we might want
to clarify the commit log.

> However, on Ammar's machine, a PCIe port below VMD does not support MSI-X,
> triggering this WARN_ON.
> 
> This inconsistency between the document and reality should be investigated
> further. For now, remove the MSI-X check.
> 
> Allowing child devices without MSI-X despite what the document says does
> sound suspicious, but that's what the driver had been doing before the
> WARN_ON is added.
> 
> Fixes: d7d8ab87e3e7 ("PCI: vmd: Switch to msi_create_parent_irq_domain()")
> Link: https://cdrdv2-public.intel.com/776857/VMD_White_Paper.pdf [1]
> Reported-by: Ammar Faizi <ammarfaizi2@...weeb.org>
> Closes: https://lore.kernel.org/linux-pci/aJXYhfc%2F6DfcqfqF@linux.gnuweeb.org/
> Tested-by: Ammar Faizi <ammarfaizi2@...weeb.org>
> Signed-off-by: Nam Cao <namcao@...utronix.de>
> ---
>  drivers/pci/controller/vmd.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/pci/controller/vmd.c b/drivers/pci/controller/vmd.c
> index b679c7f28f51..1bd5bf4a6097 100644
> --- a/drivers/pci/controller/vmd.c
> +++ b/drivers/pci/controller/vmd.c
> @@ -306,9 +306,6 @@ static bool vmd_init_dev_msi_info(struct device *dev, struct irq_domain *domain,
>  				  struct irq_domain *real_parent,
>  				  struct msi_domain_info *info)
>  {
> -	if (WARN_ON_ONCE(info->bus_token != DOMAIN_BUS_PCI_DEVICE_MSIX))
> -		return false;
> -
>  	if (!msi_lib_init_dev_msi_info(dev, domain, real_parent, info))
>  		return false;
>  
> -- 
> 2.39.5
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ