* iproute2: using .maxattr = IFLA_VLAN_MAX??
@ 2017-01-23 17:44 Murali Karicheri
2017-01-23 20:45 ` Rosen, Rami
0 siblings, 1 reply; 3+ messages in thread
From: Murali Karicheri @ 2017-01-23 17:44 UTC (permalink / raw)
To: open list:TI NETCP ETHERNET DRIVER
Hi iproute2 experts,
Found the below usage of IFLA_VLAN_MAX in ip/iplink_hsr.c
struct link_util hsr_link_util = {
.id = "hsr",
.maxattr = IFLA_VLAN_MAX, <==== should be IFLA_HSR_MAX
.parse_opt = hsr_parse_opt,
.print_opt = hsr_print_opt,
.print_help = hsr_print_help,
};
This appears to be a cut-n-paste bug as the source is based on
ip/iplink_vlan.c and should be fixed to IFLA_HSR_MAX. If yes,
I will send a patch for this.
Thanks.
--
Murali Karicheri
Linux Kernel, Keystone
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: iproute2: using .maxattr = IFLA_VLAN_MAX??
2017-01-23 17:44 iproute2: using .maxattr = IFLA_VLAN_MAX?? Murali Karicheri
@ 2017-01-23 20:45 ` Rosen, Rami
2017-01-26 16:27 ` Murali Karicheri
0 siblings, 1 reply; 3+ messages in thread
From: Rosen, Rami @ 2017-01-23 20:45 UTC (permalink / raw)
To: Murali Karicheri, open list:TI NETCP ETHERNET DRIVER
Hi, Murali,
> This appears to be a cut-n-paste bug as the source is based on ip/iplink_vlan.c and should be fixed to IFLA_HSR_MAX.
You are right.
The "HSR section" indeed defines IFLA_HSR_MAX in include/linux/if_link.h of iproute2 as the max attributes number.
And in the top of ip/iplink_hsr.c you will find this comment, which enhances your assumption about the origin of this mistake:
/*
...
Based on iplink_vlan.c by Patrick McHardy <kaber@trash.net
...
*/
Regards,
Rami Rosen
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: iproute2: using .maxattr = IFLA_VLAN_MAX??
2017-01-23 20:45 ` Rosen, Rami
@ 2017-01-26 16:27 ` Murali Karicheri
0 siblings, 0 replies; 3+ messages in thread
From: Murali Karicheri @ 2017-01-26 16:27 UTC (permalink / raw)
To: Rosen, Rami, open list:TI NETCP ETHERNET DRIVER
On 01/23/2017 03:45 PM, Rosen, Rami wrote:
> Hi, Murali,
>
>> This appears to be a cut-n-paste bug as the source is based on ip/iplink_vlan.c and should be fixed to IFLA_HSR_MAX.
>
> You are right.
> The "HSR section" indeed defines IFLA_HSR_MAX in include/linux/if_link.h of iproute2 as the max attributes number.
>
> And in the top of ip/iplink_hsr.c you will find this comment, which enhances your assumption about the origin of this mistake:
>
> /*
> ...
> Based on iplink_vlan.c by Patrick McHardy <kaber@trash.net
> ...
> */
>
> Regards,
> Rami Rosen
>
Hi, Rami,
Thanks for confirming. I will send out a patch for fixing this when I get a chance to
test hsr for my work in the next few days.
--
Murali Karicheri
Linux Kernel, Keystone
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-01-26 16:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-23 17:44 iproute2: using .maxattr = IFLA_VLAN_MAX?? Murali Karicheri
2017-01-23 20:45 ` Rosen, Rami
2017-01-26 16:27 ` Murali Karicheri
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.