Roopa Prabhu | e3e4712 | 2015-07-21 10:43:53 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2015 Cumulus Networks, Inc. |
| 3 | * |
| 4 | * This program is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of version 2 of the GNU General Public |
| 6 | * License as published by the Free Software Foundation. |
| 7 | * |
| 8 | * This program is distributed in the hope that it will be useful, but |
| 9 | * WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 11 | * General Public License for more details. |
| 12 | */ |
| 13 | |
| 14 | #ifndef _NET_MPLS_IPTUNNEL_H |
| 15 | #define _NET_MPLS_IPTUNNEL_H 1 |
| 16 | |
| 17 | #define MAX_NEW_LABELS 2 |
| 18 | |
| 19 | struct mpls_iptunnel_encap { |
| 20 | u32 label[MAX_NEW_LABELS]; |
Roopa Prabhu | f8efb73 | 2015-10-23 06:03:27 -0700 | [diff] [blame] | 21 | u8 labels; |
Roopa Prabhu | e3e4712 | 2015-07-21 10:43:53 +0200 | [diff] [blame] | 22 | }; |
| 23 | |
| 24 | static inline struct mpls_iptunnel_encap *mpls_lwtunnel_encap(struct lwtunnel_state *lwtstate) |
| 25 | { |
| 26 | return (struct mpls_iptunnel_encap *)lwtstate->data; |
| 27 | } |
| 28 | |
| 29 | #endif |