arm: tegra: Console suspend for all boards
[linux-2.6.git] / arch / arm / mach-tegra / board-enterprise-power.c
index 9f1f959..4da5d1d 100644 (file)
@@ -400,6 +400,18 @@ int __init enterprise_regulator_init(void)
        return 0;
 }
 
+static void enterprise_board_suspend(int lp_state, enum suspend_stage stg)
+{
+       if ((lp_state == TEGRA_SUSPEND_LP1) && (stg == TEGRA_SUSPEND_BEFORE_CPU))
+               tegra_console_uart_suspend();
+}
+
+static void enterprise_board_resume(int lp_state, enum resume_stage stg)
+{
+       if ((lp_state == TEGRA_SUSPEND_LP1) && (stg == TEGRA_RESUME_AFTER_CPU))
+               tegra_console_uart_resume();
+}
+
 static struct tegra_suspend_platform_data enterprise_suspend_data = {
        .cpu_timer      = 2000,
        .cpu_off_timer  = 200,
@@ -408,6 +420,8 @@ static struct tegra_suspend_platform_data enterprise_suspend_data = {
        .core_off_timer = 0,
        .corereq_high   = true,
        .sysclkreq_high = true,
+       .board_suspend = enterprise_board_suspend,
+       .board_resume = enterprise_board_resume,
 };
 
 int __init enterprise_suspend_init(void)