ARM: tegra: enterprise: Use machine_is_tegra_enterprise()
Dan Willemsen [Tue, 14 Feb 2012 00:53:43 +0000 (16:53 -0800)]
We don't need a static bool here, there's already a function that does
this.

Change-Id: Icacf9dc2fccf2fc780cd7d37121f3eeedbe7fb40
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
Reviewed-on: http://git-master/r/83623
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>

arch/arm/mach-tegra/board-enterprise-power.c

index 43bfe20..69b24cc 100644 (file)
@@ -33,6 +33,8 @@
 #include <linux/regulator/driver.h>
 #include <linux/regulator/gpio-regulator.h>
 
+#include <asm/mach-types.h>
+
 #include <mach/edp.h>
 #include <mach/iomap.h>
 #include <mach/irqs.h>
@@ -51,8 +53,6 @@
 #define PMC_DPD_PADS_ORIDE             0x01c
 #define PMC_DPD_PADS_ORIDE_BLINK       (1 << 20)
 
-static bool is_enterprise_machine = false;
-
 /************************ TPS80031 based regulator ****************/
 static struct regulator_consumer_supply tps80031_vio_supply[] = {
        REGULATOR_SUPPLY("vio_1v8", NULL),
@@ -562,7 +562,7 @@ static int __init enterprise_regulators_fixed_gpio_init(void)
 {
        int ret;
 
-       if (!is_enterprise_machine)
+       if (!machine_is_tegra_enterprise())
                return 0;
 
        ret = enterprise_fixed_regulator_init();
@@ -602,8 +602,6 @@ int __init enterprise_regulator_init(void)
        }
 
        i2c_register_board_info(4, enterprise_regulators, 1);
-       is_enterprise_machine = true;
-
        return 0;
 }