summaryrefslogtreecommitdiffstats
path: root/include/net/dsa.h
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2016-04-13 02:40:39 +0200
committerDavid S. Miller <davem@davemloft.net>2016-04-14 00:15:22 +0200
commitbbb8d793994c894eef2a48a35fac6de3c6b4fa93 (patch)
treeb77344abffc2f441f5a2a17f6a8852df63519e06 /include/net/dsa.h
parentMerge tag 'mac80211-next-for-davem-2016-04-13' of git://git.kernel.org/pub/sc... (diff)
downloadlinux-bbb8d793994c894eef2a48a35fac6de3c6b4fa93.tar.xz
linux-bbb8d793994c894eef2a48a35fac6de3c6b4fa93.zip
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>
Diffstat (limited to 'include/net/dsa.h')
-rw-r--r--include/net/dsa.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/net/dsa.h b/include/net/dsa.h
index 18d1be3ad62d..0f9f6f38f255 100644
--- a/include/net/dsa.h
+++ b/include/net/dsa.h
@@ -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);