提交 4715029f 编写于 作者: V Vladimir Oltean 提交者: David S. Miller

net: dsa: drop dsa_slave_priv from dsa_slave_change_mtu

We can get a hold of the "ds" pointer directly from "dp", no need for
the dsa_slave_priv.
Signed-off-by: NVladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 cf1c39d3
...@@ -1806,9 +1806,8 @@ int dsa_slave_change_mtu(struct net_device *dev, int new_mtu) ...@@ -1806,9 +1806,8 @@ int dsa_slave_change_mtu(struct net_device *dev, int new_mtu)
{ {
struct net_device *master = dsa_slave_to_master(dev); struct net_device *master = dsa_slave_to_master(dev);
struct dsa_port *dp = dsa_slave_to_port(dev); struct dsa_port *dp = dsa_slave_to_port(dev);
struct dsa_slave_priv *p = netdev_priv(dev);
struct dsa_port *cpu_dp = dp->cpu_dp; struct dsa_port *cpu_dp = dp->cpu_dp;
struct dsa_switch *ds = p->dp->ds; struct dsa_switch *ds = dp->ds;
struct dsa_port *other_dp; struct dsa_port *other_dp;
int largest_mtu = 0; int largest_mtu = 0;
int new_master_mtu; int new_master_mtu;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册