All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Greear <greearb@candelatech.com>
To: Andrew Zaborowski <andrew.zaborowski@intel.com>
Cc: Johannes Berg <johannes@sipsolutions.net>,
	linux-wireless@vger.kernel.org
Subject: Re: [PATCH 2/2][RFC] mac80211_hwsim: Report radio addresses in NEW_RADIO/GET_RADIO
Date: Mon, 27 Feb 2017 17:57:34 -0800	[thread overview]
Message-ID: <4549b209-df6c-0eaa-65e6-72562c61bf4b@candelatech.com> (raw)
In-Reply-To: <CAOq732+MZt=mytXrZko0uw=EsBWvQpZ49wg3CxFPVn0uGGNyog@mail.gmail.com>



On 02/27/2017 05:23 PM, Andrew Zaborowski wrote:
> Hi,
>
> On 27 February 2017 at 18:10, Ben Greear <greearb@candelatech.com> wrote:
>> On 02/27/2017 07:26 AM, Andrew Zaborowski wrote:
>>> As it turns out it can be read from /sys, but I do need it so I can
>>> know what to put in HWSIM_ATTR_ADDR_RECEIVER based on the destination
>>> addr in the frame or if I want to forward the frame to all radios.  Or
>>> is there another way to know that?
>>>
>>>>
>>>> I'd actually prefer to *only* have the wiphy index, and I don't really
>>>> see a problem with moving the wiphy_idx from struct
>>>> cfg80211_registered_device to struct wiphy.
>>>
>>>
>>> Ok, I'll try that.  get_wiphy_idx can stay in place, not sure if I
>>> should just drop it.
>>>
>>> By having *only* the wiphy index you don't mean dropping the radio
>>> names altogether?  The don't seem useful but userspace may expect
>>> them.
>>
>>
>> I find the name and addr more useful than an 'index', because if you
>> remove/add
>> a virtual phy, then the index will probably change, even if name and MAC
>
> I don't think you can remove/add a phy without removing the hwsim
> radio.  A hwsim radio is tied to some wiphy at all times.

You can specify the MAC address and name (ie, wiphy0) when creating a hwsim radio.
You cannot specify the index.  So, from a user-space perspective,
I think the name and MAC is more important than the index.

Anyway, I think you are correct to pay attention to the MAC address and use
that as the identifying key.

Thanks,
Ben


-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

  reply	other threads:[~2017-02-28  1:58 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-23 12:02 [PATCH 1/2] mac80211_hwsim: Make sure NEW_RADIO contains final name Andrew Zaborowski
2017-02-23 12:02 ` [PATCH 2/2][RFC] mac80211_hwsim: Report radio addresses in NEW_RADIO/GET_RADIO Andrew Zaborowski
2017-02-23 19:01   ` Benjamin Beichler
2017-02-24  0:02     ` Andrew Zaborowski
2017-02-24  0:25       ` Ben Greear
2017-02-27 13:27   ` Johannes Berg
2017-02-27 15:26     ` Andrew Zaborowski
2017-02-27 17:10       ` Ben Greear
2017-02-28  1:23         ` Andrew Zaborowski
2017-02-28  1:57           ` Ben Greear [this message]
2017-03-01 14:33             ` Benjamin Beichler
2017-03-01 15:35               ` Ben Greear
2017-03-01 17:04                 ` Benjamin Beichler
2017-03-02  8:23                   ` Johannes Berg
2017-02-24  0:08 ` [PATCH 1/2] mac80211_hwsim: Make sure NEW_RADIO contains final name Andrew Zaborowski
2017-02-27 13:24   ` Johannes Berg
2017-02-27 15:16     ` Andrew Zaborowski
2017-02-27 16:08       ` Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4549b209-df6c-0eaa-65e6-72562c61bf4b@candelatech.com \
    --to=greearb@candelatech.com \
    --cc=andrew.zaborowski@intel.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.