public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: UV cleanup
@ 2009-01-29 19:39 Cliff Wickman
  2009-01-29 20:35 ` Ingo Molnar
  0 siblings, 1 reply; 3+ messages in thread
From: Cliff Wickman @ 2009-01-29 19:39 UTC (permalink / raw)
  To: linux-kernel; +Cc: mingo, tj



From: Cliff Wickman <cpw@sgi.com>

This patch tweaks a couple things:

- uv_flush_tlb_others()
  the WARN_ON(!in_atomic()); fails if CONFIG_PREEMPT is not enabled

  The #ifdef may not be the right fix. The fix is probably in the
  in_atomic macro, but I'm not sure what in_atomic() should return
  if CONFIG_PREEMPT is turned off.  I tested making it return 1 in that
  case, but that yielded tons of warnings.

  The simpler fix for tlb_uv.c would be to just drop the WARN_ON.

- uv_flush_send_and_wait() should return a pointer if the broadcast
  remote tlb shootdown requests fail. That causes the conventional IPI
  method of shootdown to be used.

Diffed against 2.6.29-rc2
  (Ingo's tree)

Signed-off-by: Cliff Wickman <cpw@sgi.com>
---
 arch/x86/kernel/tlb_uv.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Index: linux/arch/x86/kernel/tlb_uv.c
===================================================================
--- linux.orig/arch/x86/kernel/tlb_uv.c
+++ linux/arch/x86/kernel/tlb_uv.c
@@ -259,7 +259,7 @@ const struct cpumask *uv_flush_send_and_
 		 * the cpu's, all of which are still in the mask.
 		 */
 		__get_cpu_var(ptcstats).ptc_i++;
-		return 0;
+		return flush_mask;
 	}
 
 	/*
@@ -316,7 +316,9 @@ const struct cpumask *uv_flush_tlb_other
 	int locals = 0;
 	struct bau_desc *bau_desc;
 
+#ifdef CONFIG_PREEMPT
 	WARN_ON(!in_atomic());
+#endif
 
 	cpumask_andnot(flush_mask, cpumask, cpumask_of(cpu));
 

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

end of thread, other threads:[~2009-01-29 21:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-29 19:39 [PATCH] x86: UV cleanup Cliff Wickman
2009-01-29 20:35 ` Ingo Molnar
2009-01-29 21:30   ` Cliff Wickman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox