public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Oliver Hartkopp <socketcan@hartkopp.net>
Cc: Jakub Kicinski <kuba@kernel.org>,
	netdev@vger.kernel.org, linux-can@vger.kernel.org
Subject: Re: [net-next 0/6] move CAN skb headroom content to skb extensions
Date: Wed, 28 Jan 2026 17:25:48 +0100	[thread overview]
Message-ID: <aXo4jP9M0EQPOaeI@strlen.de> (raw)
In-Reply-To: <e2033d96-e900-4013-a18a-c2e0ffa269d3@hartkopp.net>

Oliver Hartkopp <socketcan@hartkopp.net> wrote:
> Ok. But then I don't see any real pressure to do the extension right 
> now. There doesn't seem so much changes adding new skb extensions users. 
>   And we still have a free slot even if all users would have been 
> enabled (which is not the case due to the mutually exclusive options).

Yes.

> The good thing is that skb extensions are very efficient. Which leads to 
> the bad thing that we only can detect the problems at build time with
> 
> BUILD_BUG_ON(SKB_EXT_NUM > 8);
> BUILD_BUG_ON(skb_ext_total_length() > 255);
> 
> For (SKB_EXT_NUM > 8) the upgrade of active_extensions to u16 should 
> simply make it. Probably with some #ifdef magic only.
> 
> But thinking about BUILD_BUG_ON(skb_ext_total_length() > 255):
> 
> Shouldn't this be SKB_EXT_CHUNKSIZEOF(struct skb_ext) + sum of the skb 
> ext user data which can be up to 255 *  SKB_EXT_ALIGN_VALUE (= 2040) ???

Why?  Its not about the size in bytes, its there to make sure
ext->offset[] (u8) won't overflow for any of the extensions.

Maybe a comment would help.

  reply	other threads:[~2026-01-28 16:25 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-25 20:15 [net-next 0/6] move CAN skb headroom content to skb extensions Oliver Hartkopp
2026-01-25 20:15 ` [net-next 1/6] can: use skb hash instead of private variable in headroom Oliver Hartkopp
2026-01-28  1:45   ` Jakub Kicinski
2026-01-25 20:15 ` [net-next 2/6] can: add CAN skb extension infrastructure Oliver Hartkopp
2026-01-25 20:15 ` [net-next 3/6] can: move ifindex to CAN skb extensions Oliver Hartkopp
2026-01-25 20:15 ` [net-next 4/6] can: move frame_len " Oliver Hartkopp
2026-01-25 20:16 ` [net-next 5/6] can: remove private CAN skb headroom infrastructure Oliver Hartkopp
2026-01-28  1:49 ` [net-next 0/6] move CAN skb headroom content to skb extensions Jakub Kicinski
2026-01-28  8:42   ` Oliver Hartkopp
2026-01-28  9:07     ` Marc Kleine-Budde
2026-01-28 10:04       ` Marc Kleine-Budde
2026-01-28 10:17         ` Oliver Hartkopp
2026-01-29  6:44       ` Marc Kleine-Budde
2026-01-29  7:49         ` Oliver Hartkopp
2026-01-29  8:42           ` Marc Kleine-Budde
2026-01-28 11:35   ` Florian Westphal
2026-01-28 12:52     ` Oliver Hartkopp
2026-01-28 13:18       ` Florian Westphal
2026-01-28 16:14         ` Oliver Hartkopp
2026-01-28 16:25           ` Florian Westphal [this message]
2026-01-28 16:34             ` Oliver Hartkopp

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=aXo4jP9M0EQPOaeI@strlen.de \
    --to=fw@strlen.de \
    --cc=kuba@kernel.org \
    --cc=linux-can@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=socketcan@hartkopp.net \
    /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