dmaengine: qcom_hidma: simplify DT resource parsing
authorRob Herring <robh@kernel.org>
Thu, 4 Jan 2018 22:45:40 +0000 (16:45 -0600)
committerVinod Koul <vinod.koul@intel.com>
Mon, 8 Jan 2018 17:01:02 +0000 (22:31 +0530)
commit37fa4905d22a903f9fe120016fe7d6a2ece8d736
tree0fc2ebe926795746d0a9ee8299dcfdcbbd4a0f89
parent38680bc6b1e3592bc9e18adc1d6e259667df27ce
dmaengine: qcom_hidma: simplify DT resource parsing

The hidma driver open codes populating address and IRQ resources from DT.
We have standard functions of_address_to_resource and of_irq_to_resource
for this, so use them instead.

The DT binding states each child should have 2 addresses and 1 IRQ, so we
can simplify the logic and do a fixed size resource allocation. Using the
standard of_address_to_resource will also do any address translation which
was missing.

Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Sinan Kaya <okaya@codeaurora.org>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/qcom/hidma_mgmt.c