Skip to content

Commit 966051c

Browse files
committed
Add NUMA affinity policy options "socket"
Added a new port NUMA affinity policy option called "socket". Depends-On: https://review.opendev.org/c/openstack/neutron/+/910594 Related-Bug: #2052786 Change-Id: Icff9070db68ba83b47b344d56ee93b235383b2f2
1 parent 2eea916 commit 966051c

2 files changed

Lines changed: 14 additions & 0 deletions

File tree

openstackclient/network/v2/port.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,10 @@ def _get_attrs(client_manager, parsed_args):
205205
and parsed_args.numa_policy_preferred
206206
):
207207
attrs['numa_affinity_policy'] = 'preferred'
208+
elif (
209+
'numa_policy_socket' in parsed_args and parsed_args.numa_policy_socket
210+
):
211+
attrs['numa_affinity_policy'] = 'socket'
208212
elif (
209213
'numa_policy_legacy' in parsed_args and parsed_args.numa_policy_legacy
210214
):
@@ -354,6 +358,11 @@ def _add_updatable_args(parser):
354358
action='store_true',
355359
help=_("NUMA affinity policy preferred to schedule this port"),
356360
)
361+
numa_affinity_policy_group.add_argument(
362+
'--numa-policy-socket',
363+
action='store_true',
364+
help=_("NUMA affinity policy socket to schedule this port"),
365+
)
357366
numa_affinity_policy_group.add_argument(
358367
'--numa-policy-legacy',
359368
action='store_true',
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
features:
3+
- |
4+
Add a new NUMA affinity policy option: "socket". That applies to any new
5+
port (using ``port create``) or any existing port (using ``port set``).

0 commit comments

Comments
 (0)