mbox series

[iproute2-next,0/7] Convert a number of use-cases to parse_on_off(), print_on_off()

Message ID cover.1605393324.git.me@pmachata.org
Headers show
Series Convert a number of use-cases to parse_on_off(), print_on_off() | expand

Message

Petr Machata Nov. 14, 2020, 10:53 p.m. UTC
Two helpers, parse_on_off() and print_on_off(), have been recently added to
lib/utils.c. Convert a number of instances of the same effective behavior
to calls to these helpers.

Petr Machata (7):
  bridge: link: Port over to parse_on_off()
  bridge: link: Convert to use print_on_off()
  ip: iplink: Convert to use parse_on_off()
  ip: iplink_bridge_slave: Port over to parse_on_off()
  ip: iplink_bridge_slave: Convert to use print_on_off()
  ip: ipnetconf: Convert to use print_on_off()
  ip: iptuntap: Convert to use print_on_off()

 bridge/link.c            | 135 ++++++++++++++++++---------------------
 ip/iplink.c              |  47 +++++---------
 ip/iplink_bridge_slave.c |  46 +++++--------
 ip/ipnetconf.c           |  28 ++++----
 ip/iptuntap.c            |  18 ++----
 5 files changed, 112 insertions(+), 162 deletions(-)

Comments

David Ahern Nov. 17, 2020, 12:56 a.m. UTC | #1
On 11/14/20 3:53 PM, Petr Machata wrote:
> Two helpers, parse_on_off() and print_on_off(), have been recently added to
> lib/utils.c. Convert a number of instances of the same effective behavior
> to calls to these helpers.
> 
> Petr Machata (7):
>   bridge: link: Port over to parse_on_off()
>   bridge: link: Convert to use print_on_off()
>   ip: iplink: Convert to use parse_on_off()
>   ip: iplink_bridge_slave: Port over to parse_on_off()
>   ip: iplink_bridge_slave: Convert to use print_on_off()
>   ip: ipnetconf: Convert to use print_on_off()
>   ip: iptuntap: Convert to use print_on_off()
> 
>  bridge/link.c            | 135 ++++++++++++++++++---------------------
>  ip/iplink.c              |  47 +++++---------
>  ip/iplink_bridge_slave.c |  46 +++++--------
>  ip/ipnetconf.c           |  28 ++++----
>  ip/iptuntap.c            |  18 ++----
>  5 files changed, 112 insertions(+), 162 deletions(-)
> 

looks fine to me. Added Nik for a second set of eyes on the bridge changes.
Nikolay Aleksandrov Nov. 23, 2020, 9:21 p.m. UTC | #2
On 17/11/2020 02:56, David Ahern wrote:
> On 11/14/20 3:53 PM, Petr Machata wrote:
>> Two helpers, parse_on_off() and print_on_off(), have been recently added to
>> lib/utils.c. Convert a number of instances of the same effective behavior
>> to calls to these helpers.
>>
>> Petr Machata (7):
>>   bridge: link: Port over to parse_on_off()
>>   bridge: link: Convert to use print_on_off()
>>   ip: iplink: Convert to use parse_on_off()
>>   ip: iplink_bridge_slave: Port over to parse_on_off()
>>   ip: iplink_bridge_slave: Convert to use print_on_off()
>>   ip: ipnetconf: Convert to use print_on_off()
>>   ip: iptuntap: Convert to use print_on_off()
>>
>>  bridge/link.c            | 135 ++++++++++++++++++---------------------
>>  ip/iplink.c              |  47 +++++---------
>>  ip/iplink_bridge_slave.c |  46 +++++--------
>>  ip/ipnetconf.c           |  28 ++++----
>>  ip/iptuntap.c            |  18 ++----
>>  5 files changed, 112 insertions(+), 162 deletions(-)
>>
> 
> looks fine to me. Added Nik for a second set of eyes on the bridge changes.
> 

It's much later, but the changes look good to me. Thanks!

Cheers,
 Nik
David Ahern Nov. 25, 2020, 4:44 a.m. UTC | #3
On 11/14/20 3:53 PM, Petr Machata wrote:
> Two helpers, parse_on_off() and print_on_off(), have been recently added to
> lib/utils.c. Convert a number of instances of the same effective behavior
> to calls to these helpers.
> 

applied to iproute2-next. Thanks, Petr.