public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel•org>
To: Daniel Golle <daniel@makrotopia•org>
Cc: Andrew Lunn <andrew@lunn•ch>, Vladimir Oltean <olteanv@gmail•com>,
	"David S. Miller" <davem@davemloft•net>,
	Eric Dumazet <edumazet@google•com>,
	Paolo Abeni <pabeni@redhat•com>, Rob Herring <robh@kernel•org>,
	Krzysztof Kozlowski <krzk+dt@kernel•org>,
	Conor Dooley <conor+dt@kernel•org>,
	Heiner Kallweit <hkallweit1@gmail•com>,
	Russell King <linux@armlinux•org.uk>,
	Simon Horman <horms@kernel•org>,
	netdev@vger•kernel.org, devicetree@vger•kernel.org,
	linux-kernel@vger•kernel.org, Frank Wunderlich <frankwu@gmx•de>,
	Chad Monroe <chad@monroe•io>,
	Cezary Wilmanski <cezary.wilmanski@adtran•com>,
	Liang Xu <lxu@maxlinear•com>, John Crispin <john@phrozen•org>
Subject: Re: [PATCH net-next v13 4/4] net: dsa: add basic initial driver for MxL862xx switches
Date: Thu, 5 Feb 2026 18:21:17 -0800	[thread overview]
Message-ID: <20260205182117.41618f8d@kernel.org> (raw)
In-Reply-To: <2da8267175bfe7b8ff92d67ba5aa88755fab1710.1770211259.git.daniel@makrotopia.org>

On Wed, 4 Feb 2026 13:33:19 +0000 Daniel Golle wrote:
> +/* The switch firmware expects all structs to be byte-aligned */
> +#pragma pack(push, 1)

"Byte-aligned" means..? Generally aligned means that it starts
at an address which is multiple of X. All addresses are multiple of 1

We used you push back against blanket __packed because it's forcing
all *host* accesses to also assume that the structures are unaligned.
The best practice is to pack only specific structs which need it
and add compile_assert()s to make sure that the compiler doesn't add
any padding.

There's a couple of AI nitpicks, since I'm already complaining I'll
send these out too..

  reply	other threads:[~2026-02-06  2:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-04 13:32 [PATCH net-next v13 0/4] net: dsa: initial support for MaxLinear MxL862xx switches Daniel Golle
2026-02-04 13:32 ` [PATCH net-next v13 1/4] dt-bindings: net: dsa: add MaxLinear MxL862xx Daniel Golle
2026-02-04 13:33 ` [PATCH net-next v13 2/4] net: dsa: add tag format for MxL862xx switches Daniel Golle
2026-02-06  2:21   ` [net-next,v13,2/4] " Jakub Kicinski
2026-02-06  3:30     ` Daniel Golle
2026-02-07  2:46       ` Jakub Kicinski
2026-02-04 13:33 ` [PATCH net-next v13 3/4] net: mdio: add unlocked mdiodev C45 bus accessors Daniel Golle
2026-02-04 13:33 ` [PATCH net-next v13 4/4] net: dsa: add basic initial driver for MxL862xx switches Daniel Golle
2026-02-06  2:21   ` Jakub Kicinski [this message]
2026-02-06  3:14     ` Daniel Golle
2026-02-06 13:34       ` Vladimir Oltean
2026-02-06 16:43         ` Daniel Golle
2026-02-07 22:14           ` Vladimir Oltean
2026-02-07  2:52       ` Jakub Kicinski

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=20260205182117.41618f8d@kernel.org \
    --to=kuba@kernel$(echo .)org \
    --cc=andrew@lunn$(echo .)ch \
    --cc=cezary.wilmanski@adtran$(echo .)com \
    --cc=chad@monroe$(echo .)io \
    --cc=conor+dt@kernel$(echo .)org \
    --cc=daniel@makrotopia$(echo .)org \
    --cc=davem@davemloft$(echo .)net \
    --cc=devicetree@vger$(echo .)kernel.org \
    --cc=edumazet@google$(echo .)com \
    --cc=frankwu@gmx$(echo .)de \
    --cc=hkallweit1@gmail$(echo .)com \
    --cc=horms@kernel$(echo .)org \
    --cc=john@phrozen$(echo .)org \
    --cc=krzk+dt@kernel$(echo .)org \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux@armlinux$(echo .)org.uk \
    --cc=lxu@maxlinear$(echo .)com \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=olteanv@gmail$(echo .)com \
    --cc=pabeni@redhat$(echo .)com \
    --cc=robh@kernel$(echo .)org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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