[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y71EaQkwvw2OMVHC@unreal>
Date: Tue, 10 Jan 2023 12:56:41 +0200
From: Leon Romanovsky <leon@...nel.org>
To: Tony Nguyen <anthony.l.nguyen@...el.com>
Cc: davem@...emloft.net, kuba@...nel.org, pabeni@...hat.com,
edumazet@...gle.com, Jiasheng Jiang <jiasheng@...as.ac.cn>,
netdev@...r.kernel.org, Jiri Pirko <jiri@...dia.com>,
Gurucharan G <gurucharanx.g@...el.com>
Subject: Re: [PATCH net 2/2] ice: Add check for kzalloc
On Mon, Jan 09, 2023 at 02:53:58PM -0800, Tony Nguyen wrote:
> From: Jiasheng Jiang <jiasheng@...as.ac.cn>
>
> Add the check for the return value of kzalloc in order to avoid
> NULL pointer dereference.
> Moreover, use the goto-label to share the clean code.
>
> Fixes: d6b98c8d242a ("ice: add write functionality for GNSS TTY")
> Signed-off-by: Jiasheng Jiang <jiasheng@...as.ac.cn>
> Reviewed-by: Jiri Pirko <jiri@...dia.com>
> Tested-by: Gurucharan G <gurucharanx.g@...el.com> (A Contingent worker at Intel)
> Signed-off-by: Tony Nguyen <anthony.l.nguyen@...el.com>
> ---
> drivers/net/ethernet/intel/ice/ice_gnss.c | 23 ++++++++++++++---------
> 1 file changed, 14 insertions(+), 9 deletions(-)
>
Thanks,
Reviewed-by: Leon Romanovsky <leonro@...dia.com>
Powered by blists - more mailing lists