Enable ftrace data in kernel/power/suspend.c
authorMichael Ikey Doherty <michael.i.doherty@intel.com>
Tue, 20 Aug 2013 12:41:14 +0000 (13:41 +0100)
committerWilliam Douglas <william.douglas@intel.com>
Tue, 1 Oct 2013 19:10:26 +0000 (12:10 -0700)
Initial patch at https://github.com/01org/suspendresume/
Bug-Tizen: TZPC-4362

kernel/power/suspend.c

index ece0422..62ee437 100644 (file)
@@ -210,6 +210,7 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
                goto Platform_wake;
        }
 
+       ftrace_stop();
        error = disable_nonboot_cpus();
        if (error || suspend_test(TEST_CPUS))
                goto Enable_cpus;
@@ -232,6 +233,7 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
 
  Enable_cpus:
        enable_nonboot_cpus();
+       ftrace_start();
 
  Platform_wake:
        if (need_suspend_ops(state) && suspend_ops->wake)
@@ -265,7 +267,6 @@ int suspend_devices_and_enter(suspend_state_t state)
                        goto Close;
        }
        suspend_console();
-       ftrace_stop();
        suspend_test_start();
        error = dpm_suspend_start(PMSG_SUSPEND);
        if (error) {
@@ -285,7 +286,6 @@ int suspend_devices_and_enter(suspend_state_t state)
        suspend_test_start();
        dpm_resume_end(PMSG_RESUME);
        suspend_test_finish("resume devices");
-       ftrace_start();
        resume_console();
  Close:
        if (need_suspend_ops(state) && suspend_ops->end)