On 10/30/25 6:19 AM, Paolo Abeni wrote:
> On 10/27/25 6:39 PM, Daniel Jurgens wrote:
>> When probing a virtnet device, attempt to read the flow filter
>> capabilities. In order to use the feature the caps must also
>> be set. For now setting what was read is sufficient.
>>
>> Signed-off-by: Daniel Jurgens <[email protected]>
>> Reviewed-by: Parav Pandit <[email protected]>
>> Reviewed-by: Shahar Shitrit <[email protected]>
>> ---
>> +err_ff_action:
>> + kfree(ff->ff_actions);
>> +err_ff_mask:
>> + kfree(ff->ff_mask);
>> +err_ff:
>> + kfree(ff->ff_caps);
>> +err_cap_list:
>> + kfree(cap_id_list);
>
> Minor nit: AFAICS the ff->ff_{caps,mask,actions} pointers can be left !=
> NULL even after free. That should not cause issue at cleanup time, as
> double free is protected by/avoided with 'ff_supported'.
>
> Still it could foul kmemleak check. I think it would be better to either
> clear such fields here or set such fields only on success (and work with
> local variable up to that point).
>
> Not a blocker anyway.
>
> /P
>
I can do that. Thanks for reviewing.