Thanks Bart. How about we change the current utp_upiu_query_v4_0 to
struct utp_upiu_query_v4_0 {
__u8 opcode;
__u8 idn;
__u8 index;
__u8 selector;
__u8 cmd_specifics[8];
/* private: */
__be32 reserved;
};
Depending on the opcode/transaction, the cmd_specifics[] can be type casted to access the LENGTH, FLAG_VALUE, VALUE[0:63] fields of the QUERY UPIU. The __u8 array[8] would also prevent the compiler padding to the data.