linux-parisc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] More unreachable() conversions.
@ 2009-12-10 17:25 David Daney
  2009-12-10 17:28 ` [PATCH 2/5] parisc: Convert BUG() to use unreachable() David Daney
  0 siblings, 1 reply; 3+ messages in thread
From: David Daney @ 2009-12-10 17:25 UTC (permalink / raw)
  To: Andrew Morton, David Howells, Koichi Yasutake, linux-am33-list,
	Kyle McMartin
  Cc: Linux Kernel Mailing List, linux-arch, Linus Torvalds

Back in commit 38938c879eb0c39edf85d5164aa0cffe2874304c the new macro
unreachable() was added.  We can use it in BUG instead of a variety of
ad hoc endless loops.

This patch set consists of the patches from the original set that were
never Acked-by anyone.  Although they are completely untested, they
seem plausible.

I don't plan on pushing these things out any more, so if you
like them please merge them via your architecture trees.

I will reply with the 5 patches.

David Daney (5):
   mn10300: Convert BUG() to use unreachable()
   parisc: Convert BUG() to use unreachable()
   powerpc: Convert BUG() to use unreachable()
   alpha: Convert BUG() to use unreachable()
   blackfin: Convert BUG() to use unreachable()

  arch/alpha/include/asm/bug.h    |    3 ++-
  arch/blackfin/include/asm/bug.h |    2 +-
  arch/mn10300/include/asm/bug.h  |    3 ++-
  arch/parisc/include/asm/bug.h   |    4 ++--
  arch/powerpc/include/asm/bug.h  |    2 +-
  5 files changed, 8 insertions(+), 6 deletions(-)


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

* [PATCH 2/5] parisc: Convert BUG() to use unreachable()
  2009-12-10 17:25 [PATCH 0/5] More unreachable() conversions David Daney
@ 2009-12-10 17:28 ` David Daney
  2009-12-10 21:54   ` Kyle McMartin
  0 siblings, 1 reply; 3+ messages in thread
From: David Daney @ 2009-12-10 17:28 UTC (permalink / raw)
  To: linux-kernel, linux-arch
  Cc: akpm, torvalds, David Daney, Kyle McMartin, Helge Deller,
	linux-parisc

Use the new unreachable() macro instead of for(;;);

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
CC: Kyle McMartin <kyle@mcmartin.ca>
CC: Helge Deller <deller@gmx.de>
CC: linux-parisc@vger.kernel.org
---
 arch/parisc/include/asm/bug.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/parisc/include/asm/bug.h b/arch/parisc/include/asm/bug.h
index 8cfc553..75e46c5 100644
--- a/arch/parisc/include/asm/bug.h
+++ b/arch/parisc/include/asm/bug.h
@@ -32,14 +32,14 @@
 			     "\t.popsection"				\
 			     : : "i" (__FILE__), "i" (__LINE__),	\
 			     "i" (0), "i" (sizeof(struct bug_entry)) ); \
-		for(;;) ;						\
+		unreachable();						\
 	} while(0)
 
 #else
 #define BUG()								\
 	do {								\
 		asm volatile(PARISC_BUG_BREAK_ASM : : );		\
-		for(;;) ;						\
+		unreachable();						\
 	} while(0)
 #endif
 
-- 
1.6.2.5


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

* Re: [PATCH 2/5] parisc: Convert BUG() to use unreachable()
  2009-12-10 17:28 ` [PATCH 2/5] parisc: Convert BUG() to use unreachable() David Daney
@ 2009-12-10 21:54   ` Kyle McMartin
  0 siblings, 0 replies; 3+ messages in thread
From: Kyle McMartin @ 2009-12-10 21:54 UTC (permalink / raw)
  To: David Daney
  Cc: linux-kernel, linux-arch, akpm, torvalds, Kyle McMartin,
	Helge Deller, linux-parisc

On Thu, Dec 10, 2009 at 09:28:18AM -0800, David Daney wrote:
> Use the new unreachable() macro instead of for(;;);
> 
> Signed-off-by: David Daney <ddaney@caviumnetworks.com>
> CC: Kyle McMartin <kyle@mcmartin.ca>
> CC: Helge Deller <deller@gmx.de>
> CC: linux-parisc@vger.kernel.org
> ---

Thanks David, I'll bash this into my tree now that the macro is
upstream.

regards, Kyle

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

end of thread, other threads:[~2009-12-10 21:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-10 17:25 [PATCH 0/5] More unreachable() conversions David Daney
2009-12-10 17:28 ` [PATCH 2/5] parisc: Convert BUG() to use unreachable() David Daney
2009-12-10 21:54   ` Kyle McMartin

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).