From d3bd0f057c8550619a19c08a5dc367b09f7b3e85 Mon Sep 17 00:00:00 2001 From: Jithu Jance Date: Sun, 8 Apr 2012 20:44:05 +0300 Subject: [PATCH] nl80211: Extend shared_freq to handle AP/GO mode interfaces Signed-hostap: Jithu Jance --- src/drivers/driver_nl80211.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 1ceca542b..d7bc32cc5 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -8449,7 +8449,10 @@ static int wpa_driver_nl80211_shared_freq(void *priv) MACSTR, driver->phyname, driver->first_bss.ifname, MAC2STR(driver->first_bss.addr)); - freq = nl80211_get_assoc_freq(driver); + if (is_ap_interface(driver->nlmode)) + freq = driver->first_bss.freq; + else + freq = nl80211_get_assoc_freq(driver); wpa_printf(MSG_DEBUG, "nl80211: Shared freq for PHY %s: %d", drv->phyname, freq); }