Skip to contentSkip to conversation

IPMI: Change barrier to cpu_relax in poweroff code

PATCH In review Corey Minyard 1 participant 1 message Feb 14, 2008 IPMI

lore
Share & tools
lore
#0 lore raw

PATCH 1/4 IPMI: Change barrier to cpu_relax in poweroff code

From: Corey Minyard <[email protected]>

Change a barrier to cpu_relax(), which is more appropriate for a polling loop.

---

drivers/char/ipmi/ipmi_poweroff.c +1 -1
Index: linux-2.6.24/drivers/char/ipmi/ipmi_poweroff.c
===================================================================
@@ -175,7 +175,7 @@ static int ipmi_request_in_rc_mode(ipmi_
 	 */
 	while (atomic_read(&dummy_count) > 0) {
 		ipmi_poll_interface(user);
-		barrier();
+		cpu_relax();
 	}
 
 	return halt_recv_msg.msg.data[0];