diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2011-07-29 08:51:26 -0500 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2011-07-29 16:04:56 -0500 |
commit | 57567361769bfa02d0622c06e5e9f66392e2593a (patch) | |
tree | 1714d3f0447e6f9f873243a058e72cca8fc17064 /arch/powerpc | |
parent | a3a3e7b2c35d8bb3c3b6944cb9381d7f66f7875d (diff) | |
download | u-boot-imx-57567361769bfa02d0622c06e5e9f66392e2593a.zip u-boot-imx-57567361769bfa02d0622c06e5e9f66392e2593a.tar.gz u-boot-imx-57567361769bfa02d0622c06e5e9f66392e2593a.tar.bz2 |
powerpc/8xxx: Remove dependency on <usb.h>
We used <usb.h> for USB_MAX_DEVICE. However this requires we actual
build in support for USB into u-boot (which should not be required for
device tree fixup).
At this time no FSL SoC that utilizies this code (83xx/85xx) has more
than 2 USB controllers. So we replace USB_MAX_DEVICE with a local
define FSL_MAX_NUM_USB_CTRLS.
If/when a device shows up with more than 2 controllers we can easily
bump this value or refactor into a proper define per SoC.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc')
-rw-r--r-- | arch/powerpc/cpu/mpc8xxx/fdt.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/powerpc/cpu/mpc8xxx/fdt.c b/arch/powerpc/cpu/mpc8xxx/fdt.c index 6c757f8..285051d 100644 --- a/arch/powerpc/cpu/mpc8xxx/fdt.c +++ b/arch/powerpc/cpu/mpc8xxx/fdt.c @@ -30,9 +30,8 @@ #include <asm/fsl_serdes.h> #include <phy.h> #include <hwconfig.h> -#ifdef CONFIG_HAS_FSL_DR_USB -#include <usb.h> -#endif + +#define FSL_MAX_NUM_USB_CTRLS 2 #if defined(CONFIG_MP) && (defined(CONFIG_MPC85xx) || defined(CONFIG_MPC86xx)) static int ft_del_cpuhandle(void *blob, int cpuhandle) @@ -135,7 +134,7 @@ void fdt_fixup_dr_usb(void *blob, bd_t *bd) char str[5]; int i, j; - for (i = 1; i <= USB_MAX_DEVICE; i++) { + for (i = 1; i <= FSL_MAX_NUM_USB_CTRLS; i++) { int mode_idx = -1, phy_idx = -1; sprintf(str, "%s%d", "usb", i); if (hwconfig(str)) { |