Skip to contentSkip to conversation

drivers: net: xen-netfront: Simplify the calculation of variables

PATCH Applied Jiapeng Chong 3 participants 3 messages Feb 2, 2021 – Feb 4, 2021

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers: net: xen-netfront: Simplify the calculation of variables

Fix the following coccicheck warnings:

./drivers/net/xen-netfront.c:1816:52-54: WARNING !A || A && B is equivalent to !A || B.

---
 drivers/net/xen-netfront.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/xen-netfront.c +1 -1
index b01848e..5158841 100644
@@ -1813,7 +1813,7 @@ static int setup_netfront(struct xenbus_device *dev,
 	 *  a) feature-split-event-channels == 0
 	 *  b) feature-split-event-channels == 1 but failed to setup
 	 */
-	if (!feature_split_evtchn || (feature_split_evtchn && err))
+	if (!feature_split_evtchn || err)
 		err = setup_netfront_single(queue);
 
 	if (err)
Signature · 1 line
1.8.3.1
#2 lore raw
In reply to Jiapeng Chong
This patch was applied to netdev/net-next.git (refs/heads/master):

Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

Quoted 9 lines · On Tue, 2 Feb 2021 18:17:49 +0800 you wrote:

Fix the following coccicheck warnings:

./drivers/net/xen-netfront.c:1816:52-54: WARNING !A || A && B is equivalent to !A || B.

[...]

Here is the summary with links:
- drivers: net: xen-netfront: Simplify the calculation of variables

    https://git.kernel.org/netdev/net-next/c/e93fac3b5161

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html