[RFC 04/10] nl80211_driver: add P2P device to is_p2p_interface()

Arend van Spriel arend
Mon Feb 11 03:35:37 PST 2013


On 02/11/2013 12:15 PM, Arend van Spriel wrote:
> From: David Spinadel <david.spinadel at intel.com>
> 
> Signed-hostap: David Spinadel <david.spinadel at intel.com>
> ---
>  src/drivers/driver_nl80211.c |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c
> index 670eedc..4d6e0a8 100644
> --- a/src/drivers/driver_nl80211.c
> +++ b/src/drivers/driver_nl80211.c
> @@ -365,7 +365,8 @@ static int is_sta_interface(enum nl80211_iftype nlmode)
>  static int is_p2p_interface(enum nl80211_iftype nlmode)
>  {
>  	return (nlmode == NL80211_IFTYPE_P2P_CLIENT ||
> -		nlmode == NL80211_IFTYPE_P2P_GO);
> +		nlmode == NL80211_IFTYPE_P2P_GO ||
> +		nlmode == NL80211_IFTYPE_P2P_DEVICE);

Not sure if this is the way to go. The function is primarily used to
determine whether 11b rates should be disabled. For P2P clients and
group owners that is the same, but not for P2P device.

Maybe this function should be renamed towards its use.

>  }
>  
>  
> 





More information about the Hostap mailing list