lkml.org 
[lkml]   [2023]   [Nov]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH iwl-next v3 3/5] i40e: Add helpers to find VSI and VEB by SEID and use them
From


On 22. 11. 23 0:05, Tony Nguyen wrote:
>
>
> On 11/16/2023 7:21 AM, Ivan Vecera wrote:
>
>> @@ -13197,17 +13193,14 @@ static int i40e_ndo_bridge_getlink(struct
>> sk_buff *skb, u32 pid, u32 seq,
>>       struct i40e_vsi *vsi = np->vsi;
>>       struct i40e_pf *pf = vsi->back;
>>       struct i40e_veb *veb = NULL;
>> -    int i;
>>       /* Only for PF VSI for now */
>>       if (vsi->seid != pf->vsi[pf->lan_vsi]->seid)
>>           return -EOPNOTSUPP;
>>       /* Find the HW bridge for the PF VSI */
>> -    i40e_pf_for_each_veb(pf, i, veb)
>> -        if (veb->seid == vsi->uplink_seid)
>> -            break;
>> -    if (i == I40E_MAX_VEB)
>> +    veb = i40e_pf_get_veb_by_seid(pf, vsi->uplink_seid);
>> +    if (!vsi)
>>           return 0;
>
> In addition to the kdoc stuff that Simon pointed out. Should this null
> check be against veb?
>
Oops, the check should be against veb here not aganst vsi...
Good eyes, Tony. Thanks, I will fix this.

Ivan

\
 
 \ /
  Last update: 2023-11-22 10:59    [W:0.124 / U:0.552 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site