Re: [PATCH] drm/i915/selftests: Fix an IS_ERR() vs NULL check

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

 



On Tue, Mar 26, 2019 at 02:53:49PM +0000, Chris Wilson wrote:
> Quoting Mika Kuoppala (2019-03-26 09:30:57)
> > Dan Carpenter <dan.carpenter@xxxxxxxxxx> writes:
> > 
> > > The live_context() function returns error pointers.  It never returns
> > > NULL.
> > >
> > > Fixes: 9c1477e83e62 ("drm/i915/selftests: Exercise adding requests to a full GGTT")
> > > Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> > 
> > Reviewed-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxxxxxxxx>
> > 
> > i915_request.c has another :)
> 
> Having found it, you could have typed up the patch :-p
> 

Smatch didn't warn about that one because we didn't dereference it right
away...  I should make a check which complains about the condition
instead of the dereference.

regards,
dan carpenter

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux