PCI: rockchip: fix crash due to CONFIG_ROCKCHIP_PCIE_DMA_OBJ disabled
Change-Id: I0d3cd35150276e353fd06e4fa481b71a125f533c Signed-off-by: Simon Xue <xxm@rock-chips.com>
This commit is contained in:
parent
5bd3725c9a
commit
be2e272c83
2 changed files with 9 additions and 5 deletions
|
|
@ -1180,12 +1180,14 @@ static int rk_pcie_probe(struct platform_device *pdev)
|
|||
break;
|
||||
}
|
||||
|
||||
rk_pcie->dma_obj->start_dma_func = rk_pcie_start_dma_dwc;
|
||||
rk_pcie->dma_obj->config_dma_func = rk_pcie_config_dma_dwc;
|
||||
|
||||
if (ret)
|
||||
goto deinit_clk;
|
||||
|
||||
if (rk_pcie->dma_obj) {
|
||||
rk_pcie->dma_obj->start_dma_func = rk_pcie_start_dma_dwc;
|
||||
rk_pcie->dma_obj->config_dma_func = rk_pcie_config_dma_dwc;
|
||||
}
|
||||
|
||||
if (rk_pcie->is_rk1808) {
|
||||
/* hold link reset grant after link-up */
|
||||
ret = rk_pcie_reset_grant_ctrl(rk_pcie, false);
|
||||
|
|
|
|||
|
|
@ -1276,8 +1276,10 @@ static int rockchip_pcie_probe(struct platform_device *pdev)
|
|||
goto err_probe_dma;
|
||||
}
|
||||
|
||||
rockchip->dma_obj->start_dma_func = rk_pcie_start_dma_rk3399;
|
||||
rockchip->dma_obj->config_dma_func = rk_pcie_config_dma_rk3399;
|
||||
if (rockchip->dma_obj) {
|
||||
rockchip->dma_obj->start_dma_func = rk_pcie_start_dma_rk3399;
|
||||
rockchip->dma_obj->config_dma_func = rk_pcie_config_dma_rk3399;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue