diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2002-04-03 21:52:09 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2002-04-03 21:52:09 +0000 |
commit | 3d849e55779f6f4166ff8c851145a1c5ce3b98ae (patch) | |
tree | ace967e8ab2cdcd9c701d727615d12e74cad341d /sys/dev/ic/if_wi.c | |
parent | 09b9d0a4cb9f7def0f47dd190c977dbb608132a5 (diff) |
In Host-AP mode, set IBSS SSID to the normal network id. This makes
"ifconfig nwid FOO" work correctly in Host-AP mode.
Diffstat (limited to 'sys/dev/ic/if_wi.c')
-rw-r--r-- | sys/dev/ic/if_wi.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/sys/dev/ic/if_wi.c b/sys/dev/ic/if_wi.c index eb3f5748e83..13c296f881c 100644 --- a/sys/dev/ic/if_wi.c +++ b/sys/dev/ic/if_wi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_wi.c,v 1.42 2002/04/02 21:47:26 markus Exp $ */ +/* $OpenBSD: if_wi.c,v 1.43 2002/04/03 21:52:08 millert Exp $ */ /* * Copyright (c) 1997, 1998, 1999 @@ -124,7 +124,7 @@ u_int32_t widebug = WIDEBUG; #if !defined(lint) && !defined(__OpenBSD__) static const char rcsid[] = - "$OpenBSD: if_wi.c,v 1.42 2002/04/02 21:47:26 markus Exp $"; + "$OpenBSD: if_wi.c,v 1.43 2002/04/03 21:52:08 millert Exp $"; #endif /* lint */ #ifdef foo @@ -1435,12 +1435,15 @@ wi_init(xsc) /* Roaming type */ WI_SETVAL(WI_RID_ROAMING_MODE, sc->wi_roaming); - /* Specify the IBSS name */ - WI_SETSTR(WI_RID_OWN_SSID, sc->wi_ibss_name); - /* Specify the network name */ WI_SETSTR(WI_RID_DESIRED_SSID, sc->wi_net_name); + /* Specify the IBSS name */ + if (sc->wi_ptype == WI_PORTTYPE_AP) + WI_SETSTR(WI_RID_OWN_SSID, sc->wi_net_name); + else + WI_SETSTR(WI_RID_OWN_SSID, sc->wi_ibss_name); + /* Specify the frequency to use */ WI_SETVAL(WI_RID_OWN_CHNL, sc->wi_channel); |