Skip to content
Commit cc1b0765 authored by sricharan's avatar sricharan Committed by Tony Lindgren
Browse files

ARM: OMAP: hwmod: Fix the addr space, irq, dma count APIs



The address spaces, irqs and dma reqs count APIs return the
number of corresponding entries in a hwmod including a additional
null value or a -1 terminator in the structure introduced recently.
More information here:

- 212738a4: omap_hwmod: use a terminator record with omap_hwmod_mpu_irqs
  arrays

- 78183f3f: omap_hwmod: use a null structure record to terminate
  omap_hwmod_addr_space arrays

- bc614958: omap_hwmod: use a terminator record with omap_hwmod_dma_info
  arrays

The issue with irqs and dma info was originally reported by Benoit Cousson.

The devices which have multiple hwmods and use device_build_ss are
broken with this, as their resources are populated with a extra null
value, subsequently the probe fails. So fix the API not to include
the array terminator in the count.

Reported-by: default avatarBenoit Cousson <b-cousson@ti.com>
Signed-off-by: default avatarSantosh Shilimkar <santosh.shilimar@ti.com>
Signed-off-by: default avatarsricharan <r.sricharan@ti.com>
Signed-off-by: default avatarBenoit Cousson <b-cousson@ti.com>
Cc: Paul Walmsley <paul@pwsan.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent cfcfc9ec
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment