diff options
author | Andrew Lunn <andrew@lunn.ch> | 2016-06-04 21:16:59 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-06-04 14:29:53 -0700 |
commit | 4a7704ffa86705b0580b6473c407b7b7618e072d (patch) | |
tree | ea9483934d983ffb5f00c22f9b1aa6b881b6b71c /drivers | |
parent | 189b0d93ec61e1f991e96d7bc03b03cf929d164c (diff) |
net: dsa: Remove dynamic allocate of routing table
With a maximum of four switches, the size of the routing table is the
same as the pointer to it. Removing it makes the code simpler.
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/dsa/mv88e6xxx.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/dsa/mv88e6xxx.c b/drivers/net/dsa/mv88e6xxx.c index 85332d9a245a..d622c0fb76cc 100644 --- a/drivers/net/dsa/mv88e6xxx.c +++ b/drivers/net/dsa/mv88e6xxx.c @@ -3024,8 +3024,7 @@ static int mv88e6xxx_setup_global(struct mv88e6xxx_priv_state *ps) for (i = 0; i < 32; i++) { int nexthop = 0x1f; - if (ps->ds->cd->rtable && - i != ps->ds->index && i < ps->ds->dst->pd->nr_chips) + if (i != ps->ds->index && i < ps->ds->dst->pd->nr_chips) nexthop = ps->ds->cd->rtable[i] & 0x1f; err = _mv88e6xxx_reg_write( |