[PATCH net-next v5 1/3] net: ti: icssg-prueth: Add helper functions to configure FDB

Andrew Lunn andrew at lunn.ch
Mon May 27 15:04:25 PDT 2024


> +struct mgmt_cmd {
> +	u8 param;
> +	u8 seqnum;
> +	u8 type;
> +	u8 header;
> +	u32 cmd_args[3];
> +} __packed;

There is a general dislike for __packed. Since your structures are
naturally well aligned, it is probably not needed. You could be
paranoid and add BUILD_BUG_ON(sizeof(struct mgmt_cmd) != 16);

	 Andrew



More information about the linux-arm-kernel mailing list