linux-x25.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: x25: drop harmless check of !more
@ 2021-12-08  7:20 Jεan Sacren
  2021-12-08  7:51 ` Martin Schiller
  2021-12-10  3:20 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Jεan Sacren @ 2021-12-08  7:20 UTC (permalink / raw)
  To: ms, davem, kuba, linux-x25, netdev

From: Jean Sacren <sakiwit@gmail.com>

'more' is checked first.  When !more is checked immediately after that,
it is always true.  We should drop this check.

Signed-off-by: Jean Sacren <sakiwit@gmail.com>
---
 net/x25/x25_in.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/x25/x25_in.c b/net/x25/x25_in.c
index e1c4197af468..b981a4828d08 100644
--- a/net/x25/x25_in.c
+++ b/net/x25/x25_in.c
@@ -41,7 +41,7 @@ static int x25_queue_rx_frame(struct sock *sk, struct sk_buff *skb, int more)
 		return 0;
 	}
 
-	if (!more && x25->fraglen > 0) {	/* End of fragment */
+	if (x25->fraglen > 0) {	/* End of fragment */
 		int len = x25->fraglen + skb->len;
 
 		if ((skbn = alloc_skb(len, GFP_ATOMIC)) == NULL){

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] net: x25: drop harmless check of !more
  2021-12-08  7:20 [PATCH net-next] net: x25: drop harmless check of !more Jεan Sacren
@ 2021-12-08  7:51 ` Martin Schiller
  2021-12-10  3:20 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Martin Schiller @ 2021-12-08  7:51 UTC (permalink / raw)
  To: Jεan Sacren; +Cc: davem, kuba, linux-x25, netdev

On 2021-12-08 08:20, Jεan Sacren wrote:
> From: Jean Sacren <sakiwit@gmail.com>
> 
> 'more' is checked first.  When !more is checked immediately after that,
> it is always true.  We should drop this check.
> 
> Signed-off-by: Jean Sacren <sakiwit@gmail.com>
> ---
>  net/x25/x25_in.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/x25/x25_in.c b/net/x25/x25_in.c
> index e1c4197af468..b981a4828d08 100644
> --- a/net/x25/x25_in.c
> +++ b/net/x25/x25_in.c
> @@ -41,7 +41,7 @@ static int x25_queue_rx_frame(struct sock *sk,
> struct sk_buff *skb, int more)
>  		return 0;
>  	}
> 
> -	if (!more && x25->fraglen > 0) {	/* End of fragment */
> +	if (x25->fraglen > 0) {	/* End of fragment */
>  		int len = x25->fraglen + skb->len;
> 
>  		if ((skbn = alloc_skb(len, GFP_ATOMIC)) == NULL){

Acked-by: Martin Schiller <ms@dev.tdt.de>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] net: x25: drop harmless check of !more
  2021-12-08  7:20 [PATCH net-next] net: x25: drop harmless check of !more Jεan Sacren
  2021-12-08  7:51 ` Martin Schiller
@ 2021-12-10  3:20 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-12-10  3:20 UTC (permalink / raw)
  To: =?utf-8?q?J=CE=B5an_Sacren_=3Csakiwit=40gmail=2Ecom=3E?=
  Cc: ms, davem, kuba, linux-x25, netdev

Hello:

This patch was applied to netdev/net-next.git (master)
by Jakub Kicinski <kuba@kernel.org>:

On Wed,  8 Dec 2021 00:20:25 -0700 you wrote:
> From: Jean Sacren <sakiwit@gmail.com>
> 
> 'more' is checked first.  When !more is checked immediately after that,
> it is always true.  We should drop this check.
> 
> Signed-off-by: Jean Sacren <sakiwit@gmail.com>
> 
> [...]

Here is the summary with links:
  - [net-next] net: x25: drop harmless check of !more
    https://git.kernel.org/netdev/net-next/c/9745177c9489

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



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-12-10  3:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-08  7:20 [PATCH net-next] net: x25: drop harmless check of !more Jεan Sacren
2021-12-08  7:51 ` Martin Schiller
2021-12-10  3:20 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).