2018-08-30 22:37:37

by Igor Stoppa

[permalink] [raw]
Subject: [PATCH 10/23] wireless: remove unnecessary unlikely()

WARN_ON_ONCE() already contains an unlikely(), and the logical or of two of
them is still unlikely(), so it's not necessary to wrap them into another.

Signed-off-by: Igor Stoppa <[email protected]>
Cc: Christian Lamparter <[email protected]>
Cc: Kalle Valo <[email protected]>
---
drivers/net/wireless/ath/carl9170/tx.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ath/carl9170/tx.c b/drivers/net/wireless/ath/carl9170/tx.c
index 0cb5b58925dc..8c75651ede6c 100644
--- a/drivers/net/wireless/ath/carl9170/tx.c
+++ b/drivers/net/wireless/ath/carl9170/tx.c
@@ -246,8 +246,8 @@ static void carl9170_release_dev_space(struct ar9170 *ar, struct sk_buff *skb)
* of available memory blocks, so the number can
* never execeed the mem_blocks count.
*/
- if (unlikely(WARN_ON_ONCE(cookie == 0) ||
- WARN_ON_ONCE(cookie > ar->fw.mem_blocks)))
+ if (WARN_ON_ONCE(cookie == 0) ||
+ WARN_ON_ONCE(cookie > ar->fw.mem_blocks))
return;

atomic_add(DIV_ROUND_UP(skb->len, ar->fw.mem_block_size),
--
2.17.1



2018-08-31 10:41:11

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH 10/23] wireless: remove unnecessary unlikely()

+ linux-wireless

Igor Stoppa <[email protected]> writes:

> WARN_ON_ONCE() already contains an unlikely(), and the logical or of two of
> them is still unlikely(), so it's not necessary to wrap them into another.
>
> Signed-off-by: Igor Stoppa <[email protected]>
> Cc: Christian Lamparter <[email protected]>
> Cc: Kalle Valo <[email protected]>

IMHO you could fold patches 10, 11 and 12 into one to avoid having three
patches with duplicate titles. Or alternatively use proper driver
prefixes like "ath10k:", "b43:" and so on.

But how do you want these to be applied? For the wireless patches you
didn't Cc linux-wireless so our patchwork won't see them and hence I
can't take them. So if you want me to take these, please resend and
include linux-wireless.

--
Kalle Valo

2018-08-31 13:47:03

by Igor Stoppa

[permalink] [raw]
Subject: Re: [PATCH 10/23] wireless: remove unnecessary unlikely()



On 31/08/18 12:52, Kalle Valo wrote:
> + linux-wireless

> IMHO you could fold patches 10, 11 and 12 into one to avoid having three
> patches with duplicate titles. Or alternatively use proper driver
> prefixes like "ath10k:", "b43:" and so on.

I was wondering if it would be ok to fold them, but it's easier to fold
than to split, so I started with 3

> But how do you want these to be applied? For the wireless patches you
> didn't Cc linux-wireless so our patchwork won't see them and hence I
> can't take them. So if you want me to take these, please resend and
> include linux-wireless.


ok, I was hoping to avoid joining the ml but it's done
I had patches for about 20 different trees, so I decided to first see if
the patches could be taken in right away.
In at least one case (pinctrl) I got lucky :-)

--
thanks, igor