Skip to content

Commit eaa99ad

Browse files
authored
Merge 3a9f7e6 into 50eaa18
2 parents 50eaa18 + 3a9f7e6 commit eaa99ad

File tree

342 files changed

+44526
-40180
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

342 files changed

+44526
-40180
lines changed

platform/broadcom/sai-modules.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Broadcom SAI modules
22

3-
BRCM_OPENNSL_KERNEL_VERSION = 11.2.4.1
3+
BRCM_OPENNSL_KERNEL_VERSION = 12.1.0.2
44

55
BRCM_OPENNSL_KERNEL = opennsl-modules_$(BRCM_OPENNSL_KERNEL_VERSION)_amd64.deb
66
$(BRCM_OPENNSL_KERNEL)_SRC_PATH = $(PLATFORM_PATH)/saibcm-modules

platform/broadcom/sai.mk

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
LIBSAIBCM_XGS_VERSION = 11.2.16.2
1+
LIBSAIBCM_XGS_VERSION = 12.1.0.2
22
LIBSAIBCM_DNX_VERSION = 11.2.13.1-1
3-
LIBSAIBCM_XGS_BRANCH_NAME = SAI_11.2.16.2
3+
LIBSAIBCM_XGS_BRANCH_NAME = SAI_12.1.0_GA
44
LIBSAIBCM_DNX_BRANCH_NAME = SAI_11.2.0_GA
55
LIBSAIBCM_XGS_URL_PREFIX = "https://sonicstorage.blob.core.windows.net/public/sai/sai-broadcom/$(LIBSAIBCM_XGS_BRANCH_NAME)/$(LIBSAIBCM_XGS_VERSION)/xgs"
66
LIBSAIBCM_DNX_URL_PREFIX = "https://sonicstorage.blob.core.windows.net/public/sai/sai-broadcom/$(LIBSAIBCM_DNX_BRANCH_NAME)/$(LIBSAIBCM_DNX_VERSION)/dnx"

platform/broadcom/saibcm-modules/debian/changelog

+6
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
opennsl (12.1.0.2) unstable; urgency=medium
2+
3+
* Update to Broadcom SAI 12.1.0.2
4+
5+
-- Ziting Guo <[email protected]> Wed, 18 Dec 2024 02:33:59 +0000
6+
17
opennsl (11.2.4.1) unstable; urgency=medium
28

39
* Update to Broadcom SAI 11.2.4.1

platform/broadcom/saibcm-modules/include/kcom.h

+8-6
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
#define KCOM_M_CLOCK_CMD 52 /* Clock Commands */
7373
#define KCOM_M_PCIE_LINK_STATUS 53 /* PCIe link status */
7474

75-
#define KCOM_VERSION 16 /* Protocol version */
75+
#define KCOM_VERSION 17 /* Protocol version */
7676

7777
/*
7878
* Message status codes
@@ -126,10 +126,11 @@ typedef struct kcom_msg_hdr_s {
126126
#define KCOM_NETIF_T_PORT 1
127127
#define KCOM_NETIF_T_META 2
128128

129-
#define KCOM_NETIF_F_ADD_TAG (1U << 0)
130-
#define KCOM_NETIF_F_RCPU_ENCAP (1U << 1)
129+
#define KCOM_NETIF_F_ADD_TAG (1U << 0)
130+
#define KCOM_NETIF_F_RCPU_ENCAP (1U << 1)
131131
/* If a netif has this flag, the packet sent to the netif can't be stripped tag or added tag */
132-
#define KCOM_NETIF_F_KEEP_RX_TAG (1U << 2)
132+
#define KCOM_NETIF_F_KEEP_RX_TAG (1U << 2)
133+
#define KCOM_NETIF_F_USE_SHARED_NDEV (1U << 3)
133134

134135
#define KCOM_NETIF_NAME_MAX 16
135136

@@ -331,7 +332,7 @@ typedef struct kcom_eth_hw_config_s {
331332
} kcom_eth_hw_config_t;
332333

333334
#ifndef KCOM_HW_INFO_OAMP_PORT_MAX
334-
#define KCOM_HW_INFO_OAMP_PORT_MAX 4
335+
#define KCOM_HW_INFO_OAMP_PORT_MAX 8
335336
#endif
336337

337338
/*
@@ -370,7 +371,7 @@ typedef struct kcom_msg_version_s {
370371

371372
typedef struct kcom_clock_info_s {
372373
uint8 cmd;
373-
int32 data[8];
374+
int32 data[12];
374375
} kcom_clock_info_t;
375376

376377
/*
@@ -587,6 +588,7 @@ typedef struct kcom_msg_hw_info_s {
587588
uint32 udh_length_type[4];
588589
uint32 udh_size;
589590
uint32 oamp_punted;
591+
uint32 enet_channels;
590592
uint8 no_skip_udh_check;
591593
uint8 oam_dm_tod_exist;
592594
uint8 system_headers_mode;

platform/broadcom/saibcm-modules/include/soc/devids.h

+10
Original file line numberDiff line numberDiff line change
@@ -1445,6 +1445,11 @@
14451445
#define BCM53653_B0_REV_ID 0x11
14461446
#define BCM53653_C0_REV_ID 0x21
14471447

1448+
#define BCM53654_DEVICE_ID 0x8654
1449+
#define BCM53654_A0_REV_ID 1
1450+
#define BCM53654_B0_REV_ID 0x11
1451+
#define BCM53654_C0_REV_ID 0x21
1452+
14481453
/* Firebolt-5 */
14491454
#define BCM56565_DEVICE_ID 0xb565
14501455
#define BCM56565_A0_REV_ID 1
@@ -2044,6 +2049,11 @@
20442049
#define Q3_DEVICE_ID_END 0x886f
20452050
#define J3AI_DEVICE_ID 0x8890
20462051
#define Q3D_DEVICE_ID 0x8870
2052+
#ifdef BCM_Q3A_SUPPORT
2053+
#define Q3A_DEVICE_ID 0x8490
2054+
#define Q3U_DEVICE_ID 0x8400
2055+
#define Q3N_DEVICE_ID 0x8405
2056+
#endif
20472057
#endif
20482058
#define Q2A_DEVICE_ID 0x8480
20492059
#define Q2A_A0_REV_ID DNXC_A0_REV_ID

platform/broadcom/saibcm-modules/make/Make.config

+33
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,42 @@ endif
6262

6363
-include ${SDK}/make/Make.local
6464

65+
ifdef ALL_DNX_CHIPS
66+
ALL_DNX2_CHIPS = 1
67+
endif
68+
ifdef ALL_DNXF_CHIPS
69+
ALL_DNXF1_CHIPS = 1
70+
endif
71+
6572
ifdef ALL_CHIPS
6673
ESW_CHIPS = 1
6774
endif # ALL_CHIPS
6875

76+
ifdef ALL_DNX_CHIPS
77+
ALL_DNX2_CHIPS = 1
78+
ALL_DNX3_CHIPS = 1
79+
ALL_DNXF1_CHIPS = 1
80+
ALL_DNXF3_CHIPS = 1
81+
endif # ALL_CHIPS
82+
83+
ifdef ALL_DNX2_CHIPS
84+
CFGFLAGS += -DBCM_DNX_SUPPORT
85+
endif
86+
87+
ifdef ALL_DNX3_CHIPS
88+
CFGFLAGS += -DBCM_DNX3_SUPPORT
89+
endif
90+
91+
92+
ifdef ALL_DNXF1_CHIPS
93+
CFGFLAGS += -DBCM_DNXF_SUPPORT
94+
endif
95+
96+
ifdef ALL_DNXF3_CHIPS
97+
CFGFLAGS += -DBCM_DNXF3_SUPPORT
98+
endif
99+
100+
69101
#
70102
# By default, turn off the "changing directory" message.
71103
#
@@ -174,6 +206,7 @@ INCFLAGS = -I${INCDIR} -I${SDK}/systems
174206
CFLAGS += ${INCFLAGS}
175207
CXXFLAGS += ${INCFLAGS}
176208
CPPFLAGS += ${INCFLAGS}
209+
177210
CFLAGS += -DSAI_FIXUP -UKCOM_FILTER_MAX -DKCOM_FILTER_MAX=1025 -UKCOM_NETIF_MAX -DKCOM_NETIF_MAX=1056
178211

179212
# Flag to enable multi instance support

platform/broadcom/saibcm-modules/make/Make.depend

+9
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,15 @@ endif
106106

107107
endif # !CLEANING
108108

109+
ifeq ($(ARCH),arm64)
110+
# SAI: SONIC-76388 and SDK: SDK-367718
111+
# This macro removes the redundant macros and gcc options
112+
# JIRA SONIC-69062
113+
UNIQE = $(if $1,$(firstword $1) $(call UNIQE,$(filter-out $(firstword $1),$1)))
114+
CFLAGS := $(call UNIQE,$(CFLAGS))
115+
CFGFLAGS := $(call UNIQE,$(CFGFLAGS))
116+
endif
117+
109118
clean_d::
110119
ifdef QUIET
111120
@$(ECHO) Cleaning dependencies for ${LOCALDIR}

platform/broadcom/saibcm-modules/make/Make.kernlib

-10
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,6 @@
3030

3131
.SECONDARY:: ${BOBJS}
3232

33-
targetlibsoname = ${lib}.so.${SHAREDLIBVER}
34-
targetlibrealname = ${targetlibsoname}
35-
targetlibso = ${LIBDIR}/${targetlibrealname}
36-
3733
LIBSUFFIX=a
3834

3935
${LIBDIR}/%.a: ${BOBJS}
@@ -42,11 +38,6 @@ ifdef QUIET
4238
endif
4339
$Q$(RM) $@
4440
$Q$(AR) ${ARFLAGS} $@ $(sort ${BOBJS})
45-
ifeq ($(LINUX_MAKE_SHARED_LIB),1)
46-
ifeq ($(targetbase),unix)
47-
$(CC) -shared -Wl,-soname,${targetlibsoname} -o ${targetlibso} ${BOBJS} -lc
48-
endif
49-
endif # LINUX_MAKE_SHARED_LIB #
5041

5142
targetlib = ${LIBDIR}/${lib}.${LIBSUFFIX}
5243

@@ -60,7 +51,6 @@ ifdef QUIET
6051
endif
6152
$Q$(RM) ${BOBJS}
6253
$Q$(RM) ${targetlib}
63-
$Q$(RM) ${targetlibso}
6454

6555
distclean:: clean
6656

platform/broadcom/saibcm-modules/make/Make.lib

+6-9
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,14 @@ ifeq ($(FAST),1)
4141
endif
4242
endif
4343

44-
ifeq ($(LINUX_MAKE_SHARED_LIB),1)
45-
LIBSUFFIX=so.${SHAREDLIBVER}
46-
else
47-
LIBSUFFIX=a
44+
ifeq (1,$(SAND_ONLY))
45+
ifeq ($(LINUX_MAKE_SHARED_LIB),1)
46+
LIBSUFFIX := so.${SHAREDLIBVER}
47+
endif
4848
endif
4949

50+
LIBSUFFIX ?= a
51+
5052
targetlib = ${LIBDIR}/${lib}.${LIBSUFFIX}
5153

5254
all:: ${BLDDIR}/.tree ${targetlib}
@@ -57,12 +59,7 @@ ifdef QUIET
5759
@$(ECHO) Building library $(notdir $@)
5860
endif
5961
$Q$(RM) $@
60-
ifeq ($(LINUX_MAKE_SHARED_LIB),1)
61-
$(CC) -shared -Wl,-soname,${lib}.${LIBSUFFIX}${EXTRA_LIB_LDFLAGS} -o ${targetlib} ${BOBJS} -lc
62-
else
6362
$(AR) ${ARFLAGS} $@ $(sort ${BOBJS})
64-
endif
65-
6663

6764
install:: all
6865

platform/broadcom/saibcm-modules/make/Make.linux

+4-36
Original file line numberDiff line numberDiff line change
@@ -35,50 +35,18 @@
3535
# LINUX_MAKE_FLAGS
3636
# Additional flags passed to Make
3737
#
38-
# LINUX_MAKE_USER
39-
# Defined: user build
40-
# Undefined: kernel build
41-
#
4238
# LINUX_MAKE_DIR
4339
# Common makefile location, if it is not ../common
4440
#
4541
#
4642

4743
export DEST_DIR_SUFFIX :=$(subst $(realpath $(SDK))/systems,,$(realpath $(CURDIR)/$(dir ($(firstword $(MAKEFILE_LIST))))))
4844

49-
ifeq (,$(kernel_version))
50-
kernel_version=2_4
51-
endif
52-
53-
ifndef LINUX_MAKE_SHARED_LIB
54-
LINUX_MAKE_SHARED_LIB=0
55-
endif
56-
57-
ifeq (,$(SHAREDLIBVER))
58-
SHAREDLIBVER=1
59-
endif
60-
61-
ifndef LINUX_MAKE_DIR
62-
ifdef LINUX_MAKE_USER
63-
LINUX_MAKE_DIR := $(SDK)/systems/linux/user/common
64-
else
65-
LINUX_MAKE_DIR := $(SDK)/systems/linux/kernel/common
66-
endif
67-
endif
68-
69-
ifneq (,$(findstring iproc,$(platform)))
70-
ADD_TO_CFLAGS += -DINCLUDE_MTD
71-
endif
45+
LINUX_MAKE_DIR ?= $(SDK)/systems/linux/user/common
7246

73-
ifdef LINUX_MAKE_USER
74-
CMD = $(LINUX_MAKE_FLAGS) -C $(LINUX_MAKE_DIR) \
75-
platform=$(platform) bldroot_suffix=/$(platform) kernel_version=$(kernel_version) \
76-
LINUX_MAKE_SHARED_LIB=$(LINUX_MAKE_SHARED_LIB) SHAREDLIBVER=$(SHAREDLIBVER)
77-
else
78-
export LINUX_MAKE_KERNEL := 1
79-
CMD = $(LINUX_MAKE_FLAGS) -C $(LINUX_MAKE_DIR) \
80-
platform=$(platform) kernel_version=$(kernel_version)
81-
endif
47+
CMD = $(LINUX_MAKE_FLAGS) -C $(LINUX_MAKE_DIR) \
48+
platform=$(platform) kernel_version=$(kernel_version) \
49+
bldroot_suffix=/$(platform)
8250

8351
ifneq (,$(MIPS_TOOLS_DIR))
8452
CMD += MIPS_TOOLS_DIR=$(MIPS_TOOLS_DIR)

platform/broadcom/saibcm-modules/make/Make.subdirs

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ ifdef QUIET
3636
endif
3737

3838
${subdirs}::
39-
$Q$(MAKE) -C $@ kernel_version=$(kernel_version) LINUX_MAKE_SHARED_LIB=${LINUX_MAKE_SHARED_LIB} SHAREDLIBVER=${SHAREDLIBVER} ${CLEAN_SUBDIRS}
39+
$Q$(MAKE) -C $@ kernel_version=$(kernel_version) ${CLEAN_SUBDIRS}
4040

4141
clean clean_d install distclean::
4242
ifdef QUIET

0 commit comments

Comments
 (0)