avr32: boards: setup: use IS_ERR() instead of NULL check
authorVasiliy Kulikov <segoon@openwall.com>
Fri, 26 Nov 2010 17:06:12 +0000 (20:06 +0300)
committerHans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Thu, 13 Jan 2011 19:40:53 +0000 (20:40 +0100)
clk_get() returns ERR_PTR() on error, not NULL.

Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
Acked-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
arch/avr32/boards/atngw100/setup.c
arch/avr32/boards/atstk1000/atstk1002.c
arch/avr32/boards/favr-32/setup.c
arch/avr32/boards/hammerhead/setup.c
arch/avr32/boards/merisc/setup.c
arch/avr32/boards/mimc200/setup.c

index 8c6a2440e3458b00e756899743f09465c2d06a78..659d119ce7129e03bc9b3f819f3a8595a2b8b3a6 100644 (file)
@@ -188,7 +188,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
         */
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);
index 2adc261c9e3d0e22076051d43c968abc3f2dcee5..6ce30fb2ec94924464a313aece641f392d6deb64 100644 (file)
@@ -203,7 +203,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
         */
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);
index 75f19f47fb2fb92a8fea40b10ddd303d0f837ca8..86fab77a5a00f993b8e9f82621b0cda03bdc74a2 100644 (file)
@@ -206,7 +206,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
         */
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);
index dd009875a4059d94acf08f6f28e41b3cb67030b6..da14fbdd4e8e0062a87464a8c8d9d43954f63730 100644 (file)
@@ -150,7 +150,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
 
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);
index 623b077594fc65238ae04f26eb1633816a666f96..e61bc948f959861047449fcce267422b0fe84c78 100644 (file)
@@ -134,7 +134,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
 
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);
index 523d8e183bef79a5b30ad3660ea8efd5909e7fb9..c4da5cba2dbfa718cd1a3ea34afd3a0c50257c01 100644 (file)
@@ -162,7 +162,7 @@ static void __init set_hw_addr(struct platform_device *pdev)
         */
        regs = (void __iomem __force *)res->start;
        pclk = clk_get(&pdev->dev, "pclk");
-       if (!pclk)
+       if (IS_ERR(pclk))
                return;
 
        clk_enable(pclk);