Skip to contentSkip to conversation

acpi: sleep: fixed a brace coding style issue

PATCH In review Bruno Bigras 2 participants 2 messages Mar 10, 2010 – Mar 31, 2010 ACPI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 acpi: sleep: fixed a brace coding style issue

Fix a coding style issue.

---
 drivers/acpi/sleep.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/sleep.c +2 -2
index 3bde594..fc8343f 100644
@@ -62,9 +62,9 @@ static int acpi_sleep_prepare(u32 acpi_state)
 #ifdef CONFIG_ACPI_SLEEP
 	/* do we have a wakeup address for S2 and S3? */
 	if (acpi_state == ACPI_STATE_S3) {
-		if (!acpi_wakeup_address) {
+		if (!acpi_wakeup_address)
 			return -EFAULT;
-		}
+
 		acpi_set_firmware_waking_vector(
 				(acpi_physical_address)acpi_wakeup_address);
 
Signature · 1 line
1.7.0.2
#1 lore raw
Quoted 3 lines · Bruno Bigras

Fix a coding style issue.

While I'm not fan of {}s, this is really excessive.

...especially in a code that uses u32 to pass enums, and opencodes typecasts.

Pavel

Quoted 20 lines
---
 drivers/acpi/sleep.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/sleep.c +2 -2
index 3bde594..fc8343f 100644
@@ -62,9 +62,9 @@ static int acpi_sleep_prepare(u32 acpi_state)
 #ifdef CONFIG_ACPI_SLEEP
 	/* do we have a wakeup address for S2 and S3? */
 	if (acpi_state == ACPI_STATE_S3) {
-		if (!acpi_wakeup_address) {
+		if (!acpi_wakeup_address)
 			return -EFAULT;
-		}
+
 		acpi_set_firmware_waking_vector(
 				(acpi_physical_address)acpi_wakeup_address);
 
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html