linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ACPI: Simplify conditional that has the same effect no matter what.
@ 2012-10-22 21:40 Robert P. J. Day
  2012-10-22 22:30 ` Rafael J. Wysocki
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Robert P. J. Day @ 2012-10-22 21:40 UTC (permalink / raw)
  To: linux-acpi; +Cc: lenb, rjw


Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>

---

  not sure if there's something weirdly subtle happening here, but
this looks like a straightforward simplification.

diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c
index 9eaf708..e76a7f5 100644
--- a/drivers/acpi/osl.c
+++ b/drivers/acpi/osl.c
@@ -949,12 +949,7 @@ static acpi_status __acpi_os_execute(acpi_execute_type type,
 		(type == OSL_NOTIFY_HANDLER ? kacpi_notify_wq : kacpid_wq);
 	dpc->wait = hp ? 1 : 0;

-	if (queue == kacpi_hotplug_wq)
-		INIT_WORK(&dpc->work, acpi_os_execute_deferred);
-	else if (queue == kacpi_notify_wq)
-		INIT_WORK(&dpc->work, acpi_os_execute_deferred);
-	else
-		INIT_WORK(&dpc->work, acpi_os_execute_deferred);
+	INIT_WORK(&dpc->work, acpi_os_execute_deferred);

 	/*
 	 * On some machines, a software-initiated SMI causes corruption unless


-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-10-24 22:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-22 21:40 [PATCH] ACPI: Simplify conditional that has the same effect no matter what Robert P. J. Day
2012-10-22 22:30 ` Rafael J. Wysocki
2012-10-23  2:27 ` Matthew Garrett
2012-10-24 21:23   ` Rafael J. Wysocki
2012-10-24 22:19 ` Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).