Re: [OpenWrt-Devel] Multiple virtual wireless interfaces - mix adhoc and ap mode?

2013-06-25 Thread Conor O'Gorman
On Tue, 2013-06-25 at 00:20 -0400, jonsm...@gmail.com wrote:
 Can this be made to work on Ralink? When I have the adhoc0 interface
 up bringing up ap0 says interface busy.
 

Ralink is not good for supporting this type of setup. I had tried AP and
client mode, and after some hacking it sort-of worked.

From my notes:
ifconfig: SIOCSIFFLAGS: Device or resource busy. Looking at the output
of 'iw list' the valid interface combinations only listed AP and mesh
mode, not Station/Managed mode. On further investigation, none of the
Ralink chips are fully supporting AP+Sta mode. After forcing the driver
to report that it can support the combination, I was able to configure
both interfaces as desired. The hack gives the following combination
output:
Pre:
valid interface combinations:
 * #{ AP, mesh point } = 8,
   total = 8, #channels = 1
Post:
valid interface combinations:
 * #{ managed, AP, mesh point } = 8,
   total = 8, #channels = 1

You may wish to force add 'adhoc' (P2P?) mode, and see how far it gets
you. This was on an RT28xx USB device, so you may have more success on
others.

Hack (for test) looked like:

--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -1264,7 +1264,7 @@ static inline void rt2x00lib_set_if_comb
 */
if_limit = rt2x00dev-if_limits_ap;
if_limit-max = rt2x00dev-ops-max_ap_intf;
-   if_limit-types = BIT(NL80211_IFTYPE_AP);
+   if_limit-types = BIT(NL80211_IFTYPE_STATION) | BIT(NL80211_IFTYPE_AP);
 #ifdef CONFIG_MAC80211_MESH
if_limit-types |= BIT(NL80211_IFTYPE_MESH_POINT);
 #endif

A nice Atheros (AR9330) shows good support for combinations:

valid interface combinations:
 * #{ managed, WDS, P2P-client } = 2048, #{ IBSS, AP, mesh 
point, P2P-GO } = 8,
   total = 2048, #channels = 1


Conor

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Multiple virtual wireless interfaces - mix adhoc and ap mode?

2013-06-25 Thread jonsm...@gmail.com
On Tue, Jun 25, 2013 at 8:25 AM, Conor O'Gorman i...@conorogorman.net wrote:
 On Tue, 2013-06-25 at 00:20 -0400, jonsm...@gmail.com wrote:
 Can this be made to work on Ralink? When I have the adhoc0 interface
 up bringing up ap0 says interface busy.


 Ralink is not good for supporting this type of setup. I had tried AP and
 client mode, and after some hacking it sort-of worked.

Maybe I asked the wrong question

I want to run a mesh like batman. The examples on the batman site
should it being run in adhoc mode. Can I instead run it in mesh mode?

root@OpenWrt:/etc/config# iw list
Wiphy phy0
..

valid interface combinations:
* #{ AP, mesh point } = 8,
  total = 8, #channels = 1




--
Jon Smirl
jonsm...@gmail.com
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Multiple virtual wireless interfaces - mix adhoc and ap mode?

2013-06-25 Thread Gui Iribarren

On 06/25/2013 11:09 AM, jonsm...@gmail.com wrote:

On Tue, Jun 25, 2013 at 8:25 AM, Conor O'Gorman i...@conorogorman.net wrote:

On Tue, 2013-06-25 at 00:20 -0400, jonsm...@gmail.com wrote:

Can this be made to work on Ralink? When I have the adhoc0 interface
up bringing up ap0 says interface busy.



Ralink is not good for supporting this type of setup. I had tried AP and
client mode, and after some hacking it sort-of worked.


Maybe I asked the wrong question

I want to run a mesh like batman. The examples on the batman site
should it being run in adhoc mode. Can I instead run it in mesh mode?

root@OpenWrt:/etc/config# iw list
Wiphy phy0
..

valid interface combinations:
* #{ AP, mesh point } = 8,
   total = 8, #channels = 1


Nope, mesh mode in this context refers to 802.11s which implements a 
mesh network in a lower layer than batman-adv,
already providing a layer2 link-local domain between all participating 
nodes.

running batman-adv over that is redundant and probably troublesome

so: choose between batman-adv over adhoc interfaces,
*or* use plain mesh mode interfaces.

If you're deploying this today, in a non-experimental scenario, you 
probably want to go the batman-adv way (and drop ralink :P); open11s is 
a younger project and while i'm impressed by the development pace, still 
lacks some key features (IMHO) like multi-interface support :(


Cheers!

gui
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Multiple virtual wireless interfaces - mix adhoc and ap mode?

2013-06-25 Thread jonsm...@gmail.com
So how do you want batman-adv and allow normal clients to attach?
Maybe I should give 11S a try.

I loaded OpenWRT onto my AR9331 hardware  It doesn't support mixing
adhoc (IBSS) and AP mode either.

valid interface combinations:
* #{ managed, WDS, P2P-client } = 2048, #{ AP, mesh point, P2P-GO }
= 8, #{ IBSS } = 1,
  total = 2048, #channels = 1, STA/AP BI must match
* #{ AP } = 1,
  total = 1, #channels = 1, STA/AP BI must match, radar detect
widths: { 20 MHz (no HT), 20 MHz }

--
Jon Smirl
jonsm...@gmail.com
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] Multiple virtual wireless interfaces - mix adhoc and ap mode?

2013-06-24 Thread jonsm...@gmail.com
Can this be made to work on Ralink? When I have the adhoc0 interface
up bringing up ap0 says interface busy.

Does it work on Atheros?

root@OpenWrt:/etc/config#
root@OpenWrt:/etc/config# ifconfig ap0 up
ifconfig: SIOCSIFFLAGS: Device or resource busy
root@OpenWrt:/etc/config#
root@OpenWrt:/etc/config# ifconfig adhoc0 down
[ 2510.51] batman_adv: bat0: Interface deactivated: adhoc0
root@OpenWrt:/etc/config# ifconfig ap0 up
[ 2518.35] IPv6: ADDRCONF(NETDEV_UP): ap0: link is not ready
root@OpenWrt:/etc/config# ifconfig ap0 up
root@OpenWrt:/etc/config# ifconfig adhoc0 up
ifconfig: SIOCSIFFLAGS: Device or resource busy
root@OpenWrt:/etc/config#


config wifi-device radio0
option type mac80211
option channel  11
option hwmode 11ng
option path '1018.wmac'
option htmode HT20
list ht_capab GF
list ht_capab SHORT-GI-20
list ht_capab SHORT-GI-40
list ht_capab RX-STBC1

config wifi-iface
option device 'radio0'
option ifname 'ap0'
option network 'lan'
option mode 'ap'
option ssid 'Smirl secure'
option encryption 'psk2'

config wifi-iface
option device 'radio0'
option ifname 'ap1'
option ssid 'Smirl open'
option network 'hotspot'
option mode 'ap'
option encryption 'none'
option isolate '1'

config wifi-iface
option device 'radio0'
option ifname 'adhoc0'
option network 'mesh'
option mode 'adhoc'
option ssid 'mesh'
option bssid '02:CA:FE:CA:CA:40'

--
Jon Smirl
jonsm...@gmail.com
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel