[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Tue, 7 Jul 2020 23:34:42 +0200
From: Luca Ceresoli <luca@...aceresoli.net>
To: Adam Ford <aford173@...il.com>, linux-clk@...r.kernel.org
Cc: dan.carpenter@...cle.com, aford@...conembedded.com,
charles.stevens@...icpd.com, Marek Vasut <marek.vasut@...il.com>,
Michael Turquette <mturquette@...libre.com>,
Stephen Boyd <sboyd@...nel.org>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH V2] clk: vc5: Add memory check to prevent oops
Hi Adam,
On 06/07/20 22:37, Adam Ford wrote:
> When getting the names of the child nodes, kasprintf is used to
> allocate memory which is used to create the string for the node
> name. Unfortunately, there is no memory check to determine
> if this allocation fails, it may cause an error when trying
> to get child node name.
>
> This patch will check if the memory allocation fails, and returns
> and -NOMEM error instead of blindly moving on.
s/-NOMEM/-ENOMEM/
With this possibly fixed:
Reviewed-by: Luca Ceresoli <luca@...aceresoli.net>
--
Luca
Powered by blists - more mailing lists