* Checking p2p capabilities
@ 2016-01-19 11:34 albertofanjul
2016-01-19 11:57 ` Johannes Berg
0 siblings, 1 reply; 2+ messages in thread
From: albertofanjul @ 2016-01-19 11:34 UTC (permalink / raw)
To: linux-wireless
Hi, I'm maintainer of https://github.com/albfan/miraclecast and as a project with specific hardware needs, I build a hardware tester, but it is to naive:
https://github.com/albfan/miraclecast/blob/master/res/miracle-utils.sh#L68
basically it look for p2p interface modes grepping iw phy <phyname> info.
Lot of people trying miraclecast ask me:why it's device do not support p2p? (while it's documentation says it does, many times is just what they think, not reality).
I wonder if that is a matter of driver, modules or pure hardware. Is there any way to check it directly and not from a grep inside iw ?.
something like:
iw phy wlp3s0 get P2P-client
iw phy wlp3s0 get P2P-GO
About kernel, modules and hardware, are they completely black box for others?, I mean, can I detect if my device hardware supports some interface but my driver or module can't?
At this point my script informs pretty well, and there's a few people ask such things, but I would like to check it in a better way, even with an api inside my project
Something related with this lines I could check by myself (I use that clone for it's line anchors)
https://github.com/cozybit/iw/blob/master/util.c#L124
https://github.com/cozybit/iw/blob/master/info.c#L276
NL80211_ATTR_SUPPORTED_IFTYPES
NL80211_IFTYPE_MAX
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Checking p2p capabilities
2016-01-19 11:34 Checking p2p capabilities albertofanjul
@ 2016-01-19 11:57 ` Johannes Berg
0 siblings, 0 replies; 2+ messages in thread
From: Johannes Berg @ 2016-01-19 11:57 UTC (permalink / raw)
To: albertofanjul, linux-wireless
On Tue, 2016-01-19 at 12:34 +0100, albertofanjul@gmail.com wrote:
> Lot of people trying miraclecast ask me:why it's device do not
> support p2p? (while it's documentation says it does, many times is
> just what they think, not reality).
Well, often the documentation is for the windows or vendor driver, not
for the upstream driver.
> I wonder if that is a matter of driver, modules or pure hardware. Is
> there any way to check it directly and not from a grep inside iw ?.
>
> something like:
>
> iw phy wlp3s0 get P2P-client
> iw phy wlp3s0 get P2P-GO
I'm not sure it makes sense to add commands to iw for that, but you can
use python or C code to talk to nl80211 directly.
> About kernel, modules and hardware, are they completely black box for
> others?, I mean, can I detect if my device hardware supports some
> interface but my driver or module can't?
No, you can't detect that.
> At this point my script informs pretty well, and there's a few people
> ask such things, but I would like to check it in a better way, even
> with an api inside my project
>
> Something related with this lines I could check by myself (I use that
> clone for it's line anchors)
>
> https://github.com/cozybit/iw/blob/master/util.c#L124
> https://github.com/cozybit/iw/blob/master/info.c#L276
>
> NL80211_ATTR_SUPPORTED_IFTYPES
> NL80211_IFTYPE_MAX
>
Right, you'd do something along these lines to directly speak to
nl80211 and query the supported interface types.
johannes
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-01-19 11:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-19 11:34 Checking p2p capabilities albertofanjul
2016-01-19 11:57 ` Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).