net: switchdev: remove dev from switchdev_obj cb

The net_device associated to a dump operation does not have to be passed
to the callback. switchdev stores it in a superset struct, if needed.

Also some drivers (such as DSA drivers) may not have easy access to it.

This will simplify pushing the callback function down to the drivers.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Vivien Didelot 2015-09-29 12:07:15 -04:00 committed by David S. Miller
parent e02a06b2a7
commit 03d5fb1862
4 changed files with 7 additions and 9 deletions

View file

@ -66,7 +66,7 @@ enum switchdev_obj_id {
struct switchdev_obj {
enum switchdev_obj_id id;
int (*cb)(struct net_device *dev, struct switchdev_obj *obj);
int (*cb)(struct switchdev_obj *obj);
union {
struct switchdev_obj_vlan { /* PORT_VLAN */
u16 flags;