Re: [PATCH] IB/core: type promotion bug in rdma_rw_init_one_mr()

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

 



On Wed, Jul 04, 2018 at 07:27:43PM +0300, Leon Romanovsky wrote:
> On Wed, Jul 04, 2018 at 08:49:47AM -0600, Jason Gunthorpe wrote:
> > On Wed, Jul 04, 2018 at 12:55:41PM +0200, Håkon Bugge wrote:
> > >    Is:
> > >
> > >    if (ret < (int)nents) {
> > >
> > >    a more intuitive fix?
> >
> > That could lead to truncation/force negativeness of nents :(
> 
> IS_ERROR_VALUE() from include/linux/err.h?
> 

Heh.  Please, no.  First of all that doesn't work, but also that's not
how IS_ERROR_VALUE() is supposed to be used.

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux