Re: [PATCH] staging: vt665x: fix alignment constraints

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 11, 2021 at 11:43 PM Edmundo Carmona Antoranz
<eantoranz@xxxxxxxxx> wrote:
>
> The root cause seems to be that _because_ struct ieee80211_cts is marked as __aligned(2),
> this requires any encapsulating struct to also have an alignment of 2.
>

To make sure of this, I played with an empty struct.

struct a {} __packed __aligned(2);

struct structb {
    struct a blah;
} __packed; <--- got a warning about alignment not being 2.

I would guess that setting the encapsulating struct to be __aligned(4)
or higher would also work fine, don't know if I should be more
thorough in that regard in the patch comment.



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux