{
if (tethering_is_enabled(tethering, TETHERING_TYPE_USB) ||
tethering_is_enabled(tethering, TETHERING_TYPE_WIFI) ||
- tethering_is_enabled(tethering, TETHERING_TYPE_BT))
+ tethering_is_enabled(tethering, TETHERING_TYPE_BT) ||
+ tethering_is_enabled(tethering, TETHERING_TYPE_P2P))
return true;
return false;
type = TETHERING_TYPE_WIFI;
else if (ap_type == MOBILE_AP_TYPE_BT)
type = TETHERING_TYPE_BT;
+ else if (ap_type == MOBILE_AP_TYPE_P2P)
+ type = TETHERING_TYPE_P2P;
else {
ERR("Not supported tethering type [%d]\n", ap_type);
goto DONE;
client.interface = TETHERING_TYPE_WIFI;
else if (interface == MOBILE_AP_TYPE_BT)
client.interface = TETHERING_TYPE_BT;
+ else if (interface == MOBILE_AP_TYPE_P2P)
+ client.interface = TETHERING_TYPE_P2P;
else {
ERR("Invalid interface\n");
g_free(key);
}
/* TETHERING_TYPE_ALL */
- for (ti = TETHERING_TYPE_USB; ti <= TETHERING_TYPE_BT; ti++) {
+ for (ti = TETHERING_TYPE_USB; ti <= TETHERING_TYPE_P2P; ti++) {
th->changed_cb[ti] = callback;
th->changed_user_data[ti] = user_data;
}
}
/* TETHERING_TYPE_ALL */
- for (ti = TETHERING_TYPE_USB; ti <= TETHERING_TYPE_BT; ti++) {
+ for (ti = TETHERING_TYPE_USB; ti <= TETHERING_TYPE_P2P; ti++) {
th->changed_cb[ti] = NULL;
th->changed_user_data[ti] = NULL;
}