Revert "ARM: tegra: powergate: Don't error out if new state == old state"
Dan Willemsen [Tue, 20 Aug 2013 03:48:28 +0000 (20:48 -0700)]
This reverts commit eebd1fda2342014a50ed3fd132e5dc6e8b5251e8.

Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>

arch/arm/mach-tegra/powergate.c

index af9067e..c472bed 100644 (file)
@@ -76,7 +76,7 @@ static int tegra_powergate_set(int id, bool new_state)
 
        if (status == new_state) {
                spin_unlock_irqrestore(&tegra_powergate_lock, flags);
-               return 0;
+               return -EINVAL;
        }
 
        pmc_write(PWRGATE_TOGGLE_START | id, PWRGATE_TOGGLE);