The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Martin Schiller <ms@dev.tdt.de>
To: benquike@gmail.com
Cc: andrew+netdev@lunn.ch, davem@davemloft.net, edumazet@google.com,
	kuba@kernel.org, pabeni@redhat.com, linux-x25@vger.kernel.org,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: wan: lapbether: validate frame length and headroom in lapbeth_rcv() and xmit
Date: Mon, 23 Nov 2026 19:27:20 +0100 (CET)	[thread overview]
Message-ID: <c16e43680ec701ef94f3f40499fc345a@dev.tdt.de> (raw)
In-Reply-To: <178994368506.2160803.16241878291781749602@kernel.org>

On Mon, 21 Sep 2026 00:34:45 +0200, netdev-bot wrote:
> - [High] The commit message describes two changes that are not present in
>   the diff.
> - [High] In lapbeth_rcv() (drivers/net/wan/lapbether.c:135-142) the wire-
>   supplied 2-byte length `len = skb->data[0] + skb->data[1] * 256;` is…

I agree with the review. The useful part of the change is the switch
from skb_trim() to pskb_trim_rcsum(): skb_trim() warns and does not
trim at all if the received skb is nonlinear. That is what the commit
message should describe.

Hui, for a v2 for net, as a new thread with [PATCH net v2] in the
subject, please:

- describe the actual change and its effect;
- drop frames whose length field is larger than the received data,
  as the subject promises;
- count skb->len after the trim instead of the length field;
- drop the Assisted-by: line, as for the lapb_decode() patch.

Charging the receive counters to the Ethernet device instead of the
LAPB device is a separate issue and can be a separate patch.

If you don't have time for these two patches, let me know and I'll
take them over.

      reply	other threads:[~2026-11-23 18:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-19 22:34 [PATCH] net: wan: lapbether: validate frame length and headroom in lapbeth_rcv() and xmit Hui Peng
2026-09-20 22:34 ` netdev-bot+sashiko
2026-11-23 18:27   ` Martin Schiller [this message]

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=c16e43680ec701ef94f3f40499fc345a@dev.tdt.de \
    --to=ms@dev.tdt.de \
    --cc=andrew+netdev@lunn.ch \
    --cc=benquike@gmail.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-x25@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.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