[PATCH 00/20] wpa_s: p2p: support nl80211 P2P_DEVICE interface

Johannes Berg johannes
Fri May 24 01:10:38 PDT 2013


On Fri, 2013-05-24 at 10:05 +0200, Arend van Spriel wrote:

> >  From the log it seems you get -EBUSY, which is a bit odd. Are you sure
> > your advertised interface combinations support what you were doing?
> 
> This log was testing with mac80211_hwsim, which has the following:

Oh. I thought it was brcmfmac. With hwsim there shouldn't be an issue.

> static const struct ieee80211_iface_limit hwsim_if_limits[] = {
> 	{ .max = 1, .types = BIT(NL80211_IFTYPE_ADHOC) },
> 	{ .max = 2048,  .types = BIT(NL80211_IFTYPE_STATION) |
> 				 BIT(NL80211_IFTYPE_P2P_CLIENT) |
> #ifdef CONFIG_MAC80211_MESH
> 				 BIT(NL80211_IFTYPE_MESH_POINT) |
> #endif
> 				 BIT(NL80211_IFTYPE_AP) |
> 				 BIT(NL80211_IFTYPE_P2P_GO) },
> 	{ .max = 1, .types = BIT(NL80211_IFTYPE_P2P_DEVICE) },
> };
> 
> static struct ieee80211_iface_combination hwsim_if_comb = {
> 	.limits = hwsim_if_limits,
> 	.n_limits = ARRAY_SIZE(hwsim_if_limits),
> 	.max_interfaces = 2048,
> 	.num_different_channels = 1,
> };
> 
> Crap. num_different_channels should probably be 2 here, right?

No, P2P_DEVICE doesn't use up a channel (in hwsim.) And setting an
interface UP won't consume and require a channel anyway.

johannes




More information about the Hostap mailing list