On Mon, 20 Jun 2005, Alexey Dobriyan wrote:

> > This patch provides an "isp116x-hcd" driver for Philips'
> > ISP1160/ISP1161 USB host controllers.
> --- /dev/null
> +++ gregkh-2.6/drivers/usb/host/isp116x-hcd.c
> 
> > + *The driver passes all usbtests 1-14.
> 
> Missing space.
> 
> > +static void preproc_atl_queue(struct isp116x *isp116x)
> > +{
> 
> > +                   /* To please gcc */
> > +                   toggle = dir = 0;
> 
> Oh, just ignore bogus warnings. It's easy. ;-)
> 
> > +                   ERR("%s %d: ep->nextpid %d\n", __func__, __LINE__,
> > +                       ep->nextpid);
> > +                   BUG_ON(1);
> 
> Simply BUG().
> 
> > +static int isp116x_urb_enqueue(struct usb_hcd *hcd,
> > +                          struct usb_host_endpoint *hep, struct urb *urb,
> > +                          int mem_flags)
> > +{
> 
> > +   if (!hep->hcpriv) {
> > +           ep = kcalloc(1, sizeof *ep, (__force unsigned)mem_flags);
> 
> Please, drop this cast. The right thing is to change ->urb_enqueue method to
> accept unsigned int mem_flags.

Greg, who is going to make this change to the USB core and 
to other HCDs? I can do it, but I guess it'll take a while 
before I learn obtaining the latest git tree. Or would it 
suffice to make this against 2.6.12?

> 
> > +           if (!ep)
> > +                   return -ENOMEM;
> > +   }
> 
> > +static int isp116x_hub_control(struct usb_hcd *hcd,
> > +                          u16 typeReq,
> > +                          u16 wValue, u16 wIndex, char *buf, u16 wLength)
> > +{
> 
> > +   case GetHubStatus:
> > +           DBG("GetHubStatus\n");
> > +           *(__le32 *) buf = cpu_to_le32(0);
>                                 ^^^^^^^^^^^
> Not needed. Zero is zero.
> 
> > +static int isp116x_suspend(struct device *dev, pm_message_t state, u32 
> > phase)
> > +{
> 
> > +           INFO("%s suspended\n", (char *)hcd_name);
> > +   } else
> > +           ERR("%s suspend failed\n", (char *)hcd_name);
> 
> Useless casts.
> 
> 

Greg, Alexey,

I will make the changes proposed by Alexey. Greg, should I
regenerate a new patch for the whole driver and submit it to
you or just make a patch for the proposed changes and
send it to Alexey. Or still some other way?
  
Greg, there is also a ...usb-isp116x-hcd-fix.patch among
your patches that applies on top of the patch just reviewed
by Alexey. Should I integrate these fixes with the patch I'm
going to generate?

Olav



-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to