From 621d9683e48a5bf5555c517a374326f1074f67ae Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Sat, 27 Apr 2024 14:03:30 +0900 Subject: [PATCH] dpdk: Require integer for memory_channels Support for string values has been deprecated. Change-Id: I76a42b4017b9a76f319221ff0fbb4deaf299e595 --- manifests/dpdk.pp | 13 +++---------- ...dk-memory-channels-integer-3362fc25794b170a.yaml | 5 +++++ 2 files changed, 8 insertions(+), 10 deletions(-) create mode 100644 releasenotes/notes/dpdk-memory-channels-integer-3362fc25794b170a.yaml diff --git a/manifests/dpdk.pp b/manifests/dpdk.pp index e691662f..e3f5e93c 100644 --- a/manifests/dpdk.pp +++ b/manifests/dpdk.pp @@ -106,7 +106,7 @@ class vswitch::dpdk ( String[1] $package_name, String[1] $service_name, String $package_ensure = 'present', - Optional[Variant[Integer[0], String]] $memory_channels = undef, + Optional[Integer[0]] $memory_channels = undef, Optional[String] $host_core_list = undef, Optional[String] $pmd_core_list = undef, Optional[Variant[String, Integer, Array[String], Array[Integer]]] $socket_mem = undef, @@ -140,16 +140,9 @@ class vswitch::dpdk ( $pmd_core_mask = range_to_mask($pmd_core_list) $dpdk_lcore_mask = range_to_mask($host_core_list) - if $memory_channels =~ String { - warning('Support for string by memory_channels is deprecated. Use integer instead') - } $memory_channels_conf = $memory_channels ? { - String => empty($memory_channels) ? { - true => undef, - default => "-n ${memory_channels}", - }, - Integer => "-n ${memory_channels}", - default => undef, + undef => undef, + default => "-n ${memory_channels}", } $dpdk_configs = { diff --git a/releasenotes/notes/dpdk-memory-channels-integer-3362fc25794b170a.yaml b/releasenotes/notes/dpdk-memory-channels-integer-3362fc25794b170a.yaml new file mode 100644 index 00000000..b7fbed5b --- /dev/null +++ b/releasenotes/notes/dpdk-memory-channels-integer-3362fc25794b170a.yaml @@ -0,0 +1,5 @@ +--- +upgrade: + - | + The ``vswitch::dpdk::memory_channels`` parmeter now requires an integer + value.