Skip to content

Commit

Permalink
js: GtpLocator
Browse files Browse the repository at this point in the history
  • Loading branch information
yoursunny committed Jun 21, 2024
1 parent 269f611 commit 726d19e
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 6 deletions.
6 changes: 3 additions & 3 deletions cmd/ndndpdk-upf/upfconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,19 @@ func (cfg *UpfConfig) DefineFlags(flags []cli.Flag) []cli.Flag {
},
&cli.StringFlag{
Name: "upf-n3",
Usage: "UPF N3/N9 IPv4 `address`",
Usage: "UPF N3 IPv4 `address`",
Required: true,
Action: cfg.saveIPv4(&cfg.upfIP),
},
&cli.GenericFlag{
Name: "upf-mac",
Usage: "UPF N3/N9 MAC `address`",
Usage: "UPF N3 MAC `address`",
Required: true,
Destination: &cfg.upfMAC,
},
&cli.IntFlag{
Name: "upf-vlan",
Usage: "UPF N3/N9 `VLAN ID`",
Usage: "UPF N3 `VLAN ID`",
Destination: &cfg.upfVLAN,
},
&cli.StringSliceFlag{
Expand Down
2 changes: 1 addition & 1 deletion iface/ethface/gtp.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ var (

const schemeGtp = "gtp"

// VxlanLocator describes a GTP-U face.
// GtpLocator describes a GTP-U face.
type GtpLocator struct {
IPLocator

Expand Down
34 changes: 32 additions & 2 deletions js/types/iface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export type FaceID = Uint;
* Face locator.
* @see <https://pkg.go.dev/github.com/usnistgov/ndn-dpdk/iface#Locator>
*/
export type FaceLocator = EtherLocator | UdpLocator | VxlanLocator | MemifLocator | SocketFaceLocator;
export type FaceLocator = EtherLocator | UdpLocator | VxlanLocator | GtpLocator | MemifLocator | SocketFaceLocator;

/**
* Face configuration.
Expand Down Expand Up @@ -125,7 +125,6 @@ export interface VxlanLocator extends IpLocatorBase {
scheme: "vxlan";

/**
* @minimum 0
* @maximum 16777215
*/
vxlan: Uint;
Expand All @@ -134,6 +133,37 @@ export interface VxlanLocator extends IpLocatorBase {
innerRemote: string;
}

/**
* GTP-U face locator.
* @see <https://pkg.go.dev/github.com/usnistgov/ndn-dpdk/iface/ethface#GtpLocator>
*/
export interface GtpLocator extends IpLocatorBase {
scheme: "gtp";

/**
* @maximum 4294967295
*/
ulTEID: Uint;

/**
* @maximum 63
*/
ulQFI: Uint;

/**
* @maximum 4294967295
*/
dlTEID: Uint;

/**
* @maximum 63
*/
dlQFI: Uint;

innerLocalIP: string;
innerRemoteIP: string;
}

export type MemifRole = "server" | "client";

/**
Expand Down
1 change: 1 addition & 0 deletions mk/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ install -m0755 build/bin/ndndpdk-godemo "$DESTBIN/"
install -m0755 build/bin/ndndpdk-hrlog2histogram "$DESTBIN/"
install -m0755 build/bin/ndndpdk-jrproxy "$DESTBIN/"
install -m0755 build/bin/ndndpdk-svc "$DESTBIN/"
install -m0755 build/bin/ndndpdk-upf "$DESTBIN/"

install -d -m0755 "$DESTSHARE"
install -m0644 build/share/ndn-dpdk/* "$DESTSHARE/"
Expand Down

0 comments on commit 726d19e

Please sign in to comment.