On 5/5/19 11:22 PM, Florian Fainelli wrote:
> 
> 
> On 5/5/2019 2:15 PM, Hauke Mehrtens wrote:
>> This adds functions to add and remove static entries to and from the
>> forwarding database and dump the full forwarding database.
>>
>> Signed-off-by: Hauke Mehrtens <ha...@hauke-m.de>
>> ---
> 
> [snip]
> 
>> +    mac_bridge.table = 0x0b;
>> +    mac_bridge.key_mode = true;
>> +    mac_bridge.key[0] = addr[5] | (addr[4] << 8);
>> +    mac_bridge.key[1] = addr[3] | (addr[2] << 8);
>> +    mac_bridge.key[2] = addr[1] | (addr[0] << 8);
>> +    mac_bridge.key[3] = fid;
>> +    mac_bridge.val[0] = add ? BIT(port) : 0; /* port map */
>> +    mac_bridge.val[1] = 0x01; /* static entry */
> 
> Could you add a define for that bit?

Done, I am also using this in the fast age function now.
The table ID (0x0b) now also uses the define.

> [snip]
>> +            addr[0] = (mac_bridge.key[2] >> 8) & 0xff;
>> +            if (mac_bridge.val[1] & 0x01) {
> 
> And use it here as well? The rest looks fine to me, so if you fix that:
> 
> Reviewed-by: Florian Fainelli <f.faine...@gmail.com>
> 

Reply via email to