* [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Florian Fainelli
@ 2019-02-11 21:17 ` Florian Fainelli
2019-02-12 8:55 ` Jiri Pirko
2019-02-12 12:18 ` Ido Schimmel
2019-02-11 21:17 ` [PATCH net-next 2/3] rocker: " Florian Fainelli
` (3 subsequent siblings)
4 siblings, 2 replies; 13+ messages in thread
From: Florian Fainelli @ 2019-02-11 21:17 UTC (permalink / raw)
To: netdev
Cc: Florian Fainelli, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
There is no code that will query the SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
attribute remove support for that.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
.../mellanox/mlxsw/spectrum_switchdev.c | 17 -----------------
1 file changed, 17 deletions(-)
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c
index 95e37de3e48f..4c5780f8f4b2 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c
@@ -431,19 +431,6 @@ static void mlxsw_sp_bridge_vlan_put(struct mlxsw_sp_bridge_vlan *bridge_vlan)
mlxsw_sp_bridge_vlan_destroy(bridge_vlan);
}
-static void mlxsw_sp_port_bridge_flags_get(struct mlxsw_sp_bridge *bridge,
- struct net_device *dev,
- unsigned long *brport_flags)
-{
- struct mlxsw_sp_bridge_port *bridge_port;
-
- bridge_port = mlxsw_sp_bridge_port_find(bridge, dev);
- if (WARN_ON(!bridge_port))
- return;
-
- memcpy(brport_flags, &bridge_port->flags, sizeof(*brport_flags));
-}
-
static int mlxsw_sp_port_attr_get(struct net_device *dev,
struct switchdev_attr *attr)
{
@@ -451,10 +438,6 @@ static int mlxsw_sp_port_attr_get(struct net_device *dev,
struct mlxsw_sp *mlxsw_sp = mlxsw_sp_port->mlxsw_sp;
switch (attr->id) {
- case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS:
- mlxsw_sp_port_bridge_flags_get(mlxsw_sp->bridge, attr->orig_dev,
- &attr->u.brport_flags);
- break;
case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS_SUPPORT:
attr->u.brport_flags_support = BR_LEARNING | BR_FLOOD |
BR_MCAST_FLOOD;
--
2.17.1
^ permalink raw reply related [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 ` [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS Florian Fainelli
@ 2019-02-12 8:55 ` Jiri Pirko
2019-02-12 12:18 ` Ido Schimmel
1 sibling, 0 replies; 13+ messages in thread
From: Jiri Pirko @ 2019-02-12 8:55 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
Mon, Feb 11, 2019 at 10:17:47PM CET, f.fainelli@gmail.com wrote:
>There is no code that will query the SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
>attribute remove support for that.
>
>Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 ` [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS Florian Fainelli
2019-02-12 8:55 ` Jiri Pirko
@ 2019-02-12 12:18 ` Ido Schimmel
1 sibling, 0 replies; 13+ messages in thread
From: Ido Schimmel @ 2019-02-12 12:18 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, David S. Miller, open list, open list:STAGING SUBSYSTEM,
moderated list:ETHERNET BRIDGE, Jiri Pirko, andrew,
vivien.didelot
On Mon, Feb 11, 2019 at 01:17:47PM -0800, Florian Fainelli wrote:
> There is no code that will query the SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
> attribute remove support for that.
>
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
^ permalink raw reply [flat|nested] 13+ messages in thread
* [PATCH net-next 2/3] rocker: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Florian Fainelli
2019-02-11 21:17 ` [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS Florian Fainelli
@ 2019-02-11 21:17 ` Florian Fainelli
2019-02-12 8:56 ` Jiri Pirko
2019-02-11 21:17 ` [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: " Florian Fainelli
` (2 subsequent siblings)
4 siblings, 1 reply; 13+ messages in thread
From: Florian Fainelli @ 2019-02-11 21:17 UTC (permalink / raw)
To: netdev
Cc: Florian Fainelli, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
There is no code that attempts to get the
SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS attribute, remove support for that.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
drivers/net/ethernet/rocker/rocker.h | 2 --
drivers/net/ethernet/rocker/rocker_main.c | 15 ---------------
drivers/net/ethernet/rocker/rocker_ofdpa.c | 10 ----------
3 files changed, 27 deletions(-)
diff --git a/drivers/net/ethernet/rocker/rocker.h b/drivers/net/ethernet/rocker/rocker.h
index 748fb12260a6..2b2e1c4f0dc3 100644
--- a/drivers/net/ethernet/rocker/rocker.h
+++ b/drivers/net/ethernet/rocker/rocker.h
@@ -109,8 +109,6 @@ struct rocker_world_ops {
int (*port_attr_bridge_flags_set)(struct rocker_port *rocker_port,
unsigned long brport_flags,
struct switchdev_trans *trans);
- int (*port_attr_bridge_flags_get)(const struct rocker_port *rocker_port,
- unsigned long *p_brport_flags);
int (*port_attr_bridge_flags_support_get)(const struct rocker_port *
rocker_port,
unsigned long *
diff --git a/drivers/net/ethernet/rocker/rocker_main.c b/drivers/net/ethernet/rocker/rocker_main.c
index 66f72f8c46e5..5ce8d5aba603 100644
--- a/drivers/net/ethernet/rocker/rocker_main.c
+++ b/drivers/net/ethernet/rocker/rocker_main.c
@@ -1582,17 +1582,6 @@ rocker_world_port_attr_bridge_flags_set(struct rocker_port *rocker_port,
trans);
}
-static int
-rocker_world_port_attr_bridge_flags_get(const struct rocker_port *rocker_port,
- unsigned long *p_brport_flags)
-{
- struct rocker_world_ops *wops = rocker_port->rocker->wops;
-
- if (!wops->port_attr_bridge_flags_get)
- return -EOPNOTSUPP;
- return wops->port_attr_bridge_flags_get(rocker_port, p_brport_flags);
-}
-
static int
rocker_world_port_attr_bridge_flags_support_get(const struct rocker_port *
rocker_port,
@@ -2061,10 +2050,6 @@ static int rocker_port_attr_get(struct net_device *dev,
int err = 0;
switch (attr->id) {
- case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS:
- err = rocker_world_port_attr_bridge_flags_get(rocker_port,
- &attr->u.brport_flags);
- break;
case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS_SUPPORT:
err = rocker_world_port_attr_bridge_flags_support_get(rocker_port,
&attr->u.brport_flags_support);
diff --git a/drivers/net/ethernet/rocker/rocker_ofdpa.c b/drivers/net/ethernet/rocker/rocker_ofdpa.c
index bea7895930f6..9c07f6040720 100644
--- a/drivers/net/ethernet/rocker/rocker_ofdpa.c
+++ b/drivers/net/ethernet/rocker/rocker_ofdpa.c
@@ -2511,16 +2511,6 @@ static int ofdpa_port_attr_bridge_flags_set(struct rocker_port *rocker_port,
return err;
}
-static int
-ofdpa_port_attr_bridge_flags_get(const struct rocker_port *rocker_port,
- unsigned long *p_brport_flags)
-{
- const struct ofdpa_port *ofdpa_port = rocker_port->wpriv;
-
- *p_brport_flags = ofdpa_port->brport_flags;
- return 0;
-}
-
static int
ofdpa_port_attr_bridge_flags_support_get(const struct rocker_port *
rocker_port,
--
2.17.1
^ permalink raw reply related [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 2/3] rocker: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 ` [PATCH net-next 2/3] rocker: " Florian Fainelli
@ 2019-02-12 8:56 ` Jiri Pirko
0 siblings, 0 replies; 13+ messages in thread
From: Jiri Pirko @ 2019-02-12 8:56 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
Mon, Feb 11, 2019 at 10:17:48PM CET, f.fainelli@gmail.com wrote:
>There is no code that attempts to get the
>SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS attribute, remove support for that.
>
>Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
^ permalink raw reply [flat|nested] 13+ messages in thread
* [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Florian Fainelli
2019-02-11 21:17 ` [PATCH net-next 1/3] mlxsw: spectrum_switchdev: Remove getting PORT_BRIDGE_FLAGS Florian Fainelli
2019-02-11 21:17 ` [PATCH net-next 2/3] rocker: " Florian Fainelli
@ 2019-02-11 21:17 ` Florian Fainelli
2019-02-12 7:28 ` Greg KH
2019-02-12 8:56 ` Jiri Pirko
2019-02-12 8:55 ` [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Jiri Pirko
2019-02-12 17:50 ` David Miller
4 siblings, 2 replies; 13+ messages in thread
From: Florian Fainelli @ 2019-02-11 21:17 UTC (permalink / raw)
To: netdev
Cc: Florian Fainelli, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
There is no code that tries to get the attribute
SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS, remove support for doing that.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
drivers/staging/fsl-dpaa2/ethsw/ethsw.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/staging/fsl-dpaa2/ethsw/ethsw.c b/drivers/staging/fsl-dpaa2/ethsw/ethsw.c
index e559f4c25cf7..e5a14c7c777f 100644
--- a/drivers/staging/fsl-dpaa2/ethsw/ethsw.c
+++ b/drivers/staging/fsl-dpaa2/ethsw/ethsw.c
@@ -646,11 +646,6 @@ static int swdev_port_attr_get(struct net_device *netdev,
struct ethsw_port_priv *port_priv = netdev_priv(netdev);
switch (attr->id) {
- case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS:
- attr->u.brport_flags =
- (port_priv->ethsw_data->learning ? BR_LEARNING : 0) |
- (port_priv->flood ? BR_FLOOD : 0);
- break;
case SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS_SUPPORT:
attr->u.brport_flags_support = BR_LEARNING | BR_FLOOD;
break;
--
2.17.1
^ permalink raw reply related [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 ` [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: " Florian Fainelli
@ 2019-02-12 7:28 ` Greg KH
2019-02-12 8:56 ` Jiri Pirko
1 sibling, 0 replies; 13+ messages in thread
From: Greg KH @ 2019-02-12 7:28 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, open list:STAGING SUBSYSTEM, andrew,
moderated list:ETHERNET BRIDGE, open list, vivien.didelot,
Ido Schimmel, jiri, David S. Miller
On Mon, Feb 11, 2019 at 01:17:49PM -0800, Florian Fainelli wrote:
> There is no code that tries to get the attribute
> SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS, remove support for doing that.
>
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
> ---
> drivers/staging/fsl-dpaa2/ethsw/ethsw.c | 5 -----
> 1 file changed, 5 deletions(-)
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: Remove getting PORT_BRIDGE_FLAGS
2019-02-11 21:17 ` [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: " Florian Fainelli
2019-02-12 7:28 ` Greg KH
@ 2019-02-12 8:56 ` Jiri Pirko
1 sibling, 0 replies; 13+ messages in thread
From: Jiri Pirko @ 2019-02-12 8:56 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
Mon, Feb 11, 2019 at 10:17:49PM CET, f.fainelli@gmail.com wrote:
>There is no code that tries to get the attribute
>SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS, remove support for doing that.
>
>Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
2019-02-11 21:17 [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Florian Fainelli
` (2 preceding siblings ...)
2019-02-11 21:17 ` [PATCH net-next 3/3] staging: fsl-dpaa2: ethsw: " Florian Fainelli
@ 2019-02-12 8:55 ` Jiri Pirko
2019-02-12 17:50 ` David Miller
4 siblings, 0 replies; 13+ messages in thread
From: Jiri Pirko @ 2019-02-12 8:55 UTC (permalink / raw)
To: Florian Fainelli
Cc: netdev, David S. Miller, Ido Schimmel, open list,
open list:STAGING SUBSYSTEM, moderated list:ETHERNET BRIDGE,
jiri, andrew, vivien.didelot
Mon, Feb 11, 2019 at 10:17:46PM CET, f.fainelli@gmail.com wrote:
>Hi all,
>
>AFAICT there is no code that attempts to get the value of the attribute
>SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS while it is used with
>switchdev_port_attr_set().
>
>This is effectively no doing anything and it can slow down future work
>that tries to make modifications in these areas so remove that.
>
>David, there should be no dependency with previous patch series, but
>again, feedback from Ido and Jiri would be welcome in case this was
>added for a reason.
It was originally used by:
switchdev_port_bridge_getlink()
removed by:
commit 29ab586c3d83f81c435e269cace9a1619afb5bbd
Author: Arkadi Sharshevsky <arkadis@mellanox.com>
Date: Sun Aug 6 16:15:51 2017 +0300
net: switchdev: Remove bridge bypass support from switchdev
So these are just leftovers. Let's flush them.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
2019-02-11 21:17 [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Florian Fainelli
` (3 preceding siblings ...)
2019-02-12 8:55 ` [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS Jiri Pirko
@ 2019-02-12 17:50 ` David Miller
2019-02-12 17:54 ` Florian Fainelli
4 siblings, 1 reply; 13+ messages in thread
From: David Miller @ 2019-02-12 17:50 UTC (permalink / raw)
To: f.fainelli
Cc: netdev, idosch, linux-kernel, devel, bridge, jiri, andrew,
vivien.didelot
From: Florian Fainelli <f.fainelli@gmail.com>
Date: Mon, 11 Feb 2019 13:17:46 -0800
> AFAICT there is no code that attempts to get the value of the attribute
> SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS while it is used with
> switchdev_port_attr_set().
>
> This is effectively no doing anything and it can slow down future work
> that tries to make modifications in these areas so remove that.
Series applied.
> David, there should be no dependency with previous patch series, but
> again, feedback from Ido and Jiri would be welcome in case this was
> added for a reason.
Ok, is there going to be another respin of that switchdev_ops removal
series?
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
2019-02-12 17:50 ` David Miller
@ 2019-02-12 17:54 ` Florian Fainelli
2019-02-12 21:35 ` Florian Fainelli
0 siblings, 1 reply; 13+ messages in thread
From: Florian Fainelli @ 2019-02-12 17:54 UTC (permalink / raw)
To: David Miller
Cc: netdev, idosch, linux-kernel, devel, bridge, jiri, andrew,
vivien.didelot
On 2/12/19 9:50 AM, David Miller wrote:
> From: Florian Fainelli <f.fainelli@gmail.com>
> Date: Mon, 11 Feb 2019 13:17:46 -0800
>
>> AFAICT there is no code that attempts to get the value of the attribute
>> SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS while it is used with
>> switchdev_port_attr_set().
>>
>> This is effectively no doing anything and it can slow down future work
>> that tries to make modifications in these areas so remove that.
>
> Series applied.
>
>> David, there should be no dependency with previous patch series, but
>> again, feedback from Ido and Jiri would be welcome in case this was
>> added for a reason.
>
> Ok, is there going to be another respin of that switchdev_ops removal
> series?
Yes, I will be working on a v5 which addresses Ido's feedback in the
next hours.
--
Florian
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PATCH net-next 0/3] Remove getting SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS
2019-02-12 17:54 ` Florian Fainelli
@ 2019-02-12 21:35 ` Florian Fainelli
0 siblings, 0 replies; 13+ messages in thread
From: Florian Fainelli @ 2019-02-12 21:35 UTC (permalink / raw)
To: David Miller
Cc: netdev, idosch, linux-kernel, devel, bridge, jiri, andrew,
vivien.didelot
On 2/12/19 9:54 AM, Florian Fainelli wrote:
> On 2/12/19 9:50 AM, David Miller wrote:
>> From: Florian Fainelli <f.fainelli@gmail.com>
>> Date: Mon, 11 Feb 2019 13:17:46 -0800
>>
>>> AFAICT there is no code that attempts to get the value of the attribute
>>> SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS while it is used with
>>> switchdev_port_attr_set().
>>>
>>> This is effectively no doing anything and it can slow down future work
>>> that tries to make modifications in these areas so remove that.
>>
>> Series applied.
>>
>>> David, there should be no dependency with previous patch series, but
>>> again, feedback from Ido and Jiri would be welcome in case this was
>>> added for a reason.
>>
>> Ok, is there going to be another respin of that switchdev_ops removal
>> series?
>
> Yes, I will be working on a v5 which addresses Ido's feedback in the
> next hours.
David, looks like I managed to introduce a build failure with
rocker_ofdpa.c, sorry about that, I will send a follow-up immediately.
--
Florian
^ permalink raw reply [flat|nested] 13+ messages in thread