From: Nikolay Aleksandrov <nikolay@nvidia.com>
To: "davem@davemloft.net" <davem@davemloft.net>,
"jwi@linux.ibm.com" <jwi@linux.ibm.com>,
"kuba@kernel.org" <kuba@kernel.org>
Cc: "kgraul@linux.ibm.com" <kgraul@linux.ibm.com>,
"hca@linux.ibm.com" <hca@linux.ibm.com>,
"linux-s390@vger.kernel.org" <linux-s390@vger.kernel.org>,
"wintera@linux.ibm.com" <wintera@linux.ibm.com>,
"ubraun@linux.ibm.com" <ubraun@linux.ibm.com>,
"jiri@resnulli.us" <jiri@resnulli.us>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
Roopa Prabhu <roopa@nvidia.com>,
"ivecera@redhat.com" <ivecera@redhat.com>
Subject: Re: [PATCH net-next 5/8] bridge: Add SWITCHDEV_FDB_FLUSH_TO_BRIDGE notifier
Date: Tue, 15 Sep 2020 07:20:14 +0000 [thread overview]
Message-ID: <ea877ec26ab6d552b8e54966446a7cf4d8698d86.camel@nvidia.com> (raw)
In-Reply-To: <20200910172351.5622-6-jwi@linux.ibm.com>
On Thu, 2020-09-10 at 19:23 +0200, Julian Wiedmann wrote:
> From: Alexandra Winter <wintera@linux.ibm.com>
>
> so the switchdev can notifiy the bridge to flush non-permanent fdb entries
> for this port. This is useful whenever the hardware fdb of the switchdev
> is reset, but the netdev and the bridgeport are not deleted.
>
> Note that this has the same effect as the IFLA_BRPORT_FLUSH attribute.
>
> CC: Jiri Pirko <jiri@resnulli.us>
> CC: Ivan Vecera <ivecera@redhat.com>
> CC: Roopa Prabhu <roopa@nvidia.com>
> CC: Nikolay Aleksandrov <nikolay@nvidia.com>
> Signed-off-by: Alexandra Winter <wintera@linux.ibm.com>
> Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
> ---
> include/net/switchdev.h | 1 +
> net/bridge/br.c | 5 +++++
> 2 files changed, 6 insertions(+)
>
> diff --git a/include/net/switchdev.h b/include/net/switchdev.h
> index ff2246914301..53e8b4994296 100644
> --- a/include/net/switchdev.h
> +++ b/include/net/switchdev.h
> @@ -203,6 +203,7 @@ enum switchdev_notifier_type {
> SWITCHDEV_FDB_ADD_TO_DEVICE,
> SWITCHDEV_FDB_DEL_TO_DEVICE,
> SWITCHDEV_FDB_OFFLOADED,
> + SWITCHDEV_FDB_FLUSH_TO_BRIDGE,
>
> SWITCHDEV_PORT_OBJ_ADD, /* Blocking. */
> SWITCHDEV_PORT_OBJ_DEL, /* Blocking. */
> diff --git a/net/bridge/br.c b/net/bridge/br.c
> index b6fe30e3768f..401eeb9142eb 100644
> --- a/net/bridge/br.c
> +++ b/net/bridge/br.c
> @@ -183,6 +183,11 @@ static int br_switchdev_event(struct notifier_block *unused,
> br_fdb_offloaded_set(br, p, fdb_info->addr,
> fdb_info->vid, fdb_info->offloaded);
> break;
> + case SWITCHDEV_FDB_FLUSH_TO_BRIDGE:
> + fdb_info = ptr;
> + /* Don't delete static entries */
> + br_fdb_delete_by_port(br, p, fdb_info->vid, 0);
> + break;
> }
>
> out:
Acked-by: Nikolay Aleksandrov <nikolay@nvidia.com>
next prev parent reply other threads:[~2020-09-15 7:20 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-10 17:23 [PATCH net-next 0/8] s390/qeth: updates 2020-09-10 Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 1/8] s390/cio: Add new Operation Code OC3 to PNSO Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 2/8] s390/cio: Helper functions to read CSSID, IID, and CHID Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 3/8] s390/qeth: Detect PNSO OC3 capability Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 4/8] s390/qeth: Translate address events into switchdev notifiers Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 5/8] bridge: Add SWITCHDEV_FDB_FLUSH_TO_BRIDGE notifier Julian Wiedmann
2020-09-14 21:38 ` David Miller
2020-09-15 7:20 ` Nikolay Aleksandrov [this message]
2020-09-15 8:19 ` Ivan Vecera
2020-09-10 17:23 ` [PATCH net-next 6/8] s390/qeth: Reset address notification in case of buffer overflow Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 7/8] s390/qeth: implement ndo_bridge_getlink for learning_sync Julian Wiedmann
2020-09-10 17:23 ` [PATCH net-next 8/8] s390/qeth: implement ndo_bridge_setlink " Julian Wiedmann
2020-09-15 20:22 ` [PATCH net-next 0/8] s390/qeth: updates 2020-09-10 David Miller
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=ea877ec26ab6d552b8e54966446a7cf4d8698d86.camel@nvidia.com \
--to=nikolay@nvidia.com \
--cc=davem@davemloft.net \
--cc=hca@linux.ibm.com \
--cc=ivecera@redhat.com \
--cc=jiri@resnulli.us \
--cc=jwi@linux.ibm.com \
--cc=kgraul@linux.ibm.com \
--cc=kuba@kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=roopa@nvidia.com \
--cc=ubraun@linux.ibm.com \
--cc=wintera@linux.ibm.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