Wireless Daemon for Linux
 help / color / mirror / Atom feed
From: Denis Kenzior <denkenz@gmail.com>
To: James Prestwood <prestwoj@gmail.com>, iwd@lists.linux.dev
Subject: Re: [PATCH 1/3] hwsim: remove 'optimization' sending to only known MACs
Date: Tue, 27 Jun 2023 13:00:21 -0500	[thread overview]
Message-ID: <280831cf-933a-95b0-3889-ddca6ca544cc@gmail.com> (raw)
In-Reply-To: <3790483a-442f-9602-03c9-b205376d9262@gmail.com>

Hi James,

>> You can try to see whether HWSIM_CMD_ADD_MAC_ADDR works?  See commit 
>> 5cc58a9ecfa1 ("mac80211_hwsim: notify wmediumd of used MAC addresses")
> 
> I hadn't seen that before, but looking at it they don't expose that as an API, 
> its only for internal use for scan address randomization and monitor interfaces 
> (see mac80211_hwsim_config_mac_nl()).
> 

It is used as an unsolicited event / notification.  Yeah I know, HWSIM_CMD_* 
prefix is confusing ;)

It looks like we should start using this since most of our autotests are forced 
to include the following main.conf:

[Scan]
DisableMacAddressRandomization=true

Having support for the above event would allow us to get rid of this hack.

<snip>

>>
>> Hmm, but radios are namespace independent.  They can only be added/removed via 
>> HWSIM_CMD_ADD/DEL_RADIO, no?  Since phys are moved wholesale across namespaces 
>> (you can't only move a given interface), you could assume that once a radio is 
>> created and populated, its interfaces do not change for the duration of the 
>> test, even if they're moved to a different namespace.
> 
> For testing yes this is probably fine. It may require some adaptation in hwsim 
> to do it better from a test-runner perspective. Currently we just use ip to 
> create/delete namespaces and move radios. It may make more sense to add this to 
> hwsim so there is one path. Then at least when hwsim gets a DEL_WIPHY event it 

It shouldn't matter really who invokes the namespace move.  hwsim would know 
whether it is a hot-unplug or a namespace move by virtue of being the one who 
triggers HWSIM_CMD_DEL_RADIO.

> doesn't have to assume the radio was moved (I'm thinking if we ever added 
> hotplug tests this could be important).

We should add these, but the above still stands.  hwsim is the only thing in our 
tests that triggers HWSIM_CMD_ADD_RADIO.

Regards,
-Denis

  reply	other threads:[~2023-06-27 18:02 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-04 21:52 [PATCH 1/3] hwsim: remove 'optimization' sending to only known MACs James Prestwood
2023-05-04 21:52 ` [PATCH 2/3] test-runner: allow hwsim in namespaces James Prestwood
2023-05-04 21:52 ` [PATCH 3/3] test-runner: fix __str__ for namespace processes James Prestwood
2023-05-07 23:21 ` [PATCH 1/3] hwsim: remove 'optimization' sending to only known MACs Denis Kenzior
2023-05-08 13:43   ` James Prestwood
2023-05-08 18:05     ` Denis Kenzior
2023-05-08 18:55       ` James Prestwood
2023-05-08 19:00         ` Denis Kenzior
2023-05-08 19:03         ` James Prestwood
2023-05-08 19:01           ` Denis Kenzior
2023-06-21 21:05             ` James Prestwood
2023-06-27  2:31               ` Denis Kenzior
2023-06-27 15:15                 ` James Prestwood
2023-06-27 18:00                   ` Denis Kenzior [this message]
2023-06-27 18:56                     ` James Prestwood
2023-06-27 19:23                       ` Denis Kenzior
2023-06-27 20:09                     ` James Prestwood
2023-06-28 14:49                       ` Denis Kenzior
2023-06-28 15:33                         ` James Prestwood
2023-06-28 15:40                           ` Denis Kenzior
2023-06-28 16:14                             ` James Prestwood
2023-06-28 16:25                               ` Denis Kenzior
2023-06-28 16:47                                 ` James Prestwood
2023-06-28 16:57                                   ` Denis Kenzior
2023-06-28 17:22                                     ` James Prestwood
2023-06-28 23:19                               ` Andrew Zaborowski
2023-06-28 23:28                                 ` James Prestwood

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=280831cf-933a-95b0-3889-ddca6ca544cc@gmail.com \
    --to=denkenz@gmail.com \
    --cc=iwd@lists.linux.dev \
    --cc=prestwoj@gmail.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox