diff options
author | David Woodhouse <dwmw2@shinybook.infradead.org> | 2005-07-02 08:39:09 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@shinybook.infradead.org> | 2005-07-02 08:39:09 -0400 |
commit | d2f6409584e2c62ffad81690562330ff3bf4a458 (patch) | |
tree | 3bdfb97d0b51be2f7f414f2107e97603c1206abb /include/net/sctp/sctp.h | |
parent | e1b09eba2686eca94a3a188042b518df6044a3c1 (diff) | |
parent | 4a89a04f1ee21a7c1f4413f1ad7dcfac50ff9b63 (diff) |
Merge with master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Diffstat (limited to 'include/net/sctp/sctp.h')
-rw-r--r-- | include/net/sctp/sctp.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h index 960abfa48d68..ef2738159ab3 100644 --- a/include/net/sctp/sctp.h +++ b/include/net/sctp/sctp.h | |||
@@ -223,6 +223,22 @@ DECLARE_SNMP_STAT(struct sctp_mib, sctp_statistics); | |||
223 | extern int sctp_debug_flag; | 223 | extern int sctp_debug_flag; |
224 | #define SCTP_DEBUG_PRINTK(whatever...) \ | 224 | #define SCTP_DEBUG_PRINTK(whatever...) \ |
225 | ((void) (sctp_debug_flag && printk(KERN_DEBUG whatever))) | 225 | ((void) (sctp_debug_flag && printk(KERN_DEBUG whatever))) |
226 | #define SCTP_DEBUG_PRINTK_IPADDR(lead, trail, leadparm, saddr, otherparms...) \ | ||
227 | if (sctp_debug_flag) { \ | ||
228 | if (saddr->sa.sa_family == AF_INET6) { \ | ||
229 | printk(KERN_DEBUG \ | ||
230 | lead "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x" trail, \ | ||
231 | leadparm, \ | ||
232 | NIP6(saddr->v6.sin6_addr), \ | ||
233 | otherparms); \ | ||
234 | } else { \ | ||
235 | printk(KERN_DEBUG \ | ||
236 | lead "%u.%u.%u.%u" trail, \ | ||
237 | leadparm, \ | ||
238 | NIPQUAD(saddr->v4.sin_addr.s_addr), \ | ||
239 | otherparms); \ | ||
240 | } \ | ||
241 | } | ||
226 | #define SCTP_ENABLE_DEBUG { sctp_debug_flag = 1; } | 242 | #define SCTP_ENABLE_DEBUG { sctp_debug_flag = 1; } |
227 | #define SCTP_DISABLE_DEBUG { sctp_debug_flag = 0; } | 243 | #define SCTP_DISABLE_DEBUG { sctp_debug_flag = 0; } |
228 | 244 | ||
@@ -236,6 +252,7 @@ extern int sctp_debug_flag; | |||
236 | #else /* SCTP_DEBUG */ | 252 | #else /* SCTP_DEBUG */ |
237 | 253 | ||
238 | #define SCTP_DEBUG_PRINTK(whatever...) | 254 | #define SCTP_DEBUG_PRINTK(whatever...) |
255 | #define SCTP_DEBUG_PRINTK_IPADDR(whatever...) | ||
239 | #define SCTP_ENABLE_DEBUG | 256 | #define SCTP_ENABLE_DEBUG |
240 | #define SCTP_DISABLE_DEBUG | 257 | #define SCTP_DISABLE_DEBUG |
241 | #define SCTP_ASSERT(expr, str, func) | 258 | #define SCTP_ASSERT(expr, str, func) |