> +++ b/drivers/net/wireless/intel/iwlegacy/commands.h
> @@ -201,9 +201,6 @@ struct il_cmd_header {
> * 15 unsolicited RX or uCode-originated notification
> */
> __le16 sequence;
> -
> - /* command or response/notification data follows immediately */
> - u8 data[];
> } __packed;
[...]
> - memcpy(&out_cmd->cmd.payload, cmd->data, cmd->len);
> + memcpy(&out_cmd->cmd.raw, cmd->data, cmd->len);
[...]
> +++ b/drivers/net/wireless/intel/iwlegacy/common.h
> @@ -555,6 +555,7 @@ struct il_device_cmd {
> u32 val32;
> struct il_tx_cmd tx;
> u8 payload[DEF_CMD_PAYLOAD_SIZE];
> + DECLARE_FLEX_ARRAY(u8, raw);
>
I don't think this is right, now the raw comes after
DEF_CMD_PAYLOAD_SIZE? You want it to be a union with payload, I'd think.
johannes