nat: Rename ip-tos to ip-dscp and provide an alias...
diff --git a/openbsc/include/openbsc/bsc_nat.h b/openbsc/include/openbsc/bsc_nat.h
index b628ed0..32628d6 100644
--- a/openbsc/include/openbsc/bsc_nat.h
+++ b/openbsc/include/openbsc/bsc_nat.h
@@ -241,7 +241,7 @@
 	/* known BSC's */
 	struct llist_head bsc_configs;
 	int num_bsc;
-	int bsc_ip_tos;
+	int bsc_ip_dscp;
 
 	/* MGCP config */
 	struct mgcp_config *mgcp_cfg;
diff --git a/openbsc/src/nat/bsc_nat.c b/openbsc/src/nat/bsc_nat.c
index 826f288..538472a 100644
--- a/openbsc/src/nat/bsc_nat.c
+++ b/openbsc/src/nat/bsc_nat.c
@@ -898,7 +898,7 @@
                 LOGP(DNAT, LOGL_ERROR, "Failed to set TCP_NODELAY: %s\n", strerror(errno));
 
 	rc = setsockopt(fd, IPPROTO_IP, IP_TOS,
-			&nat->bsc_ip_tos, sizeof(nat->bsc_ip_tos));
+			&nat->bsc_ip_dscp, sizeof(nat->bsc_ip_dscp));
 	if (rc != 0)
 		LOGP(DNAT, LOGL_ERROR, "Failed to set IP_TOS: %s\n", strerror(errno));
 
diff --git a/openbsc/src/nat/bsc_nat_vty.c b/openbsc/src/nat/bsc_nat_vty.c
index 49ac3e2..0345360 100644
--- a/openbsc/src/nat/bsc_nat_vty.c
+++ b/openbsc/src/nat/bsc_nat_vty.c
@@ -73,7 +73,7 @@
 	vty_out(vty, " timeout pong %d%s", _nat->pong_timeout, VTY_NEWLINE);
 	if (_nat->token)
 		vty_out(vty, " token %s%s", _nat->token, VTY_NEWLINE);
-	vty_out(vty, " ip-tos %d%s", _nat->bsc_ip_tos, VTY_NEWLINE);
+	vty_out(vty, " ip-dscp %d%s", _nat->bsc_ip_dscp, VTY_NEWLINE);
 	if (_nat->acc_lst_name)
 		vty_out(vty, " access-list-name %s%s", _nat->acc_lst_name, VTY_NEWLINE);
 
@@ -341,14 +341,19 @@
 	return CMD_SUCCESS;
 }
 
-DEFUN(cfg_nat_bsc_ip_tos, cfg_nat_bsc_ip_tos_cmd,
-      "ip-tos <0-255>",
-      "Set the IP_TOS for the BSCs to use\n" "Set the IP_TOS attribute")
+DEFUN(cfg_nat_bsc_ip_dscp, cfg_nat_bsc_ip_dscp_cmd,
+      "ip-dscp <0-255>",
+      "Set the IP DSCP for the BSCs to use\n" "Set the IP_TOS attribute")
 {
-	_nat->bsc_ip_tos = atoi(argv[0]);
+	_nat->bsc_ip_dscp = atoi(argv[0]);
 	return CMD_SUCCESS;
 }
 
+ALIAS_DEPRECATED(cfg_nat_bsc_ip_dscp, cfg_nat_bsc_ip_tos_cmd,
+      "ip-tos <0-255>",
+      "Use ip-dscp in the future.\n" "Set the DSCP\n")
+
+
 DEFUN(cfg_nat_acc_lst_name,
       cfg_nat_acc_lst_name_cmd,
       "access-list-name NAME",
@@ -569,6 +574,7 @@
 	install_element(NAT_NODE, &cfg_nat_ping_time_cmd);
 	install_element(NAT_NODE, &cfg_nat_pong_time_cmd);
 	install_element(NAT_NODE, &cfg_nat_token_cmd);
+	install_element(NAT_NODE, &cfg_nat_bsc_ip_dscp_cmd);
 	install_element(NAT_NODE, &cfg_nat_bsc_ip_tos_cmd);
 	install_element(NAT_NODE, &cfg_nat_acc_lst_name_cmd);