From: Sameeh Jubran Date: Wed, 1 May 2019 13:47:03 +0000 (+0300) Subject: net: ena: fix swapped parameters when calling ena_com_indirect_table_fill_entry X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=3c6eeff295f01bdf1c6c3addcb0a04c0c6c029e9;p=openwrt%2Fstaging%2Fblogic.git net: ena: fix swapped parameters when calling ena_com_indirect_table_fill_entry second parameter should be the index of the table rather than the value. Fixes: 1738cd3ed342 ("net: ena: Add a driver for Amazon Elastic Network Adapters (ENA)") Signed-off-by: Saeed Bshara Signed-off-by: Sameeh Jubran Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/amazon/ena/ena_ethtool.c b/drivers/net/ethernet/amazon/ena/ena_ethtool.c index f3a5a384e6e8..fe596bc30a96 100644 --- a/drivers/net/ethernet/amazon/ena/ena_ethtool.c +++ b/drivers/net/ethernet/amazon/ena/ena_ethtool.c @@ -697,8 +697,8 @@ static int ena_set_rxfh(struct net_device *netdev, const u32 *indir, if (indir) { for (i = 0; i < ENA_RX_RSS_TABLE_SIZE; i++) { rc = ena_com_indirect_table_fill_entry(ena_dev, - ENA_IO_RXQ_IDX(indir[i]), - i); + i, + ENA_IO_RXQ_IDX(indir[i])); if (unlikely(rc)) { netif_err(adapter, drv, netdev, "Cannot fill indirect table (index is too large)\n");