Commit 26aaa3df authored by Anand Gadiyar's avatar Anand Gadiyar Committed by Tony Lindgren

ARM: OMAP: USB: Fix potential resource overlap due to incorrect end address

The end address for the USB memory resources were incorrectly defined as
(<start> + <size>) instead of (<start> + <size - 1>) resulting in a
potential overlap with the start address of other resources.
Signed-off-by: default avatarAnand Gadiyar <gadiyar@ti.com>
Acked-by: default avatarNishant Kamat <nskamat@ti.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent 689fe67c
......@@ -23,7 +23,7 @@
static struct resource musb_resources[] = {
[0] = {
.start = OMAP243X_HS_BASE,
.end = OMAP243X_HS_BASE + SZ_8K,
.end = OMAP243X_HS_BASE + SZ_8K - 1,
.flags = IORESOURCE_MEM,
},
[1] = { /* general IRQ */
......
......@@ -29,7 +29,7 @@
static struct resource musb_resources[] = {
[0] = {
.start = OMAP34XX_HSUSB_OTG_BASE,
.end = OMAP34XX_HSUSB_OTG_BASE + SZ_8K,
.end = OMAP34XX_HSUSB_OTG_BASE + SZ_8K - 1,
.flags = IORESOURCE_MEM,
},
[1] = { /* general IRQ */
......@@ -100,7 +100,7 @@ static struct platform_device musb_device = {
static struct resource ehci_resources[] = {
[0] = {
.start = OMAP34XX_HSUSB_HOST_BASE + 0x800,
.end = OMAP34XX_HSUSB_HOST_BASE + 0x800 + SZ_1K,
.end = OMAP34XX_HSUSB_HOST_BASE + 0x800 + SZ_1K - 1,
.flags = IORESOURCE_MEM,
},
[1] = { /* general IRQ */
......
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