Message ID | 20120408183646.GC12438@w1.fi |
---|---|
State | Accepted |
Commit | ef35f5a0fd2c41f92a3ecc29995c5de1f407d2af |
Headers | show |
> Cleaned up version below. Though, I would like to see an example > implementation for this in driver_nl80211.c, i.e., we need to get this > functionality reviewed on the linux-wireless mailing list and included > in the upstream kernel. Thanks again!!. I still haven't worked on this front. This is a much required patch for single channel concurrency case. - Jithu * * On Mon, Apr 9, 2012 at 12:06 AM, Jouni Malinen <j@w1.fi> wrote: > On Tue, Mar 06, 2012 at 10:34:12AM +0530, Jithu Jance wrote: > > Single channel concurrency patch [3/4] > > > > Hooks for implementing GO/AP channel switch. To be expanded later. > > Cleaned up version below. Though, I would like to see an example > implementation for this in driver_nl80211.c, i.e., we need to get this > functionality reviewed on the linux-wireless mailing list and included > in the upstream kernel. > > > [PATCH 2/3] P2P: Add driver op for requesting GO/AP channel switch > > Signed-hostap: Jithu Jance <jithu@broadcom.com> > --- > src/drivers/driver.h | 12 ++++++++++++ > wpa_supplicant/driver_i.h | 8 ++++++++ > 2 files changed, 20 insertions(+), 0 deletions(-) > > diff --git a/src/drivers/driver.h b/src/drivers/driver.h > index 329f89a..7ff1b3d 100644 > --- a/src/drivers/driver.h > +++ b/src/drivers/driver.h > @@ -2535,6 +2535,18 @@ struct wpa_driver_ops { > * conditions. > */ > int (*radio_disable)(void *priv, int disabled); > + > + /** > + * switch_channel - Announce channel switch and migrate the GO to > the > + * given frequency > + * @priv: Private driver interface data > + * @freq: Frequency in MHz > + * Returns: 0 on success, -1 on failure > + * > + * This function is used to move the GO to the legacy STA channel > to > + * avoid frequency conflict in single channel concurrency. > + */ > + int (*switch_channel)(void *priv, unsigned int freq); > }; > > > diff --git a/wpa_supplicant/driver_i.h b/wpa_supplicant/driver_i.h > index e1e921d..2ab455b 100644 > --- a/wpa_supplicant/driver_i.h > +++ b/wpa_supplicant/driver_i.h > @@ -672,4 +672,12 @@ static inline int wpa_drv_radio_disable(struct > wpa_supplicant *wpa_s, > return wpa_s->driver->radio_disable(wpa_s->drv_priv, disabled); > } > > +static inline int wpa_drv_switch_channel(struct wpa_supplicant *wpa_s, > + unsigned int freq) > +{ > + if (!wpa_s->driver->switch_channel) > + return -1; > + return wpa_s->driver->switch_channel(wpa_s->drv_priv, freq); > +} > + > #endif /* DRIVER_I_H */ > -- > 1.7.4.1 > > -- > Jouni Malinen PGP id EFC895FA > _______________________________________________ > HostAP mailing list > HostAP@lists.shmoo.com > http://lists.shmoo.com/mailman/listinfo/hostap >
On Mon, Apr 09, 2012 at 12:48:14PM +0530, Jithu Jance wrote: > > Cleaned up version below. Though, I would like to see an example > > implementation for this in driver_nl80211.c, i.e., we need to get this > > functionality reviewed on the linux-wireless mailing list and included > > in the upstream kernel. > Thanks again!!. I still haven't worked on this front. This is a much > required patch for single channel concurrency case. Thanks, applied. Has there been updated on the nl80211 side for this?
> Thanks, applied. Thanks for taking in the change. There is a related patch which is not yet applied. If there is some issue with the patch, Please let me know. http://patchwork.ozlabs.org/patch/154020/ > Has there been updated on the nl80211 side for this? Not yet. :( I was sick and away from work for few weeks. Need to work on this once my backlogs are done with. - Jithu Jance On Sun, Jun 10, 2012 at 11:26 PM, Jouni Malinen <j@w1.fi> wrote: > On Mon, Apr 09, 2012 at 12:48:14PM +0530, Jithu Jance wrote: > > > Cleaned up version below. Though, I would like to see an example > > > implementation for this in driver_nl80211.c, i.e., we need to get this > > > functionality reviewed on the linux-wireless mailing list and included > > > in the upstream kernel. > > Thanks again!!. I still haven't worked on this front. This is a much > > required patch for single channel concurrency case. > > Thanks, applied. Has there been updated on the nl80211 side for this? > > -- > Jouni Malinen PGP id EFC895FA > _______________________________________________ > HostAP mailing list > HostAP@lists.shmoo.com > http://lists.shmoo.com/mailman/listinfo/hostap >
diff --git a/src/drivers/driver.h b/src/drivers/driver.h index 329f89a..7ff1b3d 100644 --- a/src/drivers/driver.h +++ b/src/drivers/driver.h @@ -2535,6 +2535,18 @@ struct wpa_driver_ops { * conditions. */ int (*radio_disable)(void *priv, int disabled); + + /** + * switch_channel - Announce channel switch and migrate the GO to the + * given frequency + * @priv: Private driver interface data + * @freq: Frequency in MHz + * Returns: 0 on success, -1 on failure + * + * This function is used to move the GO to the legacy STA channel to + * avoid frequency conflict in single channel concurrency. + */ + int (*switch_channel)(void *priv, unsigned int freq); }; diff --git a/wpa_supplicant/driver_i.h b/wpa_supplicant/driver_i.h index e1e921d..2ab455b 100644 --- a/wpa_supplicant/driver_i.h +++ b/wpa_supplicant/driver_i.h @@ -672,4 +672,12 @@ static inline int wpa_drv_radio_disable(struct wpa_supplicant *wpa_s, return wpa_s->driver->radio_disable(wpa_s->drv_priv, disabled); } +static inline int wpa_drv_switch_channel(struct wpa_supplicant *wpa_s, + unsigned int freq) +{ + if (!wpa_s->driver->switch_channel) + return -1; + return wpa_s->driver->switch_channel(wpa_s->drv_priv, freq); +} + #endif /* DRIVER_I_H */