From 4fa2e281f3cdd5c4167d16d131a7f52985d9f79e Mon Sep 17 00:00:00 2001 From: Cosmin Jinga Date: Mon, 6 Sep 2021 13:57:14 +0300 Subject: [PATCH 1/4] Updated CBF config packaging [build_templates]: Added default configuration file for CBF [rules]: Added loading rule for CBF config Why I did it The CBF default config is required to load default start-up config on CBF capable platforms How I did it Added the default config files among the existing ones, mirroring the QOS implementation How to verify it Deploy SBI on a CBF capable platform(e.g. SODA) Signed-off-by: v-cjinga@microsoft.com --- files/build_templates/cbf_config.j2 | 12 ++++++++++++ rules/scripts.dep | 1 + rules/scripts.mk | 4 ++++ 3 files changed, 17 insertions(+) create mode 100644 files/build_templates/cbf_config.j2 diff --git a/files/build_templates/cbf_config.j2 b/files/build_templates/cbf_config.j2 new file mode 100644 index 000000000000..6b8a1abf9dc1 --- /dev/null +++ b/files/build_templates/cbf_config.j2 @@ -0,0 +1,12 @@ +{ + "DSCP_TO_FC_MAP_TABLE": { + "default": { + "0": "0" + } + }, + "EXP_TO_FC_MAP_TABLE": { + "default": { + "0": "0" + } + } +} \ No newline at end of file diff --git a/rules/scripts.dep b/rules/scripts.dep index 929611852ea4..a8921b321a5e 100644 --- a/rules/scripts.dep +++ b/rules/scripts.dep @@ -6,5 +6,6 @@ $(CONFIGDB_LOAD_SCRIPT)_CACHE_MODE := none $(BUFFERS_CONFIG_TEMPLATE)_CACHE_MODE := none $(UPDATE_PROC_VARIABLES_SCRIPT)_CACHE_MODE := none $(QOS_CONFIG_TEMPLATE)_CACHE_MODE := none +$(CBF_CONFIG_TEMPLATE)_CACHE_MODE := none $(SUPERVISOR_PROC_EXIT_LISTENER_SCRIPT)_CACHE_MODE := none $(COPP_CONFIG_TEMPLATE)_CACHE_MODE := none diff --git a/rules/scripts.mk b/rules/scripts.mk index e0694a1cdf9b..ce6a8eb90025 100644 --- a/rules/scripts.mk +++ b/rules/scripts.mk @@ -14,6 +14,9 @@ $(BUFFERS_CONFIG_TEMPLATE)_PATH = files/build_templates QOS_CONFIG_TEMPLATE = qos_config.j2 $(QOS_CONFIG_TEMPLATE)_PATH = files/build_templates +CBF_CONFIG_TEMPLATE = cbf_config.j2 +$(CBF_CONFIG_TEMPLATE)_PATH = files/build_templates + SUPERVISOR_PROC_EXIT_LISTENER_SCRIPT = supervisor-proc-exit-listener $(SUPERVISOR_PROC_EXIT_LISTENER_SCRIPT)_PATH = files/scripts @@ -34,6 +37,7 @@ SONIC_COPY_FILES += $(CONFIGDB_LOAD_SCRIPT) \ $(ARP_UPDATE_VARS_TEMPLATE) \ $(BUFFERS_CONFIG_TEMPLATE) \ $(QOS_CONFIG_TEMPLATE) \ + $(CBF_CONFIG_TEMPLATE) \ $(SUPERVISOR_PROC_EXIT_LISTENER_SCRIPT) \ $(SYSCTL_NET_CONFIG) \ $(UPDATE_CHASSISDB_CONFIG_SCRIPT) \ From 31e3524211cb7bbfcb61cd4ac8b59a4d82a59b25 Mon Sep 17 00:00:00 2001 From: Cosmin Jinga Date: Mon, 11 Oct 2021 13:08:02 +0300 Subject: [PATCH 2/4] Renamed DSCP_TO_FC_MAP and EXP_TO_FC_MAP tables to be in line with the other QoS map tables --- files/build_templates/cbf_config.j2 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/files/build_templates/cbf_config.j2 b/files/build_templates/cbf_config.j2 index 6b8a1abf9dc1..f67fb26998f1 100644 --- a/files/build_templates/cbf_config.j2 +++ b/files/build_templates/cbf_config.j2 @@ -1,12 +1,12 @@ { - "DSCP_TO_FC_MAP_TABLE": { + "DSCP_TO_FC_MAP": { "default": { "0": "0" } }, - "EXP_TO_FC_MAP_TABLE": { + "EXP_TO_FC_MAP": { "default": { "0": "0" } } -} \ No newline at end of file +} From e6757f6939429a1b5e061a3fce2ff00d590a8188 Mon Sep 17 00:00:00 2001 From: Cosmin Jinga Date: Thu, 14 Oct 2021 08:38:11 +0300 Subject: [PATCH 3/4] Updated default CBF template config --- files/build_templates/cbf_config.j2 | 80 +++++++++++++++++++++++++++-- 1 file changed, 75 insertions(+), 5 deletions(-) diff --git a/files/build_templates/cbf_config.j2 b/files/build_templates/cbf_config.j2 index f67fb26998f1..38458eb53372 100644 --- a/files/build_templates/cbf_config.j2 +++ b/files/build_templates/cbf_config.j2 @@ -1,12 +1,82 @@ { - "DSCP_TO_FC_MAP": { - "default": { - "0": "0" + "DSCP_TO_TC_MAP": { + "AZURE": { + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "EXP_TO_FC_MAP": { - "default": { - "0": "0" + "AZURE": { + "0": "0", + "1": "1", + "2": "2", + "3": "3", + "4": "4", + "5": "5", + "6": "6", + "7": "7" } } } From ba1c42bd6d3e68c48baabce2dbf76cd129ba2255 Mon Sep 17 00:00:00 2001 From: Cosmin Jinga Date: Thu, 21 Oct 2021 11:35:40 +0300 Subject: [PATCH 4/4] Changed CBF DSCP map to correct name --- files/build_templates/cbf_config.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/build_templates/cbf_config.j2 b/files/build_templates/cbf_config.j2 index 38458eb53372..ff465f1ca29d 100644 --- a/files/build_templates/cbf_config.j2 +++ b/files/build_templates/cbf_config.j2 @@ -1,5 +1,5 @@ { - "DSCP_TO_TC_MAP": { + "DSCP_TO_FC_MAP": { "AZURE": { "0" : "1", "1" : "1",