2017-09-08 14:16:45

by Benjamin Beichler

[permalink] [raw]
Subject: [RFC 3/4] mac80211_hwsim: explicitly set netlink parallel ops to false

The ops field is zero initialized, therefore parallel ops is already false. This implicates that the netlink callbacks are not
processed in parallel. Maybe this could be utilized to reduce locking overhead or maybe also parallel ops could be implemented.

Signed-off-by: Benjamin Beichler <[email protected]>
---
drivers/net/wireless/mac80211_hwsim.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index 62c5a00a76c3..5dd4be2a8487 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -3499,6 +3499,7 @@ static struct genl_family hwsim_genl_family __ro_after_init = {
.n_ops = ARRAY_SIZE(hwsim_ops),
.mcgrps = hwsim_mcgrps,
.n_mcgrps = ARRAY_SIZE(hwsim_mcgrps),
+ .parallel_ops = false
};

static void destroy_radio(struct work_struct *work)
--
2.14.1


2017-09-08 15:07:47

by Benjamin Beichler

[permalink] [raw]
Subject: Re: [RFC 3/4] mac80211_hwsim: explicitly set netlink parallel ops to false



Am 8=2E September 2017 16:19:20 MESZ schrieb Johannes Berg <johannes@sipso=
lutions=2Enet>:
>On Fri, 2017-09-08 at 16:11 +0200, Benjamin Beichler wrote:
>> The ops field is zero initialized, therefore parallel ops is already
>> false=2E
>
>Therefore this patch is completely pointless?
Sorry my first message was missing regarding this=2E My question is, wheth=
er this is intentionally, and if it is parallel, whether we need extensive =
locking here=2E

>
>johannes

--=20
M=2ESc=2E Benjamin Beichler

Universit=C3=A4t Rostock, Fakult=C3=A4t f=C3=BCr Informatik und Elektrotec=
hnik
Institut f=C3=BCr Angewandte Mikroelektronik und Datentechnik

University of Rostock, Department of CS and EE
Institute of Applied Microelectronics and CE

Richard-Wagner-Stra=C3=9Fe 31
18119 Rostock
Deutschland/Germany

phone: +49 (0) 381 498 - 7278
email: Benjamin=2EBeichler@uni-rostock=2Ede
www: http://www=2Eimd=2Euni-rostock=2Ede/

2017-09-08 14:19:22

by Johannes Berg

[permalink] [raw]
Subject: Re: [RFC 3/4] mac80211_hwsim: explicitly set netlink parallel ops to false

On Fri, 2017-09-08 at 16:11 +0200, Benjamin Beichler wrote:
> The ops field is zero initialized, therefore parallel ops is already
> false.

Therefore this patch is completely pointless?

johannes

2017-09-08 15:11:21

by Johannes Berg

[permalink] [raw]
Subject: Re: [RFC 3/4] mac80211_hwsim: explicitly set netlink parallel ops to false

On Fri, 2017-09-08 at 17:07 +0200, Benjamin Beichler wrote:
>
> Am 8. September 2017 16:19:20 MESZ schrieb Johannes Berg <johannes@si
> psolutions.net>:
> > On Fri, 2017-09-08 at 16:11 +0200, Benjamin Beichler wrote:
> > > The ops field is zero initialized, therefore parallel ops is
> > > already
> > > false.
> >
> > Therefore this patch is completely pointless?
>
> Sorry my first message was missing regarding this. My question is,
> whether this is intentionally, and if it is parallel, whether we need
> extensive locking here.

It's basically intentional - not sure parallel_ops even existed when
this was first written, but we can probably use parallel_ops if we want
to.

johannes