Fix the gcov build error
[platform/core/api/tethering.git] / include / tethering_private.h
index 1f87420..b6a36c2 100644 (file)
@@ -77,6 +77,23 @@ extern "C" {
        } while (0)
 
 /**
+ * To lock and unlock Mutex
+ */
+
+#define TETHERING_LOCK \
+       do { \
+               _tethering_lock(); \
+       } while(0)
+
+#define TETHERING_UNLOCK \
+       do { \
+               _tethering_unlock(); \
+       } while(0)
+
+void _tethering_lock(void);
+void _tethering_unlock(void);
+
+/**
  * To check supported feature
  */
 
@@ -117,6 +134,9 @@ int _tethering_check_feature_supported(const char* feature, ...);
 * Common configuration
 */
 #define TETHERING_STR_INFO_LEN 40      /**< length of the ip or mac address */
+#define TETHERING_IPV4_ADDRESS_MAX_LEN 15      /**< Maximum length of IP address */
+#define TETHERING_IPV4_ADDRESS_MIN_LEN 7       /**< Minimum length of IP address */
+
 
 /**
 * Mobile AP error code
@@ -174,6 +194,8 @@ typedef enum {
        E_SIGNAL_NET_CLOSED = 0,
        E_SIGNAL_WIFI_TETHER_ON,
        E_SIGNAL_WIFI_TETHER_OFF,
+       E_SIGNAL_P2P_TETHER_ON,
+       E_SIGNAL_P2P_TETHER_OFF,
        E_SIGNAL_USB_TETHER_ON,
        E_SIGNAL_USB_TETHER_OFF,
        E_SIGNAL_BT_TETHER_ON,
@@ -200,6 +222,8 @@ typedef enum {
 #define SIGNAL_NAME_STA_DISCONNECT     "sta_disconnected"
 #define SIGNAL_NAME_WIFI_TETHER_ON     "wifi_on"
 #define SIGNAL_NAME_WIFI_TETHER_OFF    "wifi_off"
+#define SIGNAL_NAME_P2P_TETHER_ON   "p2p_on"
+#define SIGNAL_NAME_P2P_TETHER_OFF  "p2p_off"
 #define SIGNAL_NAME_USB_TETHER_ON      "usb_on"
 #define SIGNAL_NAME_USB_TETHER_OFF     "usb_off"
 #define SIGNAL_NAME_BT_TETHER_ON       "bluetooth_on"
@@ -295,6 +319,7 @@ typedef struct {
        char passphrase[TETHERING_WIFI_KEY_MAX_LEN + 1];
        tethering_wifi_security_type_e sec_type;
        tethering_wifi_mode_type_e mode_type;
+       char ip_address[TETHERING_IPV4_ADDRESS_MAX_LEN + 1];
        bool visibility;
        bool mac_filter;
        bool port_forwarding;
@@ -327,6 +352,7 @@ typedef struct {
        char ssid[TETHERING_WIFI_SSID_MAX_LEN + 1];
        char key[TETHERING_WIFI_KEY_MAX_LEN + 1];
        char mode[TETHERING_WIFI_MODE_MAX_LEN + 1];
+       char ip_address[TETHERING_IPV4_ADDRESS_MAX_LEN + 1];
        tethering_wifi_security_type_e sec_type;
        bool visibility;
        bool mac_filter;
@@ -335,10 +361,6 @@ typedef struct {
        unsigned int txpower;
 } _softap_settings_t;
 
-typedef struct {
-       bool flag;
-} tethering_request_table_t;
-
 void _tethering_add_handle(tethering_h handle);
 void _tethering_remove_handle(tethering_h handle);
 bool _tethering_check_handle(tethering_h handle);