Re: [PATCH 3/3] sfc: selftest: fix struct packing
From: Edward Cree
Date: Fri Jun 23 2023 - 08:57:46 EST
On 23/06/2023 11:52, David Laight wrote:
> Maybe you can get away with adding a 16bit pad before the ethernet
> header so that the IP header is actually aligned.
That's what I ended up doing, because my original idea was
overcomplicated and turned out super ugly.
See https://lore.kernel.org/netdev/6f87fdf5-1844-4633-b4fe-6b247bc6ab49@xxxxxxxxxxxxxxxx/T/
> (Then fight all the stuff that stops you doing a memcpy()
> that runs into a second field of a structure.)
Yeah, I don't know how you're meant to annotate that stuff.
I guess I'll have to wait until Kees shouts at me and tells
me what to do :S
-ed