Diff between 2777515a794bda8d231d7d2636844de0f1171fb9 and fead292f2e108370bf9d54b3c1d8c0b806b6ede6

Changed Files

File Additions Deletions Status
Makefile.tools +17 -13 modified
tools/mesh-gatt/README +0 -0 renamed
tools/mesh-gatt/config-client.c +8 -6 renamed
tools/mesh-gatt/config-server.c +7 -7 renamed
tools/mesh-gatt/crypto.c +3 -2 renamed
tools/mesh-gatt/crypto.h +0 -0 renamed
tools/mesh-gatt/gatt.c +6 -5 renamed
tools/mesh-gatt/gatt.h +0 -0 renamed
tools/mesh-gatt/keys.h +0 -0 renamed
tools/mesh-gatt/local_node.json +0 -0 renamed
tools/mesh-gatt/mesh-net.h +0 -0 renamed
tools/mesh-gatt/net.c +8 -8 renamed
tools/mesh-gatt/net.h +0 -0 renamed
tools/mesh-gatt/node.c +9 -7 renamed
tools/mesh-gatt/node.h +0 -0 renamed
tools/mesh-gatt/onoff-model.c +8 -7 renamed
tools/mesh-gatt/onoff-model.h +0 -0 renamed
tools/mesh-gatt/prov-db.c +7 -7 renamed
tools/mesh-gatt/prov-db.h +0 -0 renamed
tools/mesh-gatt/prov.c +9 -7 renamed
tools/mesh-gatt/prov.h +0 -0 renamed
tools/mesh-gatt/prov_db.json +0 -0 renamed
tools/mesh-gatt/util.c +4 -3 renamed
tools/mesh-gatt/util.h +0 -0 renamed
tools/meshctl.c +12 -10 modified

Full Patch

diff --git a/Makefile.tools b/Makefile.tools
index 7ce05b7..feb2c85 100644
--- a/Makefile.tools
+++ b/Makefile.tools
@@ -304,25 +304,29 @@ if MESH
 bin_PROGRAMS += tools/meshctl
 
 tools_meshctl_SOURCES = tools/meshctl.c \
-				tools/mesh/mesh-net.h \
-				tools/mesh/node.h tools/mesh/node.c \
-				tools/mesh/gatt.h tools/mesh/gatt.c \
-				tools/mesh/crypto.h tools/mesh/crypto.c \
-				tools/mesh/keys.h \
-				tools/mesh/net.h tools/mesh/net.c \
-				tools/mesh/prov.h tools/mesh/prov.c \
-				tools/mesh/util.h tools/mesh/util.c \
 				tools/mesh/agent.h tools/mesh/agent.c \
-				tools/mesh/prov-db.h tools/mesh/prov-db.c \
-				tools/mesh/config-model.h tools/mesh/config-client.c \
-				tools/mesh/config-server.c \
-				tools/mesh/onoff-model.h tools/mesh/onoff-model.c
+				tools/mesh/config-model.h\
+				tools/mesh-gatt/mesh-net.h \
+				tools/mesh-gatt/node.h tools/mesh-gatt/node.c \
+				tools/mesh-gatt/gatt.h tools/mesh-gatt/gatt.c \
+				tools/mesh-gatt/crypto.h\
+				tools/mesh-gatt/crypto.c \
+				tools/mesh-gatt/keys.h \
+				tools/mesh-gatt/net.h tools/mesh-gatt/net.c \
+				tools/mesh-gatt/prov.h tools/mesh-gatt/prov.c \
+				tools/mesh-gatt/util.h tools/mesh-gatt/util.c \
+				tools/mesh-gatt/prov-db.h \
+				tools/mesh-gatt/prov-db.c \
+				tools/mesh-gatt/config-client.c \
+				tools/mesh-gatt/config-server.c \
+				tools/mesh-gatt/onoff-model.h \
+				tools/mesh-gatt/onoff-model.c
 tools_meshctl_LDADD = gdbus/libgdbus-internal.la src/libshared-glib.la \
 				lib/libbluetooth-internal.la \
 				$(GLIB_LIBS) $(DBUS_LIBS) -ljson-c -lreadline
 endif
 
-EXTRA_DIST += tools/mesh/local_node.json tools/mesh/prov_db.json
+EXTRA_DIST += tools/mesh-gatt/local_node.json tools/mesh-gatt/prov_db.json
 
 if DEPRECATED
 bin_PROGRAMS += tools/hciattach tools/hciconfig tools/hcitool tools/hcidump \
diff --git a/tools/mesh/README b/tools/mesh-gatt/README
similarity index 100%
rename from tools/mesh/README
rename to tools/mesh-gatt/README
diff --git a/tools/mesh/config-client.c b/tools/mesh-gatt/config-client.c
similarity index 98%
rename from tools/mesh/config-client.c
rename to tools/mesh-gatt/config-client.c
index df26436..5e6374f 100644
--- a/tools/mesh/config-client.c
+++ b/tools/mesh-gatt/config-client.c
@@ -39,14 +39,16 @@
 
 #include "src/shared/shell.h"
 #include "src/shared/util.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/net.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/prov-db.h"
-#include "tools/mesh/util.h"
+
 #include "tools/mesh/config-model.h"
 
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/prov-db.h"
+#include "tools/mesh-gatt/util.h"
+
 #define MIN_COMPOSITION_LEN 16
 
 static uint32_t print_mod_id(uint8_t *data, bool vid)
diff --git a/tools/mesh/config-server.c b/tools/mesh-gatt/config-server.c
similarity index 95%
rename from tools/mesh/config-server.c
rename to tools/mesh-gatt/config-server.c
index 55035ba..8fc6edc 100644
--- a/tools/mesh/config-server.c
+++ b/tools/mesh-gatt/config-server.c
@@ -36,16 +36,16 @@
 #include <wordexp.h>
 
 #include <glib.h>
+#include "tools/mesh/config-model.h"
 
 #include "src/shared/util.h"
 #include "src/shared/shell.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/net.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/prov-db.h"
-#include "tools/mesh/util.h"
-#include "tools/mesh/config-model.h"
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/prov-db.h"
+#include "tools/mesh-gatt/util.h"
 
 static bool server_msg_recvd(uint16_t src, uint8_t *data,
 				uint16_t len, void *user_data)
diff --git a/tools/mesh/crypto.c b/tools/mesh-gatt/crypto.c
similarity index 99%
rename from tools/mesh/crypto.c
rename to tools/mesh-gatt/crypto.c
index 9935612..493b502 100644
--- a/tools/mesh/crypto.c
+++ b/tools/mesh-gatt/crypto.c
@@ -43,8 +43,9 @@
 #endif
 
 #include "src/shared/util.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/crypto.h"
+
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/crypto.h"
 
 static int alg_new(int fd, const void *keyval, socklen_t keylen,
 		size_t mic_size)
diff --git a/tools/mesh/crypto.h b/tools/mesh-gatt/crypto.h
similarity index 100%
rename from tools/mesh/crypto.h
rename to tools/mesh-gatt/crypto.h
diff --git a/tools/mesh/gatt.c b/tools/mesh-gatt/gatt.c
similarity index 96%
rename from tools/mesh/gatt.c
rename to tools/mesh-gatt/gatt.c
index 0a942d4..bff5947 100644
--- a/tools/mesh/gatt.c
+++ b/tools/mesh-gatt/gatt.c
@@ -40,11 +40,12 @@
 #include "gdbus/gdbus.h"
 #include "lib/bluetooth.h"
 #include "lib/uuid.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/util.h"
-#include "tools/mesh/gatt.h"
-#include "tools/mesh/prov.h"
-#include "tools/mesh/net.h"
+
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/util.h"
+#include "tools/mesh-gatt/gatt.h"
+#include "tools/mesh-gatt/prov.h"
+#include "tools/mesh-gatt/net.h"
 
 #define MESH_PROV_DATA_OUT_UUID_STR	"00002adc-0000-1000-8000-00805f9b34fb"
 #define MESH_PROXY_DATA_OUT_UUID_STR	"00002ade-0000-1000-8000-00805f9b34fb"
diff --git a/tools/mesh/gatt.h b/tools/mesh-gatt/gatt.h
similarity index 100%
rename from tools/mesh/gatt.h
rename to tools/mesh-gatt/gatt.h
diff --git a/tools/mesh/keys.h b/tools/mesh-gatt/keys.h
similarity index 100%
rename from tools/mesh/keys.h
rename to tools/mesh-gatt/keys.h
diff --git a/tools/mesh/local_node.json b/tools/mesh-gatt/local_node.json
similarity index 100%
rename from tools/mesh/local_node.json
rename to tools/mesh-gatt/local_node.json
diff --git a/tools/mesh/mesh-net.h b/tools/mesh-gatt/mesh-net.h
similarity index 100%
rename from tools/mesh/mesh-net.h
rename to tools/mesh-gatt/mesh-net.h
diff --git a/tools/mesh/net.c b/tools/mesh-gatt/net.c
similarity index 98%
rename from tools/mesh/net.c
rename to tools/mesh-gatt/net.c
index f1ef23a..e8171c6 100644
--- a/tools/mesh/net.c
+++ b/tools/mesh-gatt/net.c
@@ -35,14 +35,14 @@
 #include "src/shared/util.h"
 #include "src/shared/shell.h"
 
-#include "tools/mesh/crypto.h"
-#include "tools/mesh/gatt.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/util.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/prov-db.h"
-#include "tools/mesh/net.h"
+#include "tools/mesh-gatt/crypto.h"
+#include "tools/mesh-gatt/gatt.h"
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/util.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/prov-db.h"
+#include "tools/mesh-gatt/net.h"
 
 struct address_range
 {
diff --git a/tools/mesh/net.h b/tools/mesh-gatt/net.h
similarity index 100%
rename from tools/mesh/net.h
rename to tools/mesh-gatt/net.h
diff --git a/tools/mesh/node.c b/tools/mesh-gatt/node.c
similarity index 98%
rename from tools/mesh/node.c
rename to tools/mesh-gatt/node.c
index d23315c..6afa6d6 100644
--- a/tools/mesh/node.c
+++ b/tools/mesh-gatt/node.c
@@ -39,14 +39,16 @@
 #include "src/shared/util.h"
 #include "src/shared/shell.h"
 #include "gdbus/gdbus.h"
-#include "tools/mesh/mesh-net.h"
+
 #include "tools/mesh/config-model.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/gatt.h"
-#include "tools/mesh/net.h"
-#include "tools/mesh/prov-db.h"
-#include "tools/mesh/util.h"
+
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/gatt.h"
+#include "tools/mesh-gatt/net.h"
+#include "tools/mesh-gatt/prov-db.h"
+#include "tools/mesh-gatt/util.h"
 
 struct mesh_model {
 	struct mesh_model_ops cbs;
diff --git a/tools/mesh/node.h b/tools/mesh-gatt/node.h
similarity index 100%
rename from tools/mesh/node.h
rename to tools/mesh-gatt/node.h
diff --git a/tools/mesh/onoff-model.c b/tools/mesh-gatt/onoff-model.c
similarity index 95%
rename from tools/mesh/onoff-model.c
rename to tools/mesh-gatt/onoff-model.c
index b52afe2..92c9a31 100644
--- a/tools/mesh/onoff-model.c
+++ b/tools/mesh-gatt/onoff-model.c
@@ -40,13 +40,14 @@
 
 #include "src/shared/shell.h"
 #include "src/shared/util.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/net.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/prov-db.h"
-#include "tools/mesh/util.h"
-#include "tools/mesh/onoff-model.h"
+
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/prov-db.h"
+#include "tools/mesh-gatt/util.h"
+#include "tools/mesh-gatt/onoff-model.h"
 
 static uint8_t trans_id;
 static uint16_t onoff_app_idx = APP_IDX_INVALID;
diff --git a/tools/mesh/onoff-model.h b/tools/mesh-gatt/onoff-model.h
similarity index 100%
rename from tools/mesh/onoff-model.h
rename to tools/mesh-gatt/onoff-model.h
diff --git a/tools/mesh/prov-db.c b/tools/mesh-gatt/prov-db.c
similarity index 99%
rename from tools/mesh/prov-db.c
rename to tools/mesh-gatt/prov-db.c
index 05b2547..44096e1 100644
--- a/tools/mesh/prov-db.c
+++ b/tools/mesh-gatt/prov-db.c
@@ -42,13 +42,13 @@
 #include "src/shared/util.h"
 #include "src/shared/shell.h"
 
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/crypto.h"
-#include "tools/mesh/keys.h"
-#include "tools/mesh/net.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/util.h"
-#include "tools/mesh/prov-db.h"
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/crypto.h"
+#include "tools/mesh-gatt/keys.h"
+#include "tools/mesh-gatt/net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/util.h"
+#include "tools/mesh-gatt/prov-db.h"
 
 #define CHECK_KEY_IDX_RANGE(x) (((x) >= 0) && ((x) <= 4095))
 
diff --git a/tools/mesh/prov-db.h b/tools/mesh-gatt/prov-db.h
similarity index 100%
rename from tools/mesh/prov-db.h
rename to tools/mesh-gatt/prov-db.h
diff --git a/tools/mesh/prov.c b/tools/mesh-gatt/prov.c
similarity index 96%
rename from tools/mesh/prov.c
rename to tools/mesh-gatt/prov.c
index acbc5a1..0f9d85d 100644
--- a/tools/mesh/prov.c
+++ b/tools/mesh-gatt/prov.c
@@ -41,14 +41,16 @@
 #include "src/shared/shell.h"
 
 #include "gdbus/gdbus.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/gatt.h"
-#include "tools/mesh/crypto.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/util.h"
+
 #include "tools/mesh/agent.h"
-#include "tools/mesh/prov.h"
-#include "tools/mesh/net.h"
+
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/gatt.h"
+#include "tools/mesh-gatt/crypto.h"
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/util.h"
+#include "tools/mesh-gatt/prov.h"
+#include "tools/mesh-gatt/net.h"
 
 /* Provisioning Security Levels */
 #define MESH_PROV_SEC_HIGH	2
diff --git a/tools/mesh/prov.h b/tools/mesh-gatt/prov.h
similarity index 100%
rename from tools/mesh/prov.h
rename to tools/mesh-gatt/prov.h
diff --git a/tools/mesh/prov_db.json b/tools/mesh-gatt/prov_db.json
similarity index 100%
rename from tools/mesh/prov_db.json
rename to tools/mesh-gatt/prov_db.json
diff --git a/tools/mesh/util.c b/tools/mesh-gatt/util.c
similarity index 97%
rename from tools/mesh/util.c
rename to tools/mesh-gatt/util.c
index 47abc0b..564665e 100644
--- a/tools/mesh/util.c
+++ b/tools/mesh-gatt/util.c
@@ -33,9 +33,10 @@
 
 #include "src/shared/shell.h"
 #include "src/shared/util.h"
-#include "tools/mesh/mesh-net.h"
-#include "tools/mesh/node.h"
-#include "tools/mesh/util.h"
+
+#include "tools/mesh-gatt/mesh-net.h"
+#include "tools/mesh-gatt/node.h"
+#include "tools/mesh-gatt/util.h"
 
 void set_menu_prompt(const char *name, const char *id)
 {
diff --git a/tools/mesh/util.h b/tools/mesh-gatt/util.h
similarity index 100%
rename from tools/mesh/util.h
rename to tools/mesh-gatt/util.h
diff --git a/tools/meshctl.c b/tools/meshctl.c
index 6b6f108..57998fd 100644
--- a/tools/meshctl.c
+++ b/tools/meshctl.c
@@ -47,18 +47,20 @@
 #include "src/shared/shell.h"
 #include "src/shared/util.h"
 #include "gdbus/gdbus.h"
-#include "mesh/mesh-net.h"
-#include "mesh/gatt.h"
-#include "mesh/crypto.h"
-#include "mesh/node.h"
-#include "mesh/net.h"
-#include "mesh/keys.h"
-#include "mesh/prov.h"
-#include "mesh/util.h"
+
 #include "mesh/agent.h"
-#include "mesh/prov-db.h"
 #include "mesh/config-model.h"
-#include "mesh/onoff-model.h"
+
+#include "mesh-gatt/mesh-net.h"
+#include "mesh-gatt/gatt.h"
+#include "mesh-gatt/crypto.h"
+#include "mesh-gatt/node.h"
+#include "mesh-gatt/net.h"
+#include "mesh-gatt/keys.h"
+#include "mesh-gatt/prov.h"
+#include "mesh-gatt/util.h"
+#include "mesh-gatt/prov-db.h"
+#include "mesh-gatt/onoff-model.h"
 
 /* String display constants */
 #define COLORED_NEW	COLOR_GREEN "NEW" COLOR_OFF