diff options
Diffstat (limited to 'net/ipv6/ip6_flowlabel.c')
-rw-r--r-- | net/ipv6/ip6_flowlabel.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/net/ipv6/ip6_flowlabel.c b/net/ipv6/ip6_flowlabel.c index 2b45f2d657c2..6d4533b58dca 100644 --- a/net/ipv6/ip6_flowlabel.c +++ b/net/ipv6/ip6_flowlabel.c | |||
@@ -627,9 +627,13 @@ static void ip6fl_seq_stop(struct seq_file *seq, void *v) | |||
627 | read_unlock_bh(&ip6_fl_lock); | 627 | read_unlock_bh(&ip6_fl_lock); |
628 | } | 628 | } |
629 | 629 | ||
630 | static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl) | 630 | static int ip6fl_seq_show(struct seq_file *seq, void *v) |
631 | { | 631 | { |
632 | while(fl) { | 632 | if (v == SEQ_START_TOKEN) |
633 | seq_printf(seq, "%-5s %-1s %-6s %-6s %-6s %-8s %-32s %s\n", | ||
634 | "Label", "S", "Owner", "Users", "Linger", "Expires", "Dst", "Opt"); | ||
635 | else { | ||
636 | struct ip6_flowlabel *fl = v; | ||
633 | seq_printf(seq, | 637 | seq_printf(seq, |
634 | "%05X %-1d %-6d %-6d %-6ld %-8ld " NIP6_SEQFMT " %-4d\n", | 638 | "%05X %-1d %-6d %-6d %-6ld %-8ld " NIP6_SEQFMT " %-4d\n", |
635 | (unsigned)ntohl(fl->label), | 639 | (unsigned)ntohl(fl->label), |
@@ -640,17 +644,7 @@ static void ip6fl_fl_seq_show(struct seq_file *seq, struct ip6_flowlabel *fl) | |||
640 | (long)(fl->expires - jiffies)/HZ, | 644 | (long)(fl->expires - jiffies)/HZ, |
641 | NIP6(fl->dst), | 645 | NIP6(fl->dst), |
642 | fl->opt ? fl->opt->opt_nflen : 0); | 646 | fl->opt ? fl->opt->opt_nflen : 0); |
643 | fl = fl->next; | ||
644 | } | 647 | } |
645 | } | ||
646 | |||
647 | static int ip6fl_seq_show(struct seq_file *seq, void *v) | ||
648 | { | ||
649 | if (v == SEQ_START_TOKEN) | ||
650 | seq_printf(seq, "%-5s %-1s %-6s %-6s %-6s %-8s %-32s %s\n", | ||
651 | "Label", "S", "Owner", "Users", "Linger", "Expires", "Dst", "Opt"); | ||
652 | else | ||
653 | ip6fl_fl_seq_show(seq, v); | ||
654 | return 0; | 648 | return 0; |
655 | } | 649 | } |
656 | 650 | ||