Commit 72d4b284 authored by Felipe Balbi's avatar Felipe Balbi Committed by Greg Kroah-Hartman

usb: host: xhci: plat: change type of mvebu init_quirk()

Just like RCAR's init_quirk() we want mvebu's to use
struct usb_hcd * as argument too. This is another
step towards removing xhci_plat_type_is().
Acked-by: default avatarYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@linux.intel.com>
Signed-off-by: default avatarMathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 3bdb263d
...@@ -12,6 +12,9 @@ ...@@ -12,6 +12,9 @@
#include <linux/of.h> #include <linux/of.h>
#include <linux/platform_device.h> #include <linux/platform_device.h>
#include <linux/usb.h>
#include <linux/usb/hcd.h>
#include "xhci-mvebu.h" #include "xhci-mvebu.h"
#define USB3_MAX_WINDOWS 4 #define USB3_MAX_WINDOWS 4
...@@ -41,8 +44,10 @@ static void xhci_mvebu_mbus_config(void __iomem *base, ...@@ -41,8 +44,10 @@ static void xhci_mvebu_mbus_config(void __iomem *base,
} }
} }
int xhci_mvebu_mbus_init_quirk(struct platform_device *pdev) int xhci_mvebu_mbus_init_quirk(struct usb_hcd *hcd)
{ {
struct device *dev = hcd->self.controller;
struct platform_device *pdev = to_platform_device(dev);
struct resource *res; struct resource *res;
void __iomem *base; void __iomem *base;
const struct mbus_dram_target_info *dram; const struct mbus_dram_target_info *dram;
......
...@@ -10,10 +10,13 @@ ...@@ -10,10 +10,13 @@
#ifndef __LINUX_XHCI_MVEBU_H #ifndef __LINUX_XHCI_MVEBU_H
#define __LINUX_XHCI_MVEBU_H #define __LINUX_XHCI_MVEBU_H
struct usb_hcd;
#if IS_ENABLED(CONFIG_USB_XHCI_MVEBU) #if IS_ENABLED(CONFIG_USB_XHCI_MVEBU)
int xhci_mvebu_mbus_init_quirk(struct platform_device *pdev); int xhci_mvebu_mbus_init_quirk(struct usb_hcd *hcd);
#else #else
static inline int xhci_mvebu_mbus_init_quirk(struct platform_device *pdev) static inline int xhci_mvebu_mbus_init_quirk(struct usb_hcd *hcd)
{ {
return 0; return 0;
} }
......
...@@ -73,10 +73,7 @@ static int xhci_plat_setup(struct usb_hcd *hcd) ...@@ -73,10 +73,7 @@ static int xhci_plat_setup(struct usb_hcd *hcd)
} }
if (xhci_plat_type_is(hcd, XHCI_PLAT_TYPE_MARVELL_ARMADA)) { if (xhci_plat_type_is(hcd, XHCI_PLAT_TYPE_MARVELL_ARMADA)) {
struct platform_device *pdev; ret = xhci_mvebu_mbus_init_quirk(hcd);
pdev = to_platform_device(hcd->self.controller);
ret = xhci_mvebu_mbus_init_quirk(pdev);
if (ret) if (ret)
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment