Commit e49bad31 authored by Andrew Lunn's avatar Andrew Lunn Committed by David S. Miller

net: dsa: Rename DSA probe function.

Rename the function called from the DSA to perform a probe for the
switch. This makes the normal _probe() name available for a standard
Linux device driver probe function.
Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
Tested-by: default avatarVivien Didelot <vivien.didelot@savoirfairelinux.com>
Acked-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a77d43f1
...@@ -135,8 +135,9 @@ static int bcm_sf2_sw_get_sset_count(struct dsa_switch *ds) ...@@ -135,8 +135,9 @@ static int bcm_sf2_sw_get_sset_count(struct dsa_switch *ds)
return BCM_SF2_STATS_SIZE; return BCM_SF2_STATS_SIZE;
} }
static char *bcm_sf2_sw_probe(struct device *dsa_dev, struct device *host_dev, static char *bcm_sf2_sw_drv_probe(struct device *dsa_dev,
int sw_addr, void **_priv) struct device *host_dev,
int sw_addr, void **_priv)
{ {
struct bcm_sf2_priv *priv; struct bcm_sf2_priv *priv;
...@@ -1370,7 +1371,7 @@ static int bcm_sf2_sw_set_wol(struct dsa_switch *ds, int port, ...@@ -1370,7 +1371,7 @@ static int bcm_sf2_sw_set_wol(struct dsa_switch *ds, int port,
static struct dsa_switch_driver bcm_sf2_switch_driver = { static struct dsa_switch_driver bcm_sf2_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_BRCM, .tag_protocol = DSA_TAG_PROTO_BRCM,
.probe = bcm_sf2_sw_probe, .probe = bcm_sf2_sw_drv_probe,
.setup = bcm_sf2_sw_setup, .setup = bcm_sf2_sw_setup,
.set_addr = bcm_sf2_sw_set_addr, .set_addr = bcm_sf2_sw_set_addr,
.get_phy_flags = bcm_sf2_sw_get_phy_flags, .get_phy_flags = bcm_sf2_sw_get_phy_flags,
......
...@@ -69,8 +69,9 @@ static char *mv88e6060_get_name(struct mii_bus *bus, int sw_addr) ...@@ -69,8 +69,9 @@ static char *mv88e6060_get_name(struct mii_bus *bus, int sw_addr)
return NULL; return NULL;
} }
static char *mv88e6060_probe(struct device *dsa_dev, struct device *host_dev, static char *mv88e6060_drv_probe(struct device *dsa_dev,
int sw_addr, void **_priv) struct device *host_dev,
int sw_addr, void **_priv)
{ {
struct mii_bus *bus = dsa_host_dev_to_mii_bus(host_dev); struct mii_bus *bus = dsa_host_dev_to_mii_bus(host_dev);
struct mv88e6060_priv *priv; struct mv88e6060_priv *priv;
...@@ -248,7 +249,7 @@ mv88e6060_phy_write(struct dsa_switch *ds, int port, int regnum, u16 val) ...@@ -248,7 +249,7 @@ mv88e6060_phy_write(struct dsa_switch *ds, int port, int regnum, u16 val)
static struct dsa_switch_driver mv88e6060_switch_driver = { static struct dsa_switch_driver mv88e6060_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_TRAILER, .tag_protocol = DSA_TAG_PROTO_TRAILER,
.probe = mv88e6060_probe, .probe = mv88e6060_drv_probe,
.setup = mv88e6060_setup, .setup = mv88e6060_setup,
.set_addr = mv88e6060_set_addr, .set_addr = mv88e6060_set_addr,
.phy_read = mv88e6060_phy_read, .phy_read = mv88e6060_phy_read,
......
...@@ -29,8 +29,9 @@ static const struct mv88e6xxx_switch_id mv88e6123_table[] = { ...@@ -29,8 +29,9 @@ static const struct mv88e6xxx_switch_id mv88e6123_table[] = {
{ PORT_SWITCH_ID_6165_A2, "Marvell 88e6165 (A2)" }, { PORT_SWITCH_ID_6165_A2, "Marvell 88e6165 (A2)" },
}; };
static char *mv88e6123_probe(struct device *dsa_dev, struct device *host_dev, static char *mv88e6123_drv_probe(struct device *dsa_dev,
int sw_addr, void **priv) struct device *host_dev,
int sw_addr, void **priv)
{ {
return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv, return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv,
mv88e6123_table, mv88e6123_table,
...@@ -106,7 +107,7 @@ static int mv88e6123_setup(struct dsa_switch *ds) ...@@ -106,7 +107,7 @@ static int mv88e6123_setup(struct dsa_switch *ds)
struct dsa_switch_driver mv88e6123_switch_driver = { struct dsa_switch_driver mv88e6123_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_EDSA, .tag_protocol = DSA_TAG_PROTO_EDSA,
.probe = mv88e6123_probe, .probe = mv88e6123_drv_probe,
.setup = mv88e6123_setup, .setup = mv88e6123_setup,
.set_addr = mv88e6xxx_set_addr_indirect, .set_addr = mv88e6xxx_set_addr_indirect,
.phy_read = mv88e6xxx_phy_read, .phy_read = mv88e6xxx_phy_read,
......
...@@ -25,8 +25,9 @@ static const struct mv88e6xxx_switch_id mv88e6131_table[] = { ...@@ -25,8 +25,9 @@ static const struct mv88e6xxx_switch_id mv88e6131_table[] = {
{ PORT_SWITCH_ID_6185, "Marvell 88E6185" }, { PORT_SWITCH_ID_6185, "Marvell 88E6185" },
}; };
static char *mv88e6131_probe(struct device *dsa_dev, struct device *host_dev, static char *mv88e6131_drv_probe(struct device *dsa_dev,
int sw_addr, void **priv) struct device *host_dev,
int sw_addr, void **priv)
{ {
return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv, return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv,
mv88e6131_table, mv88e6131_table,
...@@ -163,7 +164,7 @@ mv88e6131_phy_write(struct dsa_switch *ds, ...@@ -163,7 +164,7 @@ mv88e6131_phy_write(struct dsa_switch *ds,
struct dsa_switch_driver mv88e6131_switch_driver = { struct dsa_switch_driver mv88e6131_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_DSA, .tag_protocol = DSA_TAG_PROTO_DSA,
.probe = mv88e6131_probe, .probe = mv88e6131_drv_probe,
.setup = mv88e6131_setup, .setup = mv88e6131_setup,
.set_addr = mv88e6xxx_set_addr_direct, .set_addr = mv88e6xxx_set_addr_direct,
.phy_read = mv88e6131_phy_read, .phy_read = mv88e6131_phy_read,
......
...@@ -24,8 +24,9 @@ static const struct mv88e6xxx_switch_id mv88e6171_table[] = { ...@@ -24,8 +24,9 @@ static const struct mv88e6xxx_switch_id mv88e6171_table[] = {
{ PORT_SWITCH_ID_6351, "Marvell 88E6351" }, { PORT_SWITCH_ID_6351, "Marvell 88E6351" },
}; };
static char *mv88e6171_probe(struct device *dsa_dev, struct device *host_dev, static char *mv88e6171_drv_probe(struct device *dsa_dev,
int sw_addr, void **priv) struct device *host_dev,
int sw_addr, void **priv)
{ {
return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv, return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv,
mv88e6171_table, mv88e6171_table,
...@@ -92,7 +93,7 @@ static int mv88e6171_setup(struct dsa_switch *ds) ...@@ -92,7 +93,7 @@ static int mv88e6171_setup(struct dsa_switch *ds)
struct dsa_switch_driver mv88e6171_switch_driver = { struct dsa_switch_driver mv88e6171_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_EDSA, .tag_protocol = DSA_TAG_PROTO_EDSA,
.probe = mv88e6171_probe, .probe = mv88e6171_drv_probe,
.setup = mv88e6171_setup, .setup = mv88e6171_setup,
.set_addr = mv88e6xxx_set_addr_indirect, .set_addr = mv88e6xxx_set_addr_indirect,
.phy_read = mv88e6xxx_phy_read_indirect, .phy_read = mv88e6xxx_phy_read_indirect,
......
...@@ -37,8 +37,9 @@ static const struct mv88e6xxx_switch_id mv88e6352_table[] = { ...@@ -37,8 +37,9 @@ static const struct mv88e6xxx_switch_id mv88e6352_table[] = {
{ PORT_SWITCH_ID_6352_A1, "Marvell 88E6352 (A1)" }, { PORT_SWITCH_ID_6352_A1, "Marvell 88E6352 (A1)" },
}; };
static char *mv88e6352_probe(struct device *dsa_dev, struct device *host_dev, static char *mv88e6352_drv_probe(struct device *dsa_dev,
int sw_addr, void **priv) struct device *host_dev,
int sw_addr, void **priv)
{ {
return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv, return mv88e6xxx_drv_probe(dsa_dev, host_dev, sw_addr, priv,
mv88e6352_table, mv88e6352_table,
...@@ -306,7 +307,7 @@ static int mv88e6352_set_eeprom(struct dsa_switch *ds, ...@@ -306,7 +307,7 @@ static int mv88e6352_set_eeprom(struct dsa_switch *ds,
struct dsa_switch_driver mv88e6352_switch_driver = { struct dsa_switch_driver mv88e6352_switch_driver = {
.tag_protocol = DSA_TAG_PROTO_EDSA, .tag_protocol = DSA_TAG_PROTO_EDSA,
.probe = mv88e6352_probe, .probe = mv88e6352_drv_probe,
.setup = mv88e6352_setup, .setup = mv88e6352_setup,
.set_addr = mv88e6xxx_set_addr_indirect, .set_addr = mv88e6xxx_set_addr_indirect,
.phy_read = mv88e6xxx_phy_read_indirect, .phy_read = mv88e6xxx_phy_read_indirect,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment