Cumulative patch from commit f3ff948753ebe5643b5c2d16546a4d16e2c9d20a
f3ff948 P2P: Add NFC_HANDOVER commands to p2p_redir list
efd11c0 Add reassociate command to dbus doxygen
481e66b Fix reassociate dbus method
2150c33 wpa_cli: Fix wrong comparison in wpa_cli_cmd_interface
83c4cb5 nl80211: Handle multiple interface combinations for P2P
0133591 HS 2.0 SPP server: Fix aaa_trust_root_cert_url example to use DER
0e0e1e5 P2P: Add retry mechanism for GO Negotiation Confirmation
8235f89 P2P: Mark the scan in p2p_in_invitation as p2p_probe
9392c9b nl80211: Use LEAVE_IBSS with driver-based-SME
38ce8e2 Android: Add qca-vendor.h to be exported
Change-Id: I34771c58e2de5e0a3133326d4b3171341ac07b17
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
diff --git a/wpa_supplicant/Android.mk b/wpa_supplicant/Android.mk
index a60a26a..c8fe1c2 100644
--- a/wpa_supplicant/Android.mk
+++ b/wpa_supplicant/Android.mk
@@ -1617,4 +1617,5 @@
LOCAL_SHARED_LIBRARIES := libcutils liblog
LOCAL_COPY_HEADERS_TO := libwpa_client
LOCAL_COPY_HEADERS := src/common/wpa_ctrl.h
+LOCAL_COPY_HEADERS += src/common/qca-vendor.h
include $(BUILD_SHARED_LIBRARY)
diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c
index f50154e..01be089 100644
--- a/wpa_supplicant/ctrl_iface.c
+++ b/wpa_supplicant/ctrl_iface.c
@@ -6843,6 +6843,9 @@
"P2P_PRESENCE_REQ ",
"P2P_EXT_LISTEN ",
"P2P_REMOVE_CLIENT ",
+ "NFC_GET_HANDOVER_SEL ",
+ "NFC_GET_HANDOVER_REQ ",
+ "NFC_REPORT_HANDOVER ",
NULL
};
int found = 0;
diff --git a/wpa_supplicant/dbus/dbus_new.h b/wpa_supplicant/dbus/dbus_new.h
index 61c480a..7aee923 100644
--- a/wpa_supplicant/dbus/dbus_new.h
+++ b/wpa_supplicant/dbus/dbus_new.h
@@ -91,6 +91,8 @@
#define WPAS_DBUS_ERROR_IFACE_EXISTS \
WPAS_DBUS_NEW_INTERFACE ".InterfaceExists"
+#define WPAS_DBUS_ERROR_IFACE_DISABLED \
+ WPAS_DBUS_NEW_INTERFACE ".InterfaceDisabled"
#define WPAS_DBUS_ERROR_IFACE_UNKNOWN \
WPAS_DBUS_NEW_INTERFACE ".InterfaceUnknown"
diff --git a/wpa_supplicant/dbus/dbus_new_handlers.c b/wpa_supplicant/dbus/dbus_new_handlers.c
index 5466d16..ffa59b2 100644
--- a/wpa_supplicant/dbus/dbus_new_handlers.c
+++ b/wpa_supplicant/dbus/dbus_new_handlers.c
@@ -1465,10 +1465,10 @@
/**
- * wpas_dbus_handler_reassociate - Reassociate to current AP
+ * wpas_dbus_handler_reassociate - Reassociate
* @message: Pointer to incoming dbus message
* @wpa_s: wpa_supplicant structure for a network interface
- * Returns: NotConnected DBus error message if not connected
+ * Returns: InterfaceDisabled DBus error message if disabled
* or NULL otherwise.
*
* Handler function for "Reassociate" method call of network interface.
@@ -1476,13 +1476,13 @@
DBusMessage * wpas_dbus_handler_reassociate(DBusMessage *message,
struct wpa_supplicant *wpa_s)
{
- if (wpa_s->current_ssid != NULL) {
+ if (wpa_s->wpa_state != WPA_INTERFACE_DISABLED) {
wpas_request_connection(wpa_s);
return NULL;
}
- return dbus_message_new_error(message, WPAS_DBUS_ERROR_NOT_CONNECTED,
- "This interface is not connected");
+ return dbus_message_new_error(message, WPAS_DBUS_ERROR_IFACE_DISABLED,
+ "This interface is disabled");
}
diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
index 1d4e6e5..bc0daeb 100644
--- a/wpa_supplicant/scan.c
+++ b/wpa_supplicant/scan.c
@@ -870,7 +870,7 @@
}
#ifdef CONFIG_P2P
- if (wpa_s->p2p_in_provisioning ||
+ if (wpa_s->p2p_in_provisioning || wpa_s->p2p_in_invitation ||
(wpa_s->show_group_started && wpa_s->go_params)) {
/*
* The interface may not yet be in P2P mode, so we have to
diff --git a/wpa_supplicant/wpa_cli.c b/wpa_supplicant/wpa_cli.c
index 28e186e..77c5295 100644
--- a/wpa_supplicant/wpa_cli.c
+++ b/wpa_supplicant/wpa_cli.c
@@ -1552,7 +1552,7 @@
os_free(ctrl_ifname);
ctrl_ifname = os_strdup(argv[0]);
- if (wpa_cli_open_connection(ctrl_ifname, 1)) {
+ if (wpa_cli_open_connection(ctrl_ifname, 1) == 0) {
printf("Connected to interface '%s.\n", ctrl_ifname);
} else {
printf("Could not connect to interface '%s' - re-trying\n",