Commit 4c4a5686 authored by Yan Markman's avatar Yan Markman Committed by David S. Miller

net: mvpp2: use RSS only when using multi-queue mode

Since RSS only applies when we have per-cpu rx queues, it should only
be enabled when the driver is configured to make use of multi-queue
mode.
Signed-off-by: default avatarYan Markman <ymarkman@marvell.com>
[Maxime: Commit message]
Signed-off-by: default avatarMaxime Chevallier <maxime.chevallier@bootlin.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 3f6aaf72
...@@ -3276,6 +3276,11 @@ static void mvpp2_irqs_deinit(struct mvpp2_port *port) ...@@ -3276,6 +3276,11 @@ static void mvpp2_irqs_deinit(struct mvpp2_port *port)
} }
} }
static bool mvpp22_rss_is_supported(void)
{
return queue_mode == MVPP2_QDIST_MULTI_MODE;
}
static int mvpp2_open(struct net_device *dev) static int mvpp2_open(struct net_device *dev)
{ {
struct mvpp2_port *port = netdev_priv(dev); struct mvpp2_port *port = netdev_priv(dev);
...@@ -3368,7 +3373,7 @@ static int mvpp2_open(struct net_device *dev) ...@@ -3368,7 +3373,7 @@ static int mvpp2_open(struct net_device *dev)
mvpp2_start_dev(port); mvpp2_start_dev(port);
if (priv->hw_version == MVPP22) if (mvpp22_rss_is_supported())
mvpp22_init_rss(port); mvpp22_init_rss(port);
/* Start hardware statistics gathering */ /* Start hardware statistics gathering */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment