ARM i.MX ehci: factor out soc specific functions
[deliverable/linux.git] / arch / arm / plat-mxc / ehci.c
CommitLineData
7e8d5cd9
DM
1/*
2 * Copyright (c) 2009 Daniel Mack <daniel@caiaq.de>
5a25ad84 3 * Copyright (C) 2010 Freescale Semiconductor, Inc.
7e8d5cd9
DM
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * for more details.
7e8d5cd9
DM
14 */
15
16#include <linux/platform_device.h>
7e8d5cd9
DM
17
18#include <mach/hardware.h>
19#include <mach/mxc_ehci.h>
20
5a25ad84 21int mxc_initialize_usb_hw(int port, unsigned int flags)
7e8d5cd9 22{
972cc482 23#if defined(CONFIG_SOC_IMX25)
cb07625d
SH
24 if (cpu_is_mx25())
25 return mx25_initialize_usb_hw(port, flags);
972cc482 26#endif /* if defined(CONFIG_SOC_IMX25) */
648beaf5 27#if defined(CONFIG_ARCH_MX3)
cb07625d
SH
28 if (cpu_is_mx31())
29 return mx31_initialize_usb_hw(port, flags);
30 if (cpu_is_mx35())
31 return mx35_initialize_usb_hw(port, flags);
9cf945cb
SH
32#endif /* CONFIG_ARCH_MX3 */
33#ifdef CONFIG_MACH_MX27
cb07625d
SH
34 if (cpu_is_mx27())
35 return mx27_initialize_usb_hw(port, flags);
9cf945cb 36#endif /* CONFIG_MACH_MX27 */
d94ed128 37#ifdef CONFIG_SOC_IMX51
cb07625d
SH
38 if (cpu_is_mx51())
39 return mx51_initialize_usb_hw(port, flags);
5a25ad84 40#endif
7e8d5cd9
DM
41 printk(KERN_WARNING
42 "%s() unable to setup USBCONTROL for this CPU\n", __func__);
43 return -EINVAL;
44}
5a25ad84 45EXPORT_SYMBOL(mxc_initialize_usb_hw);
7e8d5cd9 46
This page took 0.071221 seconds and 5 git commands to generate.