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: <Y+pOD5+DAsm3IKup@rric.localdomain>
Date:   Mon, 13 Feb 2023 15:49:51 +0100
From:   Robert Richter <rric@...nel.org>
To:     Dan Williams <dan.j.williams@...el.com>
Cc:     Robert Richter <rrichter@....com>,
        Alison Schofield <alison.schofield@...el.com>,
        Vishal Verma <vishal.l.verma@...el.com>,
        Ira Weiny <ira.weiny@...el.com>,
        Ben Widawsky <bwidawsk@...nel.org>,
        Jonathan Cameron <jonathan.cameron@...wei.com>,
        Dave Jiang <dave.jiang@...el.com>, linux-cxl@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] cxl/port: Disable decoder setup for endpoints in RCD mode

Dan,

On 09.02.23 09:07:18, Dan Williams wrote:
> Robert Richter wrote:
> > In RCD mode the HDM decoder capability is optional for endpoints and
> > may not exist. The HDM range registers are used instead. Since the
> > driver relies on the existence of an HDM decoder capability, its
> > absence will cause the initialization of a memory card to fail.
> > 
> > Moreover, the driver also tries to enable or reuse enabled memory
> > ranges. In the worst case this may lead to a system hang due to
> > disabling system memory that was previously provided and setup by
> > system firmware.
> > 
> > To solve the issues described, disable decoder setup for RCD endpoints
> > and instead rely exclusively on system firmware to enable those memory
> > ranges. Decoders are used by the kernel to setup and configure CXL
> > memory regions, esp. to enable and disable them. Since Hot-plug is not
> > supported for devices in RCD mode, the ability to disable that memory
> > by the kernel using a decoder is not a necessarily requirement,
> > decoders are not needed then.
> > 
> > Fixes: 34e37b4c432c ("cxl/port: Enable HDM Capability after validating DVSEC Ranges")
> > Signed-off-by: Robert Richter <rrichter@....com>
> 
> Does Dave's series address this problem?
> 
> https://lore.kernel.org/linux-cxl/167588394236.1155956.8466475582138210344.stgit@djiang5-mobl3.local/
> 
> ...that is arranging for the driver to carry-on in the absence of the
> HDM Decoder Capability.

it might only solve the missing hdm decoder capability. I need to take
a closer look if that also solves a system hang I was debugging which
is caused by clearing the memory disable bit in the hdm dvsec range
register. So the best would be to use this patch now to fix decoder
initialization in RCD mode and then have Dave's patches on top. I am
going to test the series too.

Thanks,

-Robert

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ