staging: fsl-mc: Allocate IRQ's before scanning DPRC objects
Following is the current scenario when the devices are probed:
FSL_MC Bus probe ---> dprc probe ---> dprc devices scan --->
probe devices in DPRC container ---> allocate IRQ's
In case the devices being probed in the DPRC container need the IRQ's;
probing of that device will fail.
In current scenario the devices which need IRQ's such as DPIO gets
deferred because they aren't registered when first time the probing
of these devices is done in the dprc scan.
So they are probed once IRQ's have been allocated.
In case where DPRC probing itself gets deferred, which does in case
IOMMU is enabled; all the devices in DPRC container gets probed before
IRQ's are allocated. This causes devices using IRQ's (such as DPIO)
to fail.
So having IRQ's allocated before any of the devices in the DPRC container
are probed is more legitimate.
After this patch following is the flow of execution:
FSL_MC Bus probe ---> dprc probe ---> dprc devices scan --->
allocate IRQ's ---> probe of devices in DPRC container.
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Reviewed-by: Bharat Bhushan <bharat.bhushan@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>