liquidio: add support for XPS
authorRick Farrington <ricardo.farrington@cavium.com>
Tue, 7 Mar 2017 19:40:41 +0000 (11:40 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 9 Mar 2017 21:21:17 +0000 (13:21 -0800)
Add support for XPS.

Signed-off-by: Rick Farrington <ricardo.farrington@cavium.com>
Signed-off-by: Felix Manlunas <felix.manlunas@cavium.com>
Signed-off-by: Derek Chickles <derek.chickles@cavium.com>
Signed-off-by: Satanand Burla <satananda.burla@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/cavium/liquidio/lio_main.c

index be9c0e3f5ade7d4e61694da214702f0223ab5d59..dffed432d58e7ad48cd2616e41d1fcb7bed89be4 100644 (file)
@@ -2553,6 +2553,15 @@ static inline int setup_io_queues(struct octeon_device *octeon_dev,
                                __func__);
                        return 1;
                }
+
+               if (octeon_dev->ioq_vector) {
+                       struct octeon_ioq_vector *ioq_vector;
+
+                       ioq_vector = &octeon_dev->ioq_vector[q];
+                       netif_set_xps_queue(netdev,
+                                           &ioq_vector->affinity_mask,
+                                           ioq_vector->iq_index);
+               }
        }
 
        return 0;