Re: [PATCH v6.5 20/25] usb: chipidea: add host role

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

 



On Thu, May 10, 2012 at 09:43:30AM +0200, Matthieu CASTET wrote:
> >
> > [three time's the charm; sorry for spam]
> >
> > > Note that some chipidea version need special callback for phy init
> > > or errata workaround.
> >
> > It can be done similarly to how it's currently done in ehci-mv, I
> > guess. I'm not sure which particular workaround you are referring to,
> > though.
> See http://marc.info/?l=linux-usb&m=133558407107168&w=2 for example.
> I added Peter Chen on CC. I could provide more info on this.
> 
> tegra one also got special callback (tegra_ehci_hub_control, ...)

Dude, you can use platform_device IDs for that, no ? Something like:

static const struct chipidea_driver_data tegra_data __devinitconst = {
	.features	= CHIPIDEA_HAS_TEGRA_BUG_X
			| CHIPIDEA_HAS_TEGRA_BUG_Y,
};

static const struct chipidea_driver_data langwell_data __devinitconst = {
	.features	= CHIPIDEA_HAS_LANGWELL_BUG_X
			| CHIPIDEA_HAS_LANGWELL_BUG_Y,
};

static const struct platform_device_id chipidea_id_table[] __devinitconst = {
	{
		.name		= "tegra-chipidea",
		.driver_data	= (kernel_ulong_t) &tegra_data
	},
	{
		.name		= "langwell-chipidea",
		.driver_data	= (kernel_ulong_t) &langwell_data,
	},
	{  } /* Terminating Entry */
};

The only extra work will be at differentiating between Tegra- or
Langwell-specific bugs and bugs on the ChipIdea IP core, which affect
all users. For ChipIdea IP bugs, you should use revision detection to
apply the workaround.

-- 
balbi

Attachment: signature.asc
Description: Digital signature


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

  Powered by Linux