gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U)
This is an initial implementation of a netdev driver for GTP datapath (GTP-U) v0 and v1, according to the GSM TS 09.60 and 3GPP TS 29.060 standards. This tunneling protocol is used to prevent subscribers from accessing mobile carrier core network infrastructure. This implementation requires a GGSN userspace daemon that implements the signaling protocol (GTP-C), such as OpenGGSN [1]. This userspace daemon updates the PDP context database that represents active subscriber sessions through a genetlink interface. For more context on this tunneling protocol, you can check the slides that were presented during the NetDev 1.1 [2]. Only IPv4 is supported at this time. [1] http://git.osmocom.org/openggsn/ [2] http://www.netdevconf.org/1.1/proceedings/slides/schultz-welte-osmocom-gtp.pdf Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
c047c3b1af
commit
459aa660eb
@@ -141,6 +141,7 @@ header-y += gfs2_ondisk.h
|
||||
header-y += gigaset_dev.h
|
||||
header-y += gpio.h
|
||||
header-y += gsmmux.h
|
||||
header-y += gtp.h
|
||||
header-y += hdlcdrv.h
|
||||
header-y += hdlc.h
|
||||
header-y += hdreg.h
|
||||
|
33
include/uapi/linux/gtp.h
Normal file
33
include/uapi/linux/gtp.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef _UAPI_LINUX_GTP_H_
|
||||
#define _UAPI_LINUX_GTP_H__
|
||||
|
||||
enum gtp_genl_cmds {
|
||||
GTP_CMD_NEWPDP,
|
||||
GTP_CMD_DELPDP,
|
||||
GTP_CMD_GETPDP,
|
||||
|
||||
GTP_CMD_MAX,
|
||||
};
|
||||
|
||||
enum gtp_version {
|
||||
GTP_V0 = 0,
|
||||
GTP_V1,
|
||||
};
|
||||
|
||||
enum gtp_attrs {
|
||||
GTPA_UNSPEC = 0,
|
||||
GTPA_LINK,
|
||||
GTPA_VERSION,
|
||||
GTPA_TID, /* for GTPv0 only */
|
||||
GTPA_SGSN_ADDRESS,
|
||||
GTPA_MS_ADDRESS,
|
||||
GTPA_FLOW,
|
||||
GTPA_NET_NS_FD,
|
||||
GTPA_I_TEI, /* for GTPv1 only */
|
||||
GTPA_O_TEI, /* for GTPv1 only */
|
||||
GTPA_PAD,
|
||||
__GTPA_MAX,
|
||||
};
|
||||
#define GTPA_MAX (__GTPA_MAX + 1)
|
||||
|
||||
#endif /* _UAPI_LINUX_GTP_H_ */
|
@@ -529,6 +529,16 @@ enum {
|
||||
};
|
||||
#define IFLA_PPP_MAX (__IFLA_PPP_MAX - 1)
|
||||
|
||||
/* GTP section */
|
||||
enum {
|
||||
IFLA_GTP_UNSPEC,
|
||||
IFLA_GTP_FD0,
|
||||
IFLA_GTP_FD1,
|
||||
IFLA_GTP_PDP_HASHSIZE,
|
||||
__IFLA_GTP_MAX,
|
||||
};
|
||||
#define IFLA_GTP_MAX (__IFLA_GTP_MAX - 1)
|
||||
|
||||
/* Bonding section */
|
||||
|
||||
enum {
|
||||
|
@@ -36,6 +36,7 @@ struct udphdr {
|
||||
#define UDP_ENCAP_ESPINUDP_NON_IKE 1 /* draft-ietf-ipsec-nat-t-ike-00/01 */
|
||||
#define UDP_ENCAP_ESPINUDP 2 /* draft-ietf-ipsec-udp-encaps-06 */
|
||||
#define UDP_ENCAP_L2TPINUDP 3 /* rfc2661 */
|
||||
|
||||
#define UDP_ENCAP_GTP0 4 /* GSM TS 09.60 */
|
||||
#define UDP_ENCAP_GTP1U 5 /* 3GPP TS 29.060 */
|
||||
|
||||
#endif /* _UAPI_LINUX_UDP_H */
|
||||
|
Reference in New Issue
Block a user