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: <20241017145025.00002fd3@Huawei.com>
Date: Thu, 17 Oct 2024 14:50:25 +0100
From: Jonathan Cameron <Jonathan.Cameron@...wei.com>
To: Terry Bowman <Terry.Bowman@....com>
CC: <ming4.li@...el.com>, <linux-cxl@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>, <linux-pci@...r.kernel.org>,
	<dave@...olabs.net>, <dave.jiang@...el.com>, <alison.schofield@...el.com>,
	<vishal.l.verma@...el.com>, <dan.j.williams@...el.com>,
	<bhelgaas@...gle.com>, <mahesh@...ux.ibm.com>, <oohall@...il.com>,
	<Benjamin.Cheatham@....com>, <rrichter@....com>, <nathan.fontenot@....com>,
	<smita.koralahallichannabasappa@....com>
Subject: Re: [PATCH 09/15] cxl/pci: Map CXL PCIe downstream port RAS
 registers

On Wed, 16 Oct 2024 13:16:34 -0500
Terry Bowman <Terry.Bowman@....com> wrote:

> Hi Jonathan,
> 
> On 10/16/24 12:14, Jonathan Cameron wrote:
> > On Tue, 8 Oct 2024 17:16:51 -0500
> > Terry Bowman <terry.bowman@....com> wrote:
> >   
> >> RAS registers are not mapped for CXL root ports, CXL downstream switch
> >> ports, or CXL upstream switch ports. To prepare for future RAS logging
> >> and handling, the driver needs updating to map PCIe port RAS registers.  
> > 
> > Give the upstream port is in next patch, I'd just mention that you
> > are adding mapping of RP and DSP here (This confused me before I noticed
> > the next patch).  
> 
> Ok. Good point, 
> 
> >>
> >> Refactor and rename cxl_setup_parent_dport() to be cxl_init_ep_ports_aer().
> >> Update the function such that it will iterate an endpoint's dports to map
> >> the RAS registers.
> >>
> >> Rename cxl_dport_map_regs() to be cxl_dport_init_aer(). The new
> >> function name is a more accurate description of the function's work.
> >>
> >> This update should also include checking for previously mapped registers
> >> within the topology, particularly with CXL switches. Endpoints under a
> >> CXL switch may share a common downstream and upstream port, ensure that
> >> the registers are only mapped once.  
> > 
> > I don't understand why we need to do this for the ras registers but
> > it doesn't apply for HDM decoders for instance?  Why can't
> > we map these registers in cxl_port_probe()?
> >   
> 
> We have seen downstream root ports with DVSECs that are not fully populated 
> immediately after booting. The plan here was to push out the RAS register 
> block mapping until as late as possible, in the memdev driver. 

That needs debugging because simply pushing it later like this is
only going to make the race harder to hit unless we understand the
'why' of that.   If there is a reason to delay, my gut feeling would
be to delay the cxl_port_probe() until things are stable rather
than just trying this a bit later.

This might be the whole link must train before CXL registers are
presented thing (a less than ideal corner of the CXL spec) but not
sure it would mean they weren't available in cxl_port_probe()

Jonathan



> 
> 
> > End of day here, so maybe I'm completely misunderstanding this.
> > Will take another look tomorrow morning.
> >   
> 
> Thanks for your reviews.
> 
> Regards,
> Terry
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ