net: dsa: Pass the dsa device to the switch drivers
By passing a device structure to the switch devices, it allows them to use devm_* methods for resource management. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
71bbe25d01
commit
bbb8d79399
@@ -212,7 +212,8 @@ struct dsa_switch_driver {
|
||||
/*
|
||||
* Probing and setup.
|
||||
*/
|
||||
char *(*probe)(struct device *host_dev, int sw_addr);
|
||||
char *(*probe)(struct device *dsa_dev, struct device *host_dev,
|
||||
int sw_addr);
|
||||
int (*setup)(struct dsa_switch *ds);
|
||||
int (*set_addr)(struct dsa_switch *ds, u8 *addr);
|
||||
u32 (*get_phy_flags)(struct dsa_switch *ds, int port);
|
||||
|
Reference in New Issue
Block a user