[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2024071500-certainly-kick-11c8@gregkh>
Date: Mon, 15 Jul 2024 07:12:32 +0200
From: Greg KH <gregkh@...uxfoundation.org>
To: Ma Ke <make24@...as.ac.cn>
Cc: fbarrat@...ux.ibm.com, ajd@...ux.ibm.com, arnd@...db.de,
mpe@...erman.id.au, manoj@...ux.vnet.ibm.com, imunsie@....ibm.com,
clombard@...ux.vnet.ibm.com, linuxppc-dev@...ts.ozlabs.org,
linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH v4] cxl: Fix possible null pointer dereference in
read_handle()
On Mon, Jul 15, 2024 at 10:54:42AM +0800, Ma Ke wrote:
> In read_handle(), of_get_address() may return NULL if getting address and
> size of the node failed. When of_read_number() uses prop to handle
> conversions between different byte orders, it could lead to a null pointer
> dereference. Add NULL check to fix potential issue.
>
> Found by static analysis.
You need to describe the tool that found this. And how did you test
that your fix is correct?
thanks,
greg k-h
Powered by blists - more mailing lists