All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Chubb <peterc@gelato.unsw.edu.au>
To: linux-ia64@vger.kernel.org
Subject: unwind.c fix for spinlock-debug compilation
Date: Tue, 09 Sep 2003 03:48:23 +0000	[thread overview]
Message-ID: <marc-linux-ia64-106307953919670@msgid-missing> (raw)


If you try to compile 2.6.0-test[45] with spinlock debugging on, then
unwind.c won't compile, because it uses a #define magic that hides
the variable in the spinlock debugging code (also called magic)

Suggested patch appended.

=== arch/ia64/kernel/unwind.c 1.32 vs edited ==--- 1.32/arch/ia64/kernel/unwind.c	Sat Jul 26 11:42:20 2003
+++ edited/arch/ia64/kernel/unwind.c	Tue Sep  9 13:38:35 2003
@@ -1171,9 +1171,10 @@
 static inline unw_hash_index_t
 hash (unsigned long ip)
 {
-#	define magic	0x9e3779b97f4a7c16	/* based on (sqrt(5)/2-1)*2^64 */
+#	define hashmagic	0x9e3779b97f4a7c16	/* based on (sqrt(5)/2-1)*2^64 */
 
-	return (ip >> 4)*magic >> (64 - UNW_LOG_HASH_SIZE);
+	return (ip >> 4)*hashmagic >> (64 - UNW_LOG_HASH_SIZE);
+#undef hashmagic
 }
 
 static inline long


                 reply	other threads:[~2003-09-09  3:48 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=marc-linux-ia64-106307953919670@msgid-missing \
    --to=peterc@gelato.unsw.edu.au \
    --cc=linux-ia64@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.