Re: [PATCH 3/3] USB: EHCI: Add a generic platform device driver

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

 



On Sun, 12 Feb 2012, Hauke Mehrtens wrote:

> This adds a generic driver for platform devices. It works like the PCI
> driver and is based on it. This is for devices which do not have an own
> bus but their EHCI controller works like a PCI controller. It will be
> used for the Broadcom bcma and ssb USB EHCI controller.

> +static int ehci_platform_reset(struct usb_hcd *hcd)
> +{
> +	struct platform_device *pdev = to_platform_device(hcd->self.controller);
> +	struct usb_hci_pdata *pdata = pdev->dev.platform_data;

A minor problem here is that quite a few of the existing platform 
drivers already use pdev->dev.platform_data for their own structures.  
Somehow those structures will need to be combined with your 
usb_hci_pdata stuff.  Have you considered how to do this?

Obviously it's not a major problem because the other drivers can be 
switched over to your scheme one at a time.  Still, it's worth thinking 
over.

Alan Stern

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