PCI: rockchip: add new dev variable to indent the log
authorShawn Lin <shawn.lin@rock-chips.com>
Fri, 10 Mar 2017 03:02:15 +0000 (11:02 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Thu, 16 Mar 2017 03:24:53 +0000 (11:24 +0800)
Change-Id: Idc3bf972c7ab47187b115fb1d2efe7847ee82796
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
drivers/pci/host/pcie-rockchip.c

index c94f51e..50c0c36 100644 (file)
@@ -1148,6 +1148,7 @@ static int rockchip_pcie_prog_ib_atu(struct rockchip_pcie *rockchip,
 
 static int rockchip_cfg_atu(struct rockchip_pcie *rockchip)
 {
+       struct device *dev = rockchip->dev;
        int offset;
        int err;
        int reg_no;
@@ -1160,15 +1161,14 @@ static int rockchip_cfg_atu(struct rockchip_pcie *rockchip)
                                                (reg_no << 20),
                                                0);
                if (err) {
-                       dev_err(rockchip->dev,
-                                       "program RC mem outbound ATU failed\n");
+                       dev_err(dev, "program RC mem outbound ATU failed\n");
                        return err;
                }
        }
 
        err = rockchip_pcie_prog_ib_atu(rockchip, 2, 32 - 1, 0x0, 0);
        if (err) {
-               dev_err(rockchip->dev, "program RC mem inbound ATU failed\n");
+               dev_err(dev, "program RC mem inbound ATU failed\n");
                return err;
        }
 
@@ -1182,8 +1182,7 @@ static int rockchip_cfg_atu(struct rockchip_pcie *rockchip)
                                                (reg_no << 20),
                                                0);
                if (err) {
-                       dev_err(rockchip->dev,
-                                       "program RC io outbound ATU failed\n");
+                       dev_err(dev, "program RC io outbound ATU failed\n");
                        return err;
                }
        }