aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/main.c
diff options
context:
space:
mode:
authorIlan Peer <ilan.peer@intel.com>2013-09-02 12:41:00 (GMT)
committerJouni Malinen <j@w1.fi>2014-03-06 22:11:04 (GMT)
commitc16a7590cfe76d5895ac70ef711e5b0b384f7aa6 (patch)
treecec002332e62b6f8f5ed1e638444e98b17da899f /wpa_supplicant/main.c
parent185677b74c9287fb3698dcf7cea61b8595d9fb1d (diff)
downloadhostap-c16a7590cfe76d5895ac70ef711e5b0b384f7aa6.zip
hostap-c16a7590cfe76d5895ac70ef711e5b0b384f7aa6.tar.gz
hostap-c16a7590cfe76d5895ac70ef711e5b0b384f7aa6.tar.bz2
wpa_supplicant: Add a configuration file for the P2P_DEVICE parameters
Add an option to specify a configuration file that can be used to hold the P2P_DEVICE configuration parameters. If this option is not used, the P2P_DEVICE configuration parameters will be read from interface configuration file. Note that it is advised to use this option in some cases such as: If a P2P_DEVICE is supported by the driver, the wpa_supplicant creates a dedicated P2P Device interface, where the configuration file used for the main interface is used. As a consequence, if the configuration file includes network definition etc., the wpa_supplicant will try to perform station specific flows on the P2P Device interface which will fail. If a P2P_DEVICE is supported by the driver and update_config is used, the P2P Device configuration data will override the main interface configuration data. Signed-hostap: Ilan Peer <ilan.peer@intel.com>
Diffstat (limited to 'wpa_supplicant/main.c')
-rw-r--r--wpa_supplicant/main.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/wpa_supplicant/main.c b/wpa_supplicant/main.c
index d56935d..d2e839d 100644
--- a/wpa_supplicant/main.c
+++ b/wpa_supplicant/main.c
@@ -43,6 +43,9 @@ static void usage(void)
" [-o<override driver>] [-O<override ctrl>] \\\n"
" [-N -i<ifname> -c<conf> [-C<ctrl>] "
"[-D<driver>] \\\n"
+#ifdef CONFIG_P2P
+ " [-m<P2P Device config file>] \\\n"
+#endif /* CONFIG_P2P */
" [-p<driver_param>] [-b<br_ifname>] [-I<config file>] "
"...]\n"
"\n"
@@ -92,6 +95,9 @@ static void usage(void)
#endif /* CONFIG_DBUS */
printf(" -v = show version\n"
" -W = wait for a control interface monitor before starting\n"
+#ifdef CONFIG_P2P
+ " -m = Configuration file for the P2P Device interface\n"
+#endif /* CONFIG_P2P */
" -N = start describing new interface\n");
printf("example:\n"
@@ -169,7 +175,7 @@ int main(int argc, char *argv[])
for (;;) {
c = getopt(argc, argv,
- "b:Bc:C:D:de:f:g:G:hi:I:KLNo:O:p:P:qsTtuvW");
+ "b:Bc:C:D:de:f:g:G:hi:I:KLm:No:O:p:P:qsTtuvW");
if (c < 0)
break;
switch (c) {
@@ -229,6 +235,11 @@ int main(int argc, char *argv[])
license();
exitcode = 0;
goto out;
+#ifdef CONFIG_P2P
+ case 'm':
+ iface->conf_p2p_dev = optarg;
+ break;
+#endif /* CONFIG_P2P */
case 'o':
params.override_driver = optarg;
break;