Re: [PATCH 09/11] usb: musb: break the huge isr musb_stage0_irq() into small functions

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

 



On Wed, Apr 18, 2018 at 08:33:52AM -0500, Bin Liu wrote:
> Hi Dan,
> 
> I appreciate you scaning  the patches and reporting the issues.
> 

These are kbuild stuff so I basically just forward them.  It's no
effort.

> On Wed, Apr 18, 2018 at 10:25:34AM +0300, Dan Carpenter wrote:
> > Hi Bin,
> > 
> > I love your patch! Perhaps something to improve:
> > 
> > [auto build test WARNING on balbi-usb/next]
> > [also build test WARNING on v4.17-rc1 next-20180417]
> > [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
> > 
> > url:    https://github.com/0day-ci/linux/commits/Bin-Liu/usb-musb-cleanup/20180417-133633
> > base:   https://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git next
> > 
> > smatch warnings:
> > drivers/usb/musb/musb_core.c:797 musb_handle_intr_connect() error: we previously assumed 'musb->hcd' could be null (see line 783)
> 
> It appears the condition check was introduced back in 2013 in an attempt
> to separate host-only and gadget-only configurations for musb [1], but it
> seems the work is not complete, because the musb->hcd allocation is
> unconditional. So in the current code, musb->hcd won't be NULL. 
> 
> But I am now hesitated to remove this 'if(musb->hcd)' check to solve
> this smatch warning, because I am still debating on either continue the
> work to separate the two configurations or clean up the uncompleted code
> left by the attempt to not separate them.
> 
> So I want to leave the patch as is for now, is it reasonable?
> 

Fine by me.  Right now it's sort of hard for Smatch to parse the code
well enough for it to know that ->hcd is always non-NULL but I'm
hopeful that maybe in a couple years that will be possible...

regards,
dan carpenter

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



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux