Fix the gcov build error
[platform/core/api/tethering.git] / include / tethering_private.h
index 06b3268..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
  */
 
@@ -116,8 +133,10 @@ int _tethering_check_feature_supported(const char* feature, ...);
 /**
 * Common configuration
 */
-#define TETHERING_TYPE_MAX             5       /**< All, USB, Wi-Fi, BT, Wi-Fi AP */
 #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
@@ -175,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,
@@ -201,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"
@@ -296,11 +319,13 @@ 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;
        bool port_filtering;
        bool dhcp_enabled;
+       bool wifi_sharing;
        int channel;
        int wifi_max_connected;
        unsigned int txpower;
@@ -312,6 +337,7 @@ typedef struct {
        char mac[TETHERING_STR_INFO_LEN];               /**< MAC Address */
        char *hostname;
        time_t tm;      /**< connection time */
+       tethering_band_e band;                  /**< wifi band type */
 } __tethering_client_h;
 
 typedef struct {
@@ -326,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;