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] [day] [month] [year] [list]
Message-ID: <675780f0693e6_25073294fe@dwillia2-xfh.jf.intel.com.notmuch>
Date: Mon, 9 Dec 2024 15:44:48 -0800
From: Dan Williams <dan.j.williams@...el.com>
To: Li Ming <ming.li@...omail.com>, <kobayashi.da-06@...itsu.com>,
	<dave@...olabs.net>, <jonathan.cameron@...wei.com>, <dave.jiang@...el.com>,
	<alison.schofield@...el.com>, <vishal.l.verma@...el.com>,
	<ira.weiny@...el.com>, <dan.j.williams@...el.com>
CC: <linux-cxl@...r.kernel.org>, <linux-kernel@...r.kernel.org>, Li Ming
	<ming.li@...omail.com>
Subject: Re: [PATCH 1/1] cxl/pci: Check dport->regs.rcd_pcie_cap availability
 before accessing

Li Ming wrote:
> RCD Upstream Port's PCI Express Capability is a component registers
> block stored in RCD Upstream Port RCRB. CXL PCI driver helps to map it
> during the RCD probing, but mapping failure is allowed for component
> registers blocks in CXL PCI driver.
> 
> dport->regs.rcd_pcie_cap is used to store the virtual address of the RCD
> Upstream Port's PCI Express Capability, add a dport->regs.rcd_pcie_cap
> checking in rcd_pcie_cap_emit() just in case user accesses a invalid
> address via RCD sysfs.
> 
> Fixes: c5eaec79fa43 ("cxl/pci: Add sysfs attribute for CXL 1.1 device link status")
> Signed-off-by: Li Ming <ming.li@...omail.com>

Hi Ming,

This patch looks ok.

Reviewed-by: Dan Williams <dan.j.williams@...el.com>

...but it bothers me that the sysfs attributes are visible while the
attributes are in this -ENXIO return state. I will throw together a
follow-on patch to hide the attributes altogether when these
preconditions are not met.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ