lkml.org 
[lkml]   [2017]   [Nov]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH net-next 1/6] net: dsa: remove trans argument from mdb ops
From
Date
On 08. nov. 2017 18:19, Vivien Didelot wrote:
> The DSA switch MDB ops pass the switchdev_trans structure down to the
> drivers, but no one is using them and they aren't supposed to anyway.
>
> Remove the trans argument from MDB prepare and add operations.
>
> - int (*port_mdb_prepare)(struct dsa_switch *ds, int port,
> - const struct switchdev_obj_port_mdb *mdb,
> - struct switchdev_trans *trans);
> - void (*port_mdb_add)(struct dsa_switch *ds, int port,
> - const struct switchdev_obj_port_mdb *mdb,
> - struct switchdev_trans *trans);
> + int (*port_mdb_prepare)(struct dsa_switch *ds, int port,
> + const struct switchdev_obj_port_mdb *mdb);
> + void (*port_mdb_add)(struct dsa_switch *ds, int port,
> + const struct switchdev_obj_port_mdb *mdb);
> int (*port_mdb_del)(struct dsa_switch *ds, int port,
> const struct switchdev_obj_port_mdb *mdb);

Hi Vivien
Nice to get rid of "trans". I recall I was confused by this parameter.
"Am I supposed to do something with this parameter?".

But when at it. What about getting rid of switchdev_obj_port_mdb, making
similar signatures as the new .port_fdb_xxx functions? Would that make
sense?

Egil

\
 
 \ /
  Last update: 2017-11-09 10:05    [W:0.065 / U:0.288 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site