Re: [PATCH v2 4/4] staging: media: zoran: replace dprintk with new debugging macros

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

 



On Fri, May 06, 2022 at 01:30:12AM -0400, Ian Cowan wrote:
> On Thu, Apr 28, 2022 at 10:15:03AM +0200, Hans Verkuil wrote:
> > Hi Ian,
> > 
> > When I compiled this patch series with smatch I got these warnings:
> > 
> > zoran/videocodec.c:45 videocodec_attach() warn: variable dereferenced before check 'master' (see line 40)
> > zoran/videocodec.c:115 videocodec_detach() warn: variable dereferenced before check 'codec' (see line 111)
> > zoran/videocodec.c:168 videocodec_register() warn: variable dereferenced before check 'codec' (see line 166)
> > zoran/videocodec.c:200 videocodec_unregister() warn: variable dereferenced before check 'codec' (see line 198)
> > 
> > And I also got this warning when checking the kerneldoc:
> > 
> > zoran/zoran.h:307: warning: This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst
> > 
> > Can you fix this and post a v3?
> > 
> > Thanks!
> > 
> > 	Hans
> 
> I just resubmitted v3.
> 
> What did you use to see these issues? When I ran the checkpatch script
> and compiled, I did not see any of this.
> 

I have written a blog entry about checking kernel code with Smatch:

https://staticthinking.wordpress.com/2022/04/25/how-to-run-smatch-on-your-code/

regards,
dan carpenter





[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux