Skip to contentSkip to conversation

ip: add rmnet initial support

PATCH New Daniele Palmas 1 participant 1 message Jun 15, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 ip: add rmnet initial support

This patch adds basic support for Qualcomm rmnet devices.

---
v2:
rebased on iproute2-next
removed GPL boilerplate
added print_opt function
man page updated
fixed MUXID values

---
 ip/Makefile           |  2 +-
 ip/iplink.c           |  2 +-
 ip/iplink_rmnet.c     | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++
 man/man8/ip-link.8.in | 21 ++++++++++++-
 4 files changed, 103 insertions(+), 3 deletions(-)
 create mode 100644 ip/iplink_rmnet.c
ip/Makefile +1 -1
index 77fadee..a88f936 100644
@@ -10,7 +10,7 @@ IPOBJ=ip.o ipaddress.o ipaddrlabel.o iproute.o iprule.o ipnetns.o \
     link_iptnl.o link_gre6.o iplink_bond.o iplink_bond_slave.o iplink_hsr.o \
     iplink_bridge.o iplink_bridge_slave.o ipfou.o iplink_ipvlan.o \
     iplink_geneve.o iplink_vrf.o iproute_lwtunnel.o ipmacsec.o ipila.o \
-    ipvrf.o iplink_xstats.o ipseg6.o iplink_netdevsim.o
+    ipvrf.o iplink_xstats.o ipseg6.o iplink_netdevsim.o iplink_rmnet.o
 
 RTMONOBJ=rtmon.o
 
ip/iplink.c +1 -1
index e4d4da9..0ba5f1a 100644
@@ -121,7 +121,7 @@ void iplink_usage(void)
 			"          bridge | bond | team | ipoib | ip6tnl | ipip | sit | vxlan |\n"
 			"          gre | gretap | erspan | ip6gre | ip6gretap | ip6erspan |\n"
 			"          vti | nlmon | team_slave | bond_slave | ipvlan | geneve |\n"
-			"          bridge_slave | vrf | macsec | netdevsim }\n");
+			"          bridge_slave | vrf | macsec | netdevsim | rmnet }\n");
 	}
 	exit(-1);
 }
ip/iplink_rmnet.c new file +81 -0

81 lines not on this page · raw message

man/man8/ip-link.8.in +20 -1
index 83ef3ca..fd2c107 100644
@@ -219,7 +219,8 @@ ip-link \- network device configuration
 .BR geneve " |"
 .BR vrf " |"
 .BR macsec " |"
-.BR netdevsim " ]"
+.BR netdevsim " |"
+.BR rmnet " ]"
 
 .ti -8
 .IR ETYPE " := [ " TYPE " |"
@@ -342,6 +343,9 @@ Link types:
 .sp
 .BR netdevsim
 - Interface for netdev API tests
+.sp
+.BR rmnet
+- Qualcomm rmnet device
 .in -8
 
 .TP
@@ -1651,6 +1655,21 @@ the following additional arguments are supported:
 
 .in -8
 
+.TP
+RMNET Type Support
+For a link of type
+.I RMNET
+the following additional arguments are supported:
+
+.BI "ip link add link " DEVICE " name " NAME " type rmnet mux_id " MUXID
+
+.in +8
+.sp
+.BI mux_id " MUXID "
+- specifies the mux identifier for the rmnet device, possible values 1-254.
+
+.in -8
+
 .SS ip link delete - delete virtual link
 
 .TP
Signature · 1 line
2.7.4