summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/ibm/ibmvnic.h
diff options
context:
space:
mode:
authorNick Child <nnac123@linux.ibm.com>2022-11-10 15:32:17 -0600
committerDavid S. Miller <davem@davemloft.net>2022-11-14 10:47:07 +0000
commit92125c3a602454824d70edb1b2abb382811cab4f (patch)
tree13dc4ac62d7f73d9e83c7a703e70f5a19b6c3f73 /drivers/net/ethernet/ibm/ibmvnic.h
parent44fbc1b6e0e291df1d31f5080777ce66a72ef37a (diff)
ibmvnic: Add hotpluggable CPU callbacks to reassign affinity hints
When CPU's are added and removed, ibmvnic devices will reassign hint values. Introduce a new cpu hotplug state CPUHP_IBMVNIC_DEAD to signal to ibmvnic devices that the CPU has been removed and it is time to reset affinity hint assignments. On the other hand, when CPU's are being added, add a state instance to CPUHP_AP_ONLINE_DYN which will trigger a reassignment of affinity hints once the new CPU's are online. This implementation is based on the virtio_net driver. Signed-off-by: Thomas Falcon <tlfalcon@linux.ibm.com> Signed-off-by: Dany Madden <drt@linux.ibm.com> Signed-off-by: Nick Child <nnac123@linux.ibm.com> Reviewed-by: Rick Lindsley <ricklind@linux.ibm.com> Reviewed-by: Haren Myneni <haren@linux.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ibm/ibmvnic.h')
-rw-r--r--drivers/net/ethernet/ibm/ibmvnic.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/ibm/ibmvnic.h b/drivers/net/ethernet/ibm/ibmvnic.h
index 6720fec1ae67..b35c9b6f913b 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.h
+++ b/drivers/net/ethernet/ibm/ibmvnic.h
@@ -984,6 +984,10 @@ struct ibmvnic_adapter {
int reset_done_rc;
bool wait_for_reset;
+ /* CPU hotplug instances for online & dead */
+ struct hlist_node node;
+ struct hlist_node node_dead;
+
/* partner capabilities */
u64 min_tx_queues;
u64 min_rx_queues;