RE: [PATCH 06/41] usb: gadget: add max_speed to usb_composite_driver

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

 



> > > > @@ -165,6 +165,11 @@ static struct usb_composite_driver
> audio_driver = {
> > > >  	.name		= "g_audio",
> > > >  	.dev		= &device_desc,
> > > >  	.strings	= audio_strings,
> > > > +#ifdef CONFIG_USB_GADGET_DUALSPEED
> > > > +	.max_speed		= USB_SPEED_HIGH,
> > > > +#else
> > > > +	.max_speed		= USB_SPEED_FULL,
> > > > +#endif /* CONFIG_USB_GADGET_DUALSPEED */
> > >
> > > Really?
> > >
> > > Come on, this is a mess, we don't want #ifdefs in .c files for a
> reason,
> > > and this is an example of that.
> >
> > This was discussed in a recent email exchange.  Those #ifdefs are
> > completely unnecessary: max_speed is supposed to be the maximum speed
> > supported by the driver, regardless of what the hardware allows.
> >
> > In this example, the code should simply say:
> >
> > 	.max_speed	= USB_SPEED_HIGH,
> >
> > The other drivers should be handled similarly.
> 
> Ok, I thought that was the result, and so was confused when I saw the
> patch.
> 
> So it's good that I rejected it :)
> 

I'll resend a fixed patch till the end of the day.

Thanks,
Tanya Brokhman
---
Sent by an consultant of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.





--
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