From 7f1ba7ace9cfac51f6ff8d18d6b1716c5fbb9b95 Mon Sep 17 00:00:00 2001 From: Patrick Mochel Date: Mon, 18 Aug 2003 23:18:27 -0700 Subject: [PATCH] [acpi] Update comments, copyright, and license in drivers/acpi/sleep/main.c --- drivers/acpi/sleep/main.c | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/drivers/acpi/sleep/main.c b/drivers/acpi/sleep/main.c index 712413a7dc5a9..92c6840f6c232 100644 --- a/drivers/acpi/sleep/main.c +++ b/drivers/acpi/sleep/main.c @@ -1,11 +1,11 @@ /* * sleep.c - ACPI sleep support. - * - * Copyright (c) 2000-2003 Patrick Mochel * - * Portions are - * Copyright (C) 2001, 2002 Andy Grover - * Copyright (C) 2001, 2002 Paul Diefenbaugh + * Copyright (c) 2000-2003 Patrick Mochel + * Copyright (c) 2003 Open Source Development Lab + * + * This file is released under the GPLv2. + * */ #include @@ -32,6 +32,9 @@ static u32 acpi_suspend_states[] = { * acpi_pm_prepare - Do preliminary suspend work. * @state: suspend state we're entering. * + * Make sure we support the state. If we do, and we need it, set the + * firmware waking vector and do arch-specific nastiness to get the + * wakeup code to the waking vector. */ static int acpi_pm_prepare(u32 state) @@ -69,6 +72,15 @@ static int acpi_pm_prepare(u32 state) } +/** + * acpi_pm_enter - Actually enter a sleep state. + * @state: State we're entering. + * + * Flush caches and go to sleep. For STR or STD, we have to call + * arch-specific assembly, which in turn call acpi_enter_sleep_state(). + * It's unfortunate, but it works. Please fix if you're feeling frisky. + */ + static int acpi_pm_enter(u32 state) { acpi_status status = AE_OK; @@ -99,6 +111,15 @@ static int acpi_pm_enter(u32 state) return ACPI_SUCCESS(status) ? 0 : -EFAULT; } + +/** + * acpi_pm_finish - Finish up suspend sequence. + * @state: State we're coming out of. + * + * This is called after we wake back up (or if entering the sleep state + * failed). + */ + static int acpi_pm_finish(u32 state) { acpi_leave_sleep_state(state); -- 2.53.0