-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Eric W. Biederman says: ==================== Basic MPLS support take 2 On top of my two pending neighbour table prep patches here is the mpls support refactored to use them, and edited to not drop routes when an interface goes down. Additionally the addition of RTA_LLGATEWAY has been replaced with the addtion of RTA_VIA. RTA_VIA being an attribute that includes the address family as well as the address of the next hop. MPLS is at it's heart simple and I have endeavoured to maintain that simplicity in my implemenation. This is an implementation of a RFC3032 forwarding engine, and basic MPLS egress logic. Which should make linux sufficient to be a mpls forwarding node or to be a LSA (Label Switched Router) as it says in all of the MPLS documents. The ingress support will follow but it deserves it's own discussion so I am pushing it separately. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
- Loading branch information
Showing
10 changed files
with
1,110 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/proc/sys/net/mpls/* Variables: | ||
|
||
platform_labels - INTEGER | ||
Number of entries in the platform label table. It is not | ||
possible to configure forwarding for label values equal to or | ||
greater than the number of platform labels. | ||
|
||
A dense utliziation of the entries in the platform label table | ||
is possible and expected aas the platform labels are locally | ||
allocated. | ||
|
||
If the number of platform label table entries is set to 0 no | ||
label will be recognized by the kernel and mpls forwarding | ||
will be disabled. | ||
|
||
Reducing this value will remove all label routing entries that | ||
no longer fit in the table. | ||
|
||
Possible values: 0 - 1048575 | ||
Default: 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
/* | ||
* mpls in net namespaces | ||
*/ | ||
|
||
#ifndef __NETNS_MPLS_H__ | ||
#define __NETNS_MPLS_H__ | ||
|
||
struct mpls_route; | ||
struct ctl_table_header; | ||
|
||
struct netns_mpls { | ||
size_t platform_labels; | ||
struct mpls_route __rcu * __rcu *platform_label; | ||
struct ctl_table_header *ctl; | ||
}; | ||
|
||
#endif /* __NETNS_MPLS_H__ */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,30 @@ | ||
# | ||
# MPLS configuration | ||
# | ||
|
||
menuconfig MPLS | ||
tristate "MultiProtocol Label Switching" | ||
default n | ||
---help--- | ||
MultiProtocol Label Switching routes packets through logical | ||
circuits. Originally conceved as a way of routing packets at | ||
hardware speeds (before hardware was capable of routing ipv4 packets), | ||
MPLS remains as simple way of making tunnels. | ||
|
||
If you have not heard of MPLS you probably want to say N here. | ||
|
||
if MPLS | ||
|
||
config NET_MPLS_GSO | ||
tristate "MPLS: GSO support" | ||
bool "MPLS: GSO support" | ||
help | ||
This is helper module to allow segmentation of non-MPLS GSO packets | ||
that have had MPLS stack entries pushed onto them and thus | ||
become MPLS GSO packets. | ||
|
||
config MPLS_ROUTING | ||
bool "MPLS: routing support" | ||
help | ||
Add support for forwarding of mpls packets. | ||
|
||
endif # MPLS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
# Makefile for MPLS. | ||
# | ||
obj-$(CONFIG_NET_MPLS_GSO) += mpls_gso.o | ||
obj-$(CONFIG_MPLS_ROUTING) += af_mpls.o |
Oops, something went wrong.