[PATCH net v3] net: airoha: Add missing filed to ppe_mbox_data struct

Jacob Keller jacob.e.keller at intel.com
Wed Apr 23 09:34:49 PDT 2025



On 4/23/2025 4:20 AM, Lorenzo Bianconi wrote:

>> One oddity here is that the structure is not marked __packed. This
>> addition of a u8 means there will be a 3-byte gap on platforms which
>> have a 4-byte integer... It feels very weird these are ints and not s32
>> or something to fully clarify the sizes.
> 
> yes, you are right. Let's hold on for a while with this patch and let me ask
> Airoha folks if we can "pack" the struct in the NPU firmware binary so we can use
> __packed attribute here. In any case I will use "u32" instead of "int" in the next
> version.
>> Regards,
> Lorenzo
> 

Sure. Also, if firmware already has this layout fixed, you could add the
3 padding bytes marked as reserved to make it more obvious they exist
without needing to remember the rules for how the members will align.

Thanks,
Jake

>>
>> Regardless, assuming the correctness that the unofficial firmware is
>> only available to developers and isn't widely available:
>>
>> Reviewed-by: Jacob Keller <jacob.e.keller at intel.com>
>>
>>> ---
>>> base-commit: c03a49f3093a4903c8a93c8b5c9a297b5343b169
>>> change-id: 20250422-airoha-en7581-fix-ppe_mbox_data-56df12d4df72
>>>
>>> Best regards,
>>




More information about the Linux-mediatek mailing list