mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 04:10:18 +09:00
spi: rockchip-slave: Get rid of the sram driver dependency
Use devm_ioremap to get rid of the sram driver dependency. Change-Id: I908c4f6aee1d545d80b5821375d0962c2640c0e2 Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
This commit is contained in:
@@ -813,9 +813,9 @@ static int rockchip_spi_slave_probe(struct platform_device *pdev)
|
||||
|
||||
rs->max_transfer_size = resource_size(&sram_res);
|
||||
rs->dma_phys = sram_res.start;
|
||||
rs->dma_buf = devm_ioremap_resource(&pdev->dev, &sram_res);
|
||||
if (IS_ERR(rs->dma_buf)) {
|
||||
ret = PTR_ERR(rs->dma_buf);
|
||||
rs->dma_buf = devm_ioremap(&pdev->dev, sram_res.start, resource_size(&sram_res));
|
||||
if (!rs->dma_buf) {
|
||||
ret = -ENOMEM;
|
||||
goto err_put_ctlr;
|
||||
}
|
||||
dev_err(&pdev->dev, "set sram_buf\n");
|
||||
|
||||
Reference in New Issue
Block a user