RE: [PATCH -next] ice: fix return value check in ice_gnss.c

From: G, GurucharanX
Date: Fri Mar 11 2022 - 01:35:02 EST




> -----Original Message-----
> From: Yang Yingliang <yangyingliang@xxxxxxxxxx>
> Sent: Saturday, March 5, 2022 2:35 PM
> To: linux-kernel@xxxxxxxxxxxxxxx; intel-wired-lan@xxxxxxxxxxxxxxxx
> Cc: netdev@xxxxxxxxxxxxxxx; kuba@xxxxxxxxxx; davem@xxxxxxxxxxxxx;
> Nguyen, Anthony L <anthony.l.nguyen@xxxxxxxxx>; Kolacinski, Karol
> <karol.kolacinski@xxxxxxxxx>
> Subject: [PATCH -next] ice: fix return value check in ice_gnss.c
>
> kthread_create_worker() and tty_alloc_driver() return ERR_PTR() and never
> return NULL. The NULL test in the return value check should be replaced with
> IS_ERR().
>
> Fixes: 43113ff73453 ("ice: add TTY for GNSS module for E810T device")
> Reported-by: Hulk Robot <hulkci@xxxxxxxxxx>
> Signed-off-by: Yang Yingliang <yangyingliang@xxxxxxxxxx>
> ---
> drivers/net/ethernet/intel/ice/ice_gnss.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>

Tested-by: Gurucharan <gurucharanx.g@xxxxxxxxx> (A Contingent worker at Intel)