aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/linux/kernel.h2
-rw-r--r--include/net/netfilter/nf_conntrack_tuple.h2
-rw-r--r--include/net/sctp/sctp.h4
-rw-r--r--net/ipv6/addrconf.c2
-rw-r--r--net/ipv6/ah6.c3
-rw-r--r--net/ipv6/anycast.c4
-rw-r--r--net/ipv6/esp6.c3
-rw-r--r--net/ipv6/icmp.c2
-rw-r--r--net/ipv6/ip6_flowlabel.c8
-rw-r--r--net/ipv6/ipcomp6.c3
-rw-r--r--net/ipv6/mcast.c9
-rw-r--r--net/ipv6/ndisc.c2
-rw-r--r--net/ipv6/netfilter/ip6t_LOG.c5
-rw-r--r--net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c2
-rw-r--r--net/ipv6/xfrm6_tunnel.c8
-rw-r--r--net/netfilter/nf_conntrack_ftp.c4
-rw-r--r--net/sctp/ipv6.c24
-rw-r--r--net/sctp/sm_statefuns.c4
-rw-r--r--security/selinux/avc.c5
19 files changed, 39 insertions, 57 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index e6ee2d95da7a..323924edb26a 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -216,6 +216,7 @@ extern void dump_stack(void);
216 ((unsigned char *)&addr)[1], \ 216 ((unsigned char *)&addr)[1], \
217 ((unsigned char *)&addr)[2], \ 217 ((unsigned char *)&addr)[2], \
218 ((unsigned char *)&addr)[3] 218 ((unsigned char *)&addr)[3]
219#define NIPQUAD_FMT "%u.%u.%u.%u"
219 220
220#define NIP6(addr) \ 221#define NIP6(addr) \
221 ntohs((addr).s6_addr16[0]), \ 222 ntohs((addr).s6_addr16[0]), \
@@ -226,6 +227,7 @@ extern void dump_stack(void);
226 ntohs((addr).s6_addr16[5]), \ 227 ntohs((addr).s6_addr16[5]), \
227 ntohs((addr).s6_addr16[6]), \ 228 ntohs((addr).s6_addr16[6]), \
228 ntohs((addr).s6_addr16[7]) 229 ntohs((addr).s6_addr16[7])
230#define NIP6_FMT "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x"
229 231
230#if defined(__LITTLE_ENDIAN) 232#if defined(__LITTLE_ENDIAN)
231#define HIPQUAD(addr) \ 233#define HIPQUAD(addr) \
diff --git a/include/net/netfilter/nf_conntrack_tuple.h b/include/net/netfilter/nf_conntrack_tuple.h
index 14ce790e5c65..530ef1f75283 100644
--- a/include/net/netfilter/nf_conntrack_tuple.h
+++ b/include/net/netfilter/nf_conntrack_tuple.h
@@ -111,7 +111,7 @@ struct nf_conntrack_tuple
111#ifdef __KERNEL__ 111#ifdef __KERNEL__
112 112
113#define NF_CT_DUMP_TUPLE(tp) \ 113#define NF_CT_DUMP_TUPLE(tp) \
114DEBUGP("tuple %p: %u %u %04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x %hu -> %04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x %hu\n", \ 114DEBUGP("tuple %p: %u %u " NIP6_FMT " %hu -> " NIP6_FMT " %hu\n", \
115 (tp), (tp)->src.l3num, (tp)->dst.protonum, \ 115 (tp), (tp)->src.l3num, (tp)->dst.protonum, \
116 NIP6(*(struct in6_addr *)(tp)->src.u3.all), ntohs((tp)->src.u.all), \ 116 NIP6(*(struct in6_addr *)(tp)->src.u3.all), ntohs((tp)->src.u.all), \
117 NIP6(*(struct in6_addr *)(tp)->dst.u3.all), ntohs((tp)->dst.u.all)) 117 NIP6(*(struct in6_addr *)(tp)->dst.u3.all), ntohs((tp)->dst.u.all))
diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h
index 8f241216f46b..a553f39f6aee 100644
--- a/include/net/sctp/sctp.h
+++ b/include/net/sctp/sctp.h
@@ -225,13 +225,13 @@ extern int sctp_debug_flag;
225 if (sctp_debug_flag) { \ 225 if (sctp_debug_flag) { \
226 if (saddr->sa.sa_family == AF_INET6) { \ 226 if (saddr->sa.sa_family == AF_INET6) { \
227 printk(KERN_DEBUG \ 227 printk(KERN_DEBUG \
228 lead "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x" trail, \ 228 lead NIP6_FMT trail, \
229 leadparm, \ 229 leadparm, \
230 NIP6(saddr->v6.sin6_addr), \ 230 NIP6(saddr->v6.sin6_addr), \
231 otherparms); \ 231 otherparms); \
232 } else { \ 232 } else { \
233 printk(KERN_DEBUG \ 233 printk(KERN_DEBUG \
234 lead "%u.%u.%u.%u" trail, \ 234 lead NIPQUAD_FMT trail, \
235 leadparm, \ 235 leadparm, \
236 NIPQUAD(saddr->v4.sin_addr.s_addr), \ 236 NIPQUAD(saddr->v4.sin_addr.s_addr), \
237 otherparms); \ 237 otherparms); \
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 7129d4239755..dfb4f145a139 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -2644,7 +2644,7 @@ static int if6_seq_show(struct seq_file *seq, void *v)
2644{ 2644{
2645 struct inet6_ifaddr *ifp = (struct inet6_ifaddr *)v; 2645 struct inet6_ifaddr *ifp = (struct inet6_ifaddr *)v;
2646 seq_printf(seq, 2646 seq_printf(seq,
2647 "%04x%04x%04x%04x%04x%04x%04x%04x %02x %02x %02x %02x %8s\n", 2647 NIP6_FMT " %02x %02x %02x %02x %8s\n",
2648 NIP6(ifp->addr), 2648 NIP6(ifp->addr),
2649 ifp->idev->dev->ifindex, 2649 ifp->idev->dev->ifindex,
2650 ifp->prefix_len, 2650 ifp->prefix_len,
diff --git a/net/ipv6/ah6.c b/net/ipv6/ah6.c
index 13cc7f895583..c7932cb420a5 100644
--- a/net/ipv6/ah6.c
+++ b/net/ipv6/ah6.c
@@ -332,8 +332,7 @@ static void ah6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
332 if (!x) 332 if (!x)
333 return; 333 return;
334 334
335 NETDEBUG(KERN_DEBUG "pmtu discovery on SA AH/%08x/" 335 NETDEBUG(KERN_DEBUG "pmtu discovery on SA AH/%08x/" NIP6_FMT "\n",
336 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
337 ntohl(ah->spi), NIP6(iph->daddr)); 336 ntohl(ah->spi), NIP6(iph->daddr));
338 337
339 xfrm_state_put(x); 338 xfrm_state_put(x);
diff --git a/net/ipv6/anycast.c b/net/ipv6/anycast.c
index 65e73ac0d6d0..72bd08af2dfb 100644
--- a/net/ipv6/anycast.c
+++ b/net/ipv6/anycast.c
@@ -532,9 +532,7 @@ static int ac6_seq_show(struct seq_file *seq, void *v)
532 struct ac6_iter_state *state = ac6_seq_private(seq); 532 struct ac6_iter_state *state = ac6_seq_private(seq);
533 533
534 seq_printf(seq, 534 seq_printf(seq,
535 "%-4d %-15s " 535 "%-4d %-15s " NIP6_FMT " %5d\n",
536 "%04x%04x%04x%04x%04x%04x%04x%04x "
537 "%5d\n",
538 state->dev->ifindex, state->dev->name, 536 state->dev->ifindex, state->dev->name,
539 NIP6(im->aca_addr), 537 NIP6(im->aca_addr),
540 im->aca_users); 538 im->aca_users);
diff --git a/net/ipv6/esp6.c b/net/ipv6/esp6.c
index 6de8ee1a5ad9..7b5b94f13902 100644
--- a/net/ipv6/esp6.c
+++ b/net/ipv6/esp6.c
@@ -266,8 +266,7 @@ static void esp6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
266 x = xfrm_state_lookup((xfrm_address_t *)&iph->daddr, esph->spi, IPPROTO_ESP, AF_INET6); 266 x = xfrm_state_lookup((xfrm_address_t *)&iph->daddr, esph->spi, IPPROTO_ESP, AF_INET6);
267 if (!x) 267 if (!x)
268 return; 268 return;
269 printk(KERN_DEBUG "pmtu discovery on SA ESP/%08x/" 269 printk(KERN_DEBUG "pmtu discovery on SA ESP/%08x/" NIP6_FMT "\n",
270 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
271 ntohl(esph->spi), NIP6(iph->daddr)); 270 ntohl(esph->spi), NIP6(iph->daddr));
272 xfrm_state_put(x); 271 xfrm_state_put(x);
273} 272}
diff --git a/net/ipv6/icmp.c b/net/ipv6/icmp.c
index 53c81fcd20ba..fcf883183cef 100644
--- a/net/ipv6/icmp.c
+++ b/net/ipv6/icmp.c
@@ -607,7 +607,7 @@ static int icmpv6_rcv(struct sk_buff **pskb)
607 skb->csum = ~csum_ipv6_magic(saddr, daddr, skb->len, 607 skb->csum = ~csum_ipv6_magic(saddr, daddr, skb->len,
608 IPPROTO_ICMPV6, 0); 608 IPPROTO_ICMPV6, 0);
609 if (__skb_checksum_complete(skb)) { 609 if (__skb_checksum_complete(skb)) {
610 LIMIT_NETDEBUG(KERN_DEBUG "ICMPv6 checksum failed [%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x > %04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x]\n", 610 LIMIT_NETDEBUG(KERN_DEBUG "ICMPv6 checksum failed [" NIP6_FMT " > " NIP6_FMT "]\n",
611 NIP6(*saddr), NIP6(*daddr)); 611 NIP6(*saddr), NIP6(*daddr));
612 goto discard_it; 612 goto discard_it;
613 } 613 }
diff --git a/net/ipv6/ip6_flowlabel.c b/net/ipv6/ip6_flowlabel.c
index 964ad9d1276d..4183c8dac7f6 100644
--- a/net/ipv6/ip6_flowlabel.c
+++ b/net/ipv6/ip6_flowlabel.c
@@ -629,9 +629,7 @@ static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl)
629{ 629{
630 while(fl) { 630 while(fl) {
631 seq_printf(seq, 631 seq_printf(seq,
632 "%05X %-1d %-6d %-6d %-6ld %-8ld " 632 "%05X %-1d %-6d %-6d %-6ld %-8ld " NIP6_FMT " %-4d\n",
633 "%02x%02x%02x%02x%02x%02x%02x%02x "
634 "%-4d\n",
635 (unsigned)ntohl(fl->label), 633 (unsigned)ntohl(fl->label),
636 fl->share, 634 fl->share,
637 (unsigned)fl->owner, 635 (unsigned)fl->owner,
@@ -647,8 +645,8 @@ static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl)
647static int ip6fl_seq_show(struct seq_file *seq, void *v) 645static int ip6fl_seq_show(struct seq_file *seq, void *v)
648{ 646{
649 if (v == SEQ_START_TOKEN) 647 if (v == SEQ_START_TOKEN)
650 seq_puts(seq, "Label S Owner Users Linger Expires " 648 seq_printf(seq, "%-5s %-1s %-6s %-6s %-6s %-8s %-39s %s\n",
651 "Dst Opt\n"); 649 "Label", "S", "Owner", "Users", "Linger", "Expires", "Dst", "Opt");
652 else 650 else
653 ip6fl_fl_seq_show(seq, v); 651 ip6fl_fl_seq_show(seq, v);
654 return 0; 652 return 0;
diff --git a/net/ipv6/ipcomp6.c b/net/ipv6/ipcomp6.c
index 626dd39685f2..d511a884dad0 100644
--- a/net/ipv6/ipcomp6.c
+++ b/net/ipv6/ipcomp6.c
@@ -212,8 +212,7 @@ static void ipcomp6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
212 if (!x) 212 if (!x)
213 return; 213 return;
214 214
215 printk(KERN_DEBUG "pmtu discovery on SA IPCOMP/%08x/" 215 printk(KERN_DEBUG "pmtu discovery on SA IPCOMP/%08x/" NIP6_FMT "\n",
216 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
217 spi, NIP6(iph->daddr)); 216 spi, NIP6(iph->daddr));
218 xfrm_state_put(x); 217 xfrm_state_put(x);
219} 218}
diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c
index cc3e9f560867..0e03eabfb9da 100644
--- a/net/ipv6/mcast.c
+++ b/net/ipv6/mcast.c
@@ -2373,7 +2373,7 @@ static int igmp6_mc_seq_show(struct seq_file *seq, void *v)
2373 struct igmp6_mc_iter_state *state = igmp6_mc_seq_private(seq); 2373 struct igmp6_mc_iter_state *state = igmp6_mc_seq_private(seq);
2374 2374
2375 seq_printf(seq, 2375 seq_printf(seq,
2376 "%-4d %-15s %04x%04x%04x%04x%04x%04x%04x%04x %5d %08X %ld\n", 2376 "%-4d %-15s " NIP6_FMT " %5d %08X %ld\n",
2377 state->dev->ifindex, state->dev->name, 2377 state->dev->ifindex, state->dev->name,
2378 NIP6(im->mca_addr), 2378 NIP6(im->mca_addr),
2379 im->mca_users, im->mca_flags, 2379 im->mca_users, im->mca_flags,
@@ -2542,15 +2542,12 @@ static int igmp6_mcf_seq_show(struct seq_file *seq, void *v)
2542 if (v == SEQ_START_TOKEN) { 2542 if (v == SEQ_START_TOKEN) {
2543 seq_printf(seq, 2543 seq_printf(seq,
2544 "%3s %6s " 2544 "%3s %6s "
2545 "%32s %32s %6s %6s\n", "Idx", 2545 "%39s %39s %6s %6s\n", "Idx",
2546 "Device", "Multicast Address", 2546 "Device", "Multicast Address",
2547 "Source Address", "INC", "EXC"); 2547 "Source Address", "INC", "EXC");
2548 } else { 2548 } else {
2549 seq_printf(seq, 2549 seq_printf(seq,
2550 "%3d %6.6s " 2550 "%3d %6.6s " NIP6_FMT " " NIP6_FMT " %6lu %6lu\n",
2551 "%04x%04x%04x%04x%04x%04x%04x%04x "
2552 "%04x%04x%04x%04x%04x%04x%04x%04x "
2553 "%6lu %6lu\n",
2554 state->dev->ifindex, state->dev->name, 2551 state->dev->ifindex, state->dev->name,
2555 NIP6(state->im->mca_addr), 2552 NIP6(state->im->mca_addr),
2556 NIP6(psf->sf_addr), 2553 NIP6(psf->sf_addr),
diff --git a/net/ipv6/ndisc.c b/net/ipv6/ndisc.c
index 305d9ee6d7db..cb8856b1d951 100644
--- a/net/ipv6/ndisc.c
+++ b/net/ipv6/ndisc.c
@@ -692,7 +692,7 @@ static void ndisc_solicit(struct neighbour *neigh, struct sk_buff *skb)
692 if (!(neigh->nud_state & NUD_VALID)) { 692 if (!(neigh->nud_state & NUD_VALID)) {
693 ND_PRINTK1(KERN_DEBUG 693 ND_PRINTK1(KERN_DEBUG
694 "%s(): trying to ucast probe in NUD_INVALID: " 694 "%s(): trying to ucast probe in NUD_INVALID: "
695 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n", 695 NIP6_FMT "\n",
696 __FUNCTION__, 696 __FUNCTION__,
697 NIP6(*target)); 697 NIP6(*target));
698 } 698 }
diff --git a/net/ipv6/netfilter/ip6t_LOG.c b/net/ipv6/netfilter/ip6t_LOG.c
index fc19d8a4ca68..77c725832dec 100644
--- a/net/ipv6/netfilter/ip6t_LOG.c
+++ b/net/ipv6/netfilter/ip6t_LOG.c
@@ -63,9 +63,8 @@ static void dump_packet(const struct nf_loginfo *info,
63 return; 63 return;
64 } 64 }
65 65
66 /* Max length: 88 "SRC=0000.0000.0000.0000.0000.0000.0000.0000 DST=0000.0000.0000.0000.0000.0000.0000.0000" */ 66 /* Max length: 88 "SRC=0000.0000.0000.0000.0000.0000.0000.0000 DST=0000.0000.0000.0000.0000.0000.0000.0000 " */
67 printk("SRC=%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x ", NIP6(ih->saddr)); 67 printk("SRC=" NIP6_FMT " DST=" NIP6_FMT " ", NIP6(ih->saddr), NIP6(ih->daddr));
68 printk("DST=%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x ", NIP6(ih->daddr));
69 68
70 /* Max length: 44 "LEN=65535 TC=255 HOPLIMIT=255 FLOWLBL=FFFFF " */ 69 /* Max length: 44 "LEN=65535 TC=255 HOPLIMIT=255 FLOWLBL=FFFFF " */
71 printk("LEN=%Zu TC=%u HOPLIMIT=%u FLOWLBL=%u ", 70 printk("LEN=%Zu TC=%u HOPLIMIT=%u FLOWLBL=%u ",
diff --git a/net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c b/net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c
index 92ad53d8f8c3..ac702a29dd16 100644
--- a/net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c
+++ b/net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c
@@ -74,7 +74,7 @@ static int ipv6_invert_tuple(struct nf_conntrack_tuple *tuple,
74static int ipv6_print_tuple(struct seq_file *s, 74static int ipv6_print_tuple(struct seq_file *s,
75 const struct nf_conntrack_tuple *tuple) 75 const struct nf_conntrack_tuple *tuple)
76{ 76{
77 return seq_printf(s, "src=%x:%x:%x:%x:%x:%x:%x:%x dst=%x:%x:%x:%x:%x:%x:%x:%x ", 77 return seq_printf(s, "src=" NIP6_FMT " dst=" NIP6_FMT " ",
78 NIP6(*((struct in6_addr *)tuple->src.u3.ip6)), 78 NIP6(*((struct in6_addr *)tuple->src.u3.ip6)),
79 NIP6(*((struct in6_addr *)tuple->dst.u3.ip6))); 79 NIP6(*((struct in6_addr *)tuple->dst.u3.ip6)));
80} 80}
diff --git a/net/ipv6/xfrm6_tunnel.c b/net/ipv6/xfrm6_tunnel.c
index da09ff258648..8cfc58b96fc2 100644
--- a/net/ipv6/xfrm6_tunnel.c
+++ b/net/ipv6/xfrm6_tunnel.c
@@ -259,8 +259,7 @@ try_next_2:;
259 spi = 0; 259 spi = 0;
260 goto out; 260 goto out;
261alloc_spi: 261alloc_spi:
262 X6TPRINTK3(KERN_DEBUG "%s(): allocate new spi for " 262 X6TPRINTK3(KERN_DEBUG "%s(): allocate new spi for " NIP6_FMT "\n",
263 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
264 __FUNCTION__, 263 __FUNCTION__,
265 NIP6(*(struct in6_addr *)saddr)); 264 NIP6(*(struct in6_addr *)saddr));
266 x6spi = kmem_cache_alloc(xfrm6_tunnel_spi_kmem, SLAB_ATOMIC); 265 x6spi = kmem_cache_alloc(xfrm6_tunnel_spi_kmem, SLAB_ATOMIC);
@@ -323,9 +322,8 @@ void xfrm6_tunnel_free_spi(xfrm_address_t *saddr)
323 list_byaddr) 322 list_byaddr)
324 { 323 {
325 if (memcmp(&x6spi->addr, saddr, sizeof(x6spi->addr)) == 0) { 324 if (memcmp(&x6spi->addr, saddr, sizeof(x6spi->addr)) == 0) {
326 X6TPRINTK3(KERN_DEBUG "%s(): x6spi object " 325 X6TPRINTK3(KERN_DEBUG "%s(): x6spi object for " NIP6_FMT
327 "for %04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x " 326 " found at %p\n",
328 "found at %p\n",
329 __FUNCTION__, 327 __FUNCTION__,
330 NIP6(*(struct in6_addr *)saddr), 328 NIP6(*(struct in6_addr *)saddr),
331 x6spi); 329 x6spi);
diff --git a/net/netfilter/nf_conntrack_ftp.c b/net/netfilter/nf_conntrack_ftp.c
index d5a6eaf4a1de..ab0c920f0d30 100644
--- a/net/netfilter/nf_conntrack_ftp.c
+++ b/net/netfilter/nf_conntrack_ftp.c
@@ -545,11 +545,11 @@ static int help(struct sk_buff **pskb,
545 different IP address. Simply don't record it for 545 different IP address. Simply don't record it for
546 NAT. */ 546 NAT. */
547 if (cmd.l3num == PF_INET) { 547 if (cmd.l3num == PF_INET) {
548 DEBUGP("conntrack_ftp: NOT RECORDING: %u,%u,%u,%u != %u.%u.%u.%u\n", 548 DEBUGP("conntrack_ftp: NOT RECORDING: " NIPQUAD_FMT " != " NIPQUAD_FMT "\n",
549 NIPQUAD(cmd.u3.ip), 549 NIPQUAD(cmd.u3.ip),
550 NIPQUAD(ct->tuplehash[dir].tuple.src.u3.ip)); 550 NIPQUAD(ct->tuplehash[dir].tuple.src.u3.ip));
551 } else { 551 } else {
552 DEBUGP("conntrack_ftp: NOT RECORDING: %x:%x:%x:%x:%x:%x:%x:%x != %x:%x:%x:%x:%x:%x:%x:%x\n", 552 DEBUGP("conntrack_ftp: NOT RECORDING: " NIP6_FMT " != " NIP6_FMT "\n",
553 NIP6(*((struct in6_addr *)cmd.u3.ip6)), 553 NIP6(*((struct in6_addr *)cmd.u3.ip6)),
554 NIP6(*((struct in6_addr *)ct->tuplehash[dir] 554 NIP6(*((struct in6_addr *)ct->tuplehash[dir]
555 .tuple.src.u3.ip6))); 555 .tuple.src.u3.ip6)));
diff --git a/net/sctp/ipv6.c b/net/sctp/ipv6.c
index 04c7fab4edc4..2e266129a764 100644
--- a/net/sctp/ipv6.c
+++ b/net/sctp/ipv6.c
@@ -180,8 +180,7 @@ static int sctp_v6_xmit(struct sk_buff *skb, struct sctp_transport *transport,
180 } 180 }
181 181
182 SCTP_DEBUG_PRINTK("%s: skb:%p, len:%d, " 182 SCTP_DEBUG_PRINTK("%s: skb:%p, len:%d, "
183 "src:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x " 183 "src:" NIP6_FMT " dst:" NIP6_FMT "\n",
184 "dst:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
185 __FUNCTION__, skb, skb->len, 184 __FUNCTION__, skb, skb->len,
186 NIP6(fl.fl6_src), NIP6(fl.fl6_dst)); 185 NIP6(fl.fl6_src), NIP6(fl.fl6_dst));
187 186
@@ -206,13 +205,13 @@ static struct dst_entry *sctp_v6_get_dst(struct sctp_association *asoc,
206 fl.oif = daddr->v6.sin6_scope_id; 205 fl.oif = daddr->v6.sin6_scope_id;
207 206
208 207
209 SCTP_DEBUG_PRINTK("%s: DST=%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x ", 208 SCTP_DEBUG_PRINTK("%s: DST=" NIP6_FMT " ",
210 __FUNCTION__, NIP6(fl.fl6_dst)); 209 __FUNCTION__, NIP6(fl.fl6_dst));
211 210
212 if (saddr) { 211 if (saddr) {
213 ipv6_addr_copy(&fl.fl6_src, &saddr->v6.sin6_addr); 212 ipv6_addr_copy(&fl.fl6_src, &saddr->v6.sin6_addr);
214 SCTP_DEBUG_PRINTK( 213 SCTP_DEBUG_PRINTK(
215 "SRC=%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x - ", 214 "SRC=" NIP6_FMT " - ",
216 NIP6(fl.fl6_src)); 215 NIP6(fl.fl6_src));
217 } 216 }
218 217
@@ -221,8 +220,7 @@ static struct dst_entry *sctp_v6_get_dst(struct sctp_association *asoc,
221 struct rt6_info *rt; 220 struct rt6_info *rt;
222 rt = (struct rt6_info *)dst; 221 rt = (struct rt6_info *)dst;
223 SCTP_DEBUG_PRINTK( 222 SCTP_DEBUG_PRINTK(
224 "rt6_dst:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x " 223 "rt6_dst:" NIP6_FMT " rt6_src:" NIP6_FMT "\n",
225 "rt6_src:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
226 NIP6(rt->rt6i_dst.addr), NIP6(rt->rt6i_src.addr)); 224 NIP6(rt->rt6i_dst.addr), NIP6(rt->rt6i_src.addr));
227 } else { 225 } else {
228 SCTP_DEBUG_PRINTK("NO ROUTE\n"); 226 SCTP_DEBUG_PRINTK("NO ROUTE\n");
@@ -271,13 +269,12 @@ static void sctp_v6_get_saddr(struct sctp_association *asoc,
271 __u8 bmatchlen; 269 __u8 bmatchlen;
272 270
273 SCTP_DEBUG_PRINTK("%s: asoc:%p dst:%p " 271 SCTP_DEBUG_PRINTK("%s: asoc:%p dst:%p "
274 "daddr:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x ", 272 "daddr:" NIP6_FMT " ",
275 __FUNCTION__, asoc, dst, NIP6(daddr->v6.sin6_addr)); 273 __FUNCTION__, asoc, dst, NIP6(daddr->v6.sin6_addr));
276 274
277 if (!asoc) { 275 if (!asoc) {
278 ipv6_get_saddr(dst, &daddr->v6.sin6_addr,&saddr->v6.sin6_addr); 276 ipv6_get_saddr(dst, &daddr->v6.sin6_addr,&saddr->v6.sin6_addr);
279 SCTP_DEBUG_PRINTK("saddr from ipv6_get_saddr: " 277 SCTP_DEBUG_PRINTK("saddr from ipv6_get_saddr: " NIP6_FMT "\n",
280 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
281 NIP6(saddr->v6.sin6_addr)); 278 NIP6(saddr->v6.sin6_addr));
282 return; 279 return;
283 } 280 }
@@ -305,13 +302,11 @@ static void sctp_v6_get_saddr(struct sctp_association *asoc,
305 302
306 if (baddr) { 303 if (baddr) {
307 memcpy(saddr, baddr, sizeof(union sctp_addr)); 304 memcpy(saddr, baddr, sizeof(union sctp_addr));
308 SCTP_DEBUG_PRINTK("saddr: " 305 SCTP_DEBUG_PRINTK("saddr: " NIP6_FMT "\n",
309 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
310 NIP6(saddr->v6.sin6_addr)); 306 NIP6(saddr->v6.sin6_addr));
311 } else { 307 } else {
312 printk(KERN_ERR "%s: asoc:%p Could not find a valid source " 308 printk(KERN_ERR "%s: asoc:%p Could not find a valid source "
313 "address for the " 309 "address for the dest:" NIP6_FMT "\n",
314 "dest:%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n",
315 __FUNCTION__, asoc, NIP6(daddr->v6.sin6_addr)); 310 __FUNCTION__, asoc, NIP6(daddr->v6.sin6_addr));
316 } 311 }
317 312
@@ -675,8 +670,7 @@ static int sctp_v6_is_ce(const struct sk_buff *skb)
675/* Dump the v6 addr to the seq file. */ 670/* Dump the v6 addr to the seq file. */
676static void sctp_v6_seq_dump_addr(struct seq_file *seq, union sctp_addr *addr) 671static void sctp_v6_seq_dump_addr(struct seq_file *seq, union sctp_addr *addr)
677{ 672{
678 seq_printf(seq, "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x ", 673 seq_printf(seq, NIP6_FMT " ", NIP6(addr->v6.sin6_addr));
679 NIP6(addr->v6.sin6_addr));
680} 674}
681 675
682/* Initialize a PF_INET6 socket msg_name. */ 676/* Initialize a PF_INET6 socket msg_name. */
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c
index 557a7d90b92a..477d7f80dba6 100644
--- a/net/sctp/sm_statefuns.c
+++ b/net/sctp/sm_statefuns.c
@@ -1036,14 +1036,14 @@ sctp_disposition_t sctp_sf_backbeat_8_3(const struct sctp_endpoint *ep,
1036 if (from_addr.sa.sa_family == AF_INET6) { 1036 if (from_addr.sa.sa_family == AF_INET6) {
1037 printk(KERN_WARNING 1037 printk(KERN_WARNING
1038 "%s association %p could not find address " 1038 "%s association %p could not find address "
1039 "%04x:%04x:%04x:%04x:%04x:%04x:%04x:%04x\n", 1039 NIP6_FMT "\n",
1040 __FUNCTION__, 1040 __FUNCTION__,
1041 asoc, 1041 asoc,
1042 NIP6(from_addr.v6.sin6_addr)); 1042 NIP6(from_addr.v6.sin6_addr));
1043 } else { 1043 } else {
1044 printk(KERN_WARNING 1044 printk(KERN_WARNING
1045 "%s association %p could not find address " 1045 "%s association %p could not find address "
1046 "%u.%u.%u.%u\n", 1046 NIPQUAD_FMT "\n",
1047 __FUNCTION__, 1047 __FUNCTION__,
1048 asoc, 1048 asoc,
1049 NIPQUAD(from_addr.v4.sin_addr.s_addr)); 1049 NIPQUAD(from_addr.v4.sin_addr.s_addr));
diff --git a/security/selinux/avc.c b/security/selinux/avc.c
index 12e4fb72bf0f..53d6c7bbf564 100644
--- a/security/selinux/avc.c
+++ b/security/selinux/avc.c
@@ -494,8 +494,7 @@ static inline void avc_print_ipv6_addr(struct audit_buffer *ab,
494 char *name1, char *name2) 494 char *name1, char *name2)
495{ 495{
496 if (!ipv6_addr_any(addr)) 496 if (!ipv6_addr_any(addr))
497 audit_log_format(ab, " %s=%04x:%04x:%04x:%04x:%04x:" 497 audit_log_format(ab, " %s=" NIP6_FMT, name1, NIP6(*addr));
498 "%04x:%04x:%04x", name1, NIP6(*addr));
499 if (port) 498 if (port)
500 audit_log_format(ab, " %s=%d", name2, ntohs(port)); 499 audit_log_format(ab, " %s=%d", name2, ntohs(port));
501} 500}
@@ -504,7 +503,7 @@ static inline void avc_print_ipv4_addr(struct audit_buffer *ab, u32 addr,
504 __be16 port, char *name1, char *name2) 503 __be16 port, char *name1, char *name2)
505{ 504{
506 if (addr) 505 if (addr)
507 audit_log_format(ab, " %s=%d.%d.%d.%d", name1, NIPQUAD(addr)); 506 audit_log_format(ab, " %s=" NIPQUAD_FMT, name1, NIPQUAD(addr));
508 if (port) 507 if (port)
509 audit_log_format(ab, " %s=%d", name2, ntohs(port)); 508 audit_log_format(ab, " %s=%d", name2, ntohs(port));
510} 509}