netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] xfrm6: move define/ifdef check order
@ 2006-07-02 21:36 Randy.Dunlap
  2006-07-03 13:39 ` Nicolas DICHTEL
  2006-07-04  2:46 ` David Miller
  0 siblings, 2 replies; 5+ messages in thread
From: Randy.Dunlap @ 2006-07-02 21:36 UTC (permalink / raw)
  To: netdev; +Cc: davem

From: Randy Dunlap <rdunlap@xenotime.net>

The first check for #ifdef XFRM6_TUNNEL_SPI_MAGIC needs to come after
the optional #define of it, otherwise the variable won't be there
for the rest of the code to use.

Shouldn't that CONFIG_IPV6_XFRM6_TUNNEL_DEBUG be part of Kconfig
or have its name changed?

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
---
 net/ipv6/xfrm6_tunnel.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

--- linux-2617-g20.orig/net/ipv6/xfrm6_tunnel.c
+++ linux-2617-g20/net/ipv6/xfrm6_tunnel.c
@@ -52,6 +52,10 @@
 # define X6TPRINTK3	X6TNOPRINTK
 #endif
 
+#ifdef CONFIG_IPV6_XFRM6_TUNNEL_DEBUG
+# define XFRM6_TUNNEL_SPI_MAGIC 0xdeadbeef
+#endif
+
 /*
  * xfrm_tunnel_spi things are for allocating unique id ("spi") 
  * per xfrm_address_t.
@@ -67,10 +71,6 @@ struct xfrm6_tunnel_spi {
 #endif
 };
 
-#ifdef CONFIG_IPV6_XFRM6_TUNNEL_DEBUG
-# define XFRM6_TUNNEL_SPI_MAGIC 0xdeadbeef
-#endif
-
 static DEFINE_RWLOCK(xfrm6_tunnel_spi_lock);
 
 static u32 xfrm6_tunnel_spi;


---

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

end of thread, other threads:[~2006-07-24 20:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-02 21:36 [PATCH] xfrm6: move define/ifdef check order Randy.Dunlap
2006-07-03 13:39 ` Nicolas DICHTEL
2006-07-04  2:46 ` David Miller
2006-07-04  4:42   ` xfrm6: move define/ifdef check order and add a Kconfig option Randy.Dunlap
2006-07-24 20:49     ` David Miller

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