Re: [PATCH] net/rds: Use ERR_PTR for rds_message_alloc_sgs()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Jason Gunthorpe <jgg@xxxxxxxx>
Date: Tue, 14 Apr 2020 20:02:07 -0300

> From: Jason Gunthorpe <jgg@xxxxxxxxxxxx>
> 
> Returning the error code via a 'int *ret' when the function returns a
> pointer is very un-kernely and causes gcc 10's static analysis to choke:
> 
> net/rds/message.c: In function ʽrds_message_map_pagesʼ:
> net/rds/message.c:358:10: warning: ʽretʼ may be used uninitialized in this function [-Wmaybe-uninitialized]
>   358 |   return ERR_PTR(ret);
> 
> Use a typical ERR_PTR return instead.
> 
> Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxxxx>

Applied, thanks.




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux