summaryrefslogtreecommitdiffstats
path: root/net/mpls/internal.h
diff options
context:
space:
mode:
authorDavid Ahern <dsa@cumulusnetworks.com>2017-03-31 16:14:04 +0200
committerDavid S. Miller <davem@davemloft.net>2017-04-02 05:21:44 +0200
commit1511009cd68015c2e04135bfefa4bf5020baa8d9 (patch)
treeca1ca7c8f76a3bc752ccf31e3b216fa9119f71d7 /net/mpls/internal.h
parentnet: mpls: bump maximum number of labels (diff)
downloadlinux-1511009cd68015c2e04135bfefa4bf5020baa8d9.tar.xz
linux-1511009cd68015c2e04135bfefa4bf5020baa8d9.zip
net: mpls: Increase max number of labels for lwt encap
Alow users to push down more labels per MPLS encap. Similar to LSR case, move label array to the end of mpls_iptunnel_encap and allocate based on the number of labels for the route. For consistency with the LSR case, re-use the same maximum number of labels. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mpls/internal.h')
-rw-r--r--net/mpls/internal.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/net/mpls/internal.h b/net/mpls/internal.h
index c5d2f5bc37ec..4db6a5971322 100644
--- a/net/mpls/internal.h
+++ b/net/mpls/internal.h
@@ -2,6 +2,11 @@
#define MPLS_INTERNAL_H
#include <net/mpls.h>
+/* put a reasonable limit on the number of labels
+ * we will accept from userspace
+ */
+#define MAX_NEW_LABELS 30
+
struct mpls_entry_decoded {
u32 label;
u8 ttl;