drivers: cpuidle: Remove cpuidle-arm64 duplicate error messages
[firefly-linux-kernel-4.4.55.git] / drivers / cpuidle / cpuidle-arm64.c
index 50997ea942fce58975db9f7d933183671f6e740f..1b10f92ecd5a1cd45e1a1ec3e5212a9c0c48fbc9 100644 (file)
@@ -104,11 +104,8 @@ static int __init arm64_idle_init(void)
         * reason to initialize the idle driver if only wfi is supported.
         */
        ret = dt_init_idle_driver(drv, arm64_idle_state_match, 1);
-       if (ret <= 0) {
-               if (ret)
-                       pr_err("failed to initialize idle states\n");
+       if (ret <= 0)
                return ret ? : -ENODEV;
-       }
 
        /*
         * Call arch CPU operations in order to initialize
@@ -122,12 +119,6 @@ static int __init arm64_idle_init(void)
                }
        }
 
-       ret = cpuidle_register(drv, NULL);
-       if (ret) {
-               pr_err("failed to register cpuidle driver\n");
-               return ret;
-       }
-
-       return 0;
+       return cpuidle_register(drv, NULL);
 }
 device_initcall(arm64_idle_init);