[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <878t82r5tr.fsf@weeman.i-did-not-set--mail-host-address--so-tickle-me>
Date: Tue, 29 May 2018 08:42:40 -0400
From: Vivien Didelot <vivien.didelot@...oirfairelinux.com>
To: Petr Machata <petrm@...lanox.com>, netdev@...r.kernel.org,
devel@...verdev.osuosl.org, bridge@...ts.linux-foundation.org
Cc: jiri@...lanox.com, idosch@...lanox.com, davem@...emloft.net,
razvan.stefanescu@....com, gregkh@...uxfoundation.org,
stephen@...workplumber.org, andrew@...n.ch, f.fainelli@...il.com,
nikolay@...ulusnetworks.com
Subject: Re: [PATCH net-next v3 1/7] net: bridge: Extract boilerplate around switchdev_port_obj_*()
Hi Petr,
Petr Machata <petrm@...lanox.com> writes:
> A call to switchdev_port_obj_add() or switchdev_port_obj_del() involves
> initializing a struct switchdev_obj_port_vlan, a piece of code that
> repeats on each call site almost verbatim. While in the current codebase
> there is just one duplicated add call, the follow-up patches add more of
> both add and del calls.
>
> Thus to remove the duplication, extract the repetition into named
> functions and reuse.
>
> Signed-off-by: Petr Machata <petrm@...lanox.com>
Considering Dan's comment as well:
Reviewed-by: Vivien Didelot <vivien.didelot@...oirfairelinux.com>
Thanks,
Vivien
Powered by blists - more mailing lists