Skip to content
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ AX_CODE_COVERAGE
AX_ADD_AM_MACRO_STATIC([])

AM_CONDITIONAL(SONIC_ASIC_PLATFORM_BAREFOOT, test x$CONFIGURED_PLATFORM = xbarefoot)
AM_CONDITIONAL(SONIC_ASIC_PLATFORM_BROADCOM, test x$CONFIGURED_PLATFORM = xbroadcom)

AC_ARG_ENABLE(debug,
[ --enable-debug turn on debugging],
Expand Down
48 changes: 48 additions & 0 deletions meta/SaiInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,3 +197,51 @@ sai_status_t SaiInterface::get(
return SAI_STATUS_FAILURE;
}
}

sai_status_t SaiInterface::switchMdioRead(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_Out_ uint32_t *reg_val)
{
SWSS_LOG_ENTER();

return SAI_STATUS_FAILURE;
}

sai_status_t SaiInterface::switchMdioWrite(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_In_ const uint32_t *reg_val)
{
SWSS_LOG_ENTER();

return SAI_STATUS_FAILURE;
}

sai_status_t SaiInterface::switchMdioCl22Read(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_Out_ uint32_t *reg_val)
{
SWSS_LOG_ENTER();

return SAI_STATUS_FAILURE;
}

sai_status_t SaiInterface::switchMdioCl22Write(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_In_ const uint32_t *reg_val)
{
SWSS_LOG_ENTER();

return SAI_STATUS_FAILURE;
}
28 changes: 28 additions & 0 deletions meta/SaiInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,34 @@ namespace sairedis
_In_ uint32_t attrCount,
_In_ const sai_attribute_t *attrList) = 0;

virtual sai_status_t switchMdioRead(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_Out_ uint32_t *reg_val);

virtual sai_status_t switchMdioWrite(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_In_ const uint32_t *reg_val);

virtual sai_status_t switchMdioCl22Read(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_Out_ uint32_t *reg_val);

virtual sai_status_t switchMdioCl22Write(
_In_ sai_object_id_t switch_id,
_In_ uint32_t device_addr,
_In_ uint32_t start_reg_addr,
_In_ uint32_t number_of_registers,
_In_ const uint32_t *reg_val);

public: // SAI API

virtual sai_status_t objectTypeGetAvailability(
Expand Down
5 changes: 5 additions & 0 deletions syncd/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ libSyncd_a_SOURCES = \
FlexCounterManager.cpp \
GlobalSwitchId.cpp \
HardReiniter.cpp \
MdioIpcServer.cpp \
MetadataLogger.cpp \
NotificationHandler.cpp \
NotificationProcessor.cpp \
Expand Down Expand Up @@ -71,6 +72,10 @@ syncd_CXXFLAGS += -DSAITHRIFT=yes
syncd_LDADD += -lrpcserver -lthrift
endif

if SONIC_ASIC_PLATFORM_BROADCOM
libSyncd_a_CXXFLAGS += -DMDIO_ACCESS_USE_NPU
endif

libSyncdRequestShutdown_a_SOURCES = \
RequestShutdown.cpp \
RequestShutdownCommandLineOptions.cpp \
Expand Down
Loading