From: Simon Glass Date: Sun, 3 Jan 2016 20:50:30 +0000 (-0700) Subject: usb: Allow up to 7 storage devices X-Git-Url: http://git.dujemihanovic.xyz/img/sics.gif?a=commitdiff_plain;h=70caa97108d790e5779b347a8530b130df9f000a;p=u-boot.git usb: Allow up to 7 storage devices The current limit of 5 is not enough for the driver model USB tests. Really we should not have a limit but the driver model code still uses the usb_dev_desc[] array, which has a limit. Increasing the limit by 2 should not bother anyone. Adjust it. Signed-off-by: Simon Glass Reviewed-by: Marek Vasut --- diff --git a/common/usb_storage.c b/common/usb_storage.c index 4fa6538db5..e61a8c8adf 100644 --- a/common/usb_storage.c +++ b/common/usb_storage.c @@ -65,7 +65,7 @@ static const unsigned char us_direction[256/8] = { static ccb usb_ccb __attribute__((aligned(ARCH_DMA_MINALIGN))); static __u32 CBWTag; -#define USB_MAX_STOR_DEV 5 +#define USB_MAX_STOR_DEV 7 static int usb_max_devs; /* number of highest available usb device */ static block_dev_desc_t usb_dev_desc[USB_MAX_STOR_DEV]; diff --git a/include/usb.h b/include/usb.h index 2539364565..0b410b6cd1 100644 --- a/include/usb.h +++ b/include/usb.h @@ -227,7 +227,7 @@ int board_usb_cleanup(int index, enum usb_init_type init); #ifdef CONFIG_USB_STORAGE -#define USB_MAX_STOR_DEV 5 +#define USB_MAX_STOR_DEV 7 block_dev_desc_t *usb_stor_get_dev(int index); int usb_stor_scan(int mode); int usb_stor_info(void);