netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arkadi Sharshevsky <arkadis@mellanox.com>
To: netdev@vger.kernel.org
Cc: davem@davemloft.net, jiri@resnulli.us, ivecera@redhat.com,
	f.fainelli@gmail.com, andrew@lunn.ch,
	vivien.didelot@savoirfairelinux.com, Woojung.Huh@microchip.com,
	stephen@networkplumber.org, mlxsw@mellanox.com,
	Arkadi Sharshevsky <arkadis@mellanox.com>
Subject: [PATCH net-next v2 09/13] net: dsa: Remove support for MDB dump from DSA's drivers
Date: Wed, 19 Jul 2017 19:04:50 +0300	[thread overview]
Message-ID: <1500480294-10604-10-git-send-email-arkadis@mellanox.com> (raw)
In-Reply-To: <1500480294-10604-1-git-send-email-arkadis@mellanox.com>

This is done as a preparation before removing support for MDB dump from
DSA core. The MDBs are synced with the bridge and thus there is no
need for special dump operation support.

Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com>
---
 drivers/net/dsa/microchip/ksz_common.c |  9 ---------
 drivers/net/dsa/mv88e6xxx/chip.c       | 24 ------------------------
 2 files changed, 33 deletions(-)

diff --git a/drivers/net/dsa/microchip/ksz_common.c b/drivers/net/dsa/microchip/ksz_common.c
index a53ce59..4de9d90 100644
--- a/drivers/net/dsa/microchip/ksz_common.c
+++ b/drivers/net/dsa/microchip/ksz_common.c
@@ -1020,14 +1020,6 @@ static int ksz_port_mdb_del(struct dsa_switch *ds, int port,
 	return ret;
 }
 
-static int ksz_port_mdb_dump(struct dsa_switch *ds, int port,
-			     struct switchdev_obj_port_mdb *mdb,
-			     switchdev_obj_dump_cb_t *cb)
-{
-	/* this is not called by switch layer */
-	return 0;
-}
-
 static int ksz_port_mirror_add(struct dsa_switch *ds, int port,
 			       struct dsa_mall_mirror_tc_entry *mirror,
 			       bool ingress)
@@ -1090,7 +1082,6 @@ static const struct dsa_switch_ops ksz_switch_ops = {
 	.port_mdb_prepare       = ksz_port_mdb_prepare,
 	.port_mdb_add           = ksz_port_mdb_add,
 	.port_mdb_del           = ksz_port_mdb_del,
-	.port_mdb_dump          = ksz_port_mdb_dump,
 	.port_mirror_add	= ksz_port_mirror_add,
 	.port_mirror_del	= ksz_port_mirror_del,
 };
diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
index 9cc6269..97b77b9 100644
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
@@ -1443,15 +1443,6 @@ static int mv88e6xxx_port_db_dump_fid(struct mv88e6xxx_chip *chip,
 				fdb->ndm_state = NUD_NOARP;
 			else
 				fdb->ndm_state = NUD_REACHABLE;
-		} else if (obj->id == SWITCHDEV_OBJ_ID_PORT_MDB) {
-			struct switchdev_obj_port_mdb *mdb;
-
-			if (!is_multicast_ether_addr(addr.mac))
-				continue;
-
-			mdb = SWITCHDEV_OBJ_PORT_MDB(obj);
-			mdb->vid = vid;
-			ether_addr_copy(mdb->addr, addr.mac);
 		} else {
 			return -EOPNOTSUPP;
 		}
@@ -3762,20 +3753,6 @@ static int mv88e6xxx_port_mdb_del(struct dsa_switch *ds, int port,
 	return err;
 }
 
-static int mv88e6xxx_port_mdb_dump(struct dsa_switch *ds, int port,
-				   struct switchdev_obj_port_mdb *mdb,
-				   switchdev_obj_dump_cb_t *cb)
-{
-	struct mv88e6xxx_chip *chip = ds->priv;
-	int err;
-
-	mutex_lock(&chip->reg_lock);
-	err = mv88e6xxx_port_db_dump(chip, port, &mdb->obj, cb);
-	mutex_unlock(&chip->reg_lock);
-
-	return err;
-}
-
 static const struct dsa_switch_ops mv88e6xxx_switch_ops = {
 	.probe			= mv88e6xxx_drv_probe,
 	.get_tag_protocol	= mv88e6xxx_get_tag_protocol,
@@ -3809,7 +3786,6 @@ static const struct dsa_switch_ops mv88e6xxx_switch_ops = {
 	.port_mdb_prepare       = mv88e6xxx_port_mdb_prepare,
 	.port_mdb_add           = mv88e6xxx_port_mdb_add,
 	.port_mdb_del           = mv88e6xxx_port_mdb_del,
-	.port_mdb_dump          = mv88e6xxx_port_mdb_dump,
 	.crosschip_bridge_join	= mv88e6xxx_crosschip_bridge_join,
 	.crosschip_bridge_leave	= mv88e6xxx_crosschip_bridge_leave,
 };
-- 
2.4.11

  parent reply	other threads:[~2017-07-19 16:01 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-19 16:04 [PATCH net-next v2 00/13] Change DSA's FDB API and perform switchdev cleanup Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 01/13] net: dsa: Change DSA slave FDB API to be switchdev independent Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 02/13] net: dsa: Remove prepare phase for FDB Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 03/13] net: dsa: Remove switchdev dependency from DSA switch notifier chain Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 04/13] net: dsa: Add support for learning FDB through notification Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 05/13] net: dsa: Remove support for FDB add/del via SELF Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 06/13] net: dsa: Add support for querying supported bridge flags Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 07/13] net: dsa: Remove support for vlan dump from DSA's drivers Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 08/13] net: dsa: Remove support for bypass bridge port attributes/vlan set Arkadi Sharshevsky
2017-07-19 16:04 ` Arkadi Sharshevsky [this message]
2017-07-19 16:04 ` [PATCH net-next v2 10/13] net: dsa: Remove redundant MDB dump support Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 11/13] net: dsa: Move FDB dump implementation inside DSA Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 12/13] net: bridge: Remove FDB deletion through switchdev object Arkadi Sharshevsky
2017-07-19 16:04 ` [PATCH net-next v2 13/13] net: switchdev: Remove bridge bypass support from switchdev Arkadi Sharshevsky
2017-07-19 20:17 ` [PATCH net-next v2 00/13] Change DSA's FDB API and perform switchdev cleanup Vivien Didelot
2017-07-20  9:04   ` Arkadi Sharshevsky
2017-07-20 16:26     ` Vivien Didelot
2017-07-23 15:00       ` Arkadi Sharshevsky
2017-08-03 22:39         ` Arkadi Sharshevsky
2017-08-04  5:23           ` Jiri Pirko
2017-08-04 15:29             ` Vivien Didelot
2017-08-06 13:07               ` Arkadi Sharshevsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1500480294-10604-10-git-send-email-arkadis@mellanox.com \
    --to=arkadis@mellanox.com \
    --cc=Woojung.Huh@microchip.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=ivecera@redhat.com \
    --cc=jiri@resnulli.us \
    --cc=mlxsw@mellanox.com \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    --cc=vivien.didelot@savoirfairelinux.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).