[PATCH 2/4] Add new rtnl_link_af_data_compare function to compare af_data

Roopa Prabhu roopa at cumulusnetworks.com
Mon Jan 14 11:01:38 EST 2013


On 1/14/13 12:02 AM, Thomas Graf wrote:
> On 01/13/13 at 03:09pm, Roopa Prabhu wrote:
>> The reason i did not add this check because this api could be used
>> for comparing IFLA_AF_SPEC too. In which case the IFLA_AF_SPEC
>> family might not be same as l_family.
>>
>> Right now link_compare only compares IFLA_PROTINFO. But it could be
>> extended to compare af_data belonging to IFLA_AF_SPEC as well.
>>
>> Let me know what you think.
>
> OK, makes sense.
>
> Please make the API more solid then and document the exact meaning
> of the family parameter. As of now, an invalid family value will
> be used blindly to index the ops array. Checking the return value
> of rtnl_link_af_ops_lookup() would be enough already as it
> enforces>  0&&  <  AF_MAX.
>
ok thanks. Will do. I will re-spin the series.



More information about the libnl mailing list