Dataplane telemetry support in SONiC#328
Conversation
Rel 6 0 telemetry
… non-bfn platforms
syncd/Makefile.am
Outdated
| if SAITHRIFT | ||
| syncd_CPPFLAGS += -DSAITHRIFT=yes | ||
| syncd_LDADD += -lrpcserver -lthrift | ||
| #syncd_LDADD += -lthrift |
There was a problem hiding this comment.
remove this commented line.
habeebmohammed
left a comment
There was a problem hiding this comment.
Job well done! All the code looks good. Coding style is consistent.
| else | ||
| if sonic_asic_platform_barefoot | ||
| SAILIB=-L/opt/bfn/install/lib -lswitchsai -lswitchapi -lbf_switchd_lib -ltofinopdfixed_thrift -ldriver -lbfutils -lbfsys -lbfutils -L/opt/bfn/install/lib/tofinopd/switch -lpd -lpdcli -lpdthrift | ||
| else |
There was a problem hiding this comment.
remove library other than the sai package.
dproc
left a comment
There was a problem hiding this comment.
The dtel related part looks good to me
|
Can you resolve the conflict? |
lib/src/sai_redis_bridge.cpp
Outdated
| } | ||
|
|
||
| sai_status_t redis_clear_bridge_stats( | ||
| sai_status_t redis_get_bridge_stats_ext( |
There was a problem hiding this comment.
i am not sure this needs to be modified.
vslib/src/sai_vs_dtel.cpp
Outdated
|
|
||
| const sai_dtel_api_t vs_dtel_api = { | ||
|
|
||
| VS_GENERIC_QUAD_API(dtel) |
There was a problem hiding this comment.
can you convert all tabs to spaces?
syncd/Makefile.am
Outdated
| else | ||
| if sonic_asic_platform_barefoot | ||
| AM_CPPFLAGS += -I/opt/bfn/install/include | ||
| SAILIB=-L/opt/bfn/install/lib -lswitchsai -lswitchapi -lbf_switchd_lib -ltofinopdfixed_thrift -ldriver -lbfutils -lbfsys -lbfutils -L/opt/bfn/install/lib/tofinopd/switch -lpd -lpdcli -lpdthrift |
…ibraries linked at compile time (#6) * Link only bfn sai lib * all unresolved symbols resolved at runtime * Preload some bfn libraries on syncd startup * Build fix * also remove commented code
lib/src/sai_redis_dtel.cpp
Outdated
|
|
||
| const sai_dtel_api_t redis_dtel_api = { | ||
|
|
||
| REDIS_GENERIC_QUAD_API(dtel) |
saisdkdump/Makefile.am
Outdated
| SAILIB=-L$(top_srcdir)/vslib/src/.libs -lsaivs | ||
| else | ||
| if sonic_asic_platform_barefoot | ||
| SAILIB=-L/opt/bfn/install/lib -lswitchsai -lswitchapi -lbf_switchd_lib -ltofinopdfixed_thrift -ldriver -lbfutils -lbfsys -lbfutils -L/opt/bfn/install/lib/tofinopd/switch -lpd -lpdcli -lpdthrift |
There was a problem hiding this comment.
remove library other than the sai package.
syncd/scripts/syncd_init_common.sh
Outdated
| export ONIE_PLATFORM=`grep onie_platform /etc/machine.conf | awk 'BEGIN { FS = "=" } ; { print $2 }'` | ||
| export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/bfn/install/lib/platform/$ONIE_PLATFORM:/opt/bfn/install/lib:/opt/bfn/install/lib/tofinopd/switch | ||
| . /opt/bfn/install/bin/dma_setup.sh | ||
| export LD_PRELOAD=libswitchapi.so:libswitchsai.so:libpd.so:libpdcli.so:libdriver.so:libbfsys.so:libbfutils.so:libbf_switchd_lib.so:libtofinopdfixed_thrift.so:libpdthrift.so |
There was a problem hiding this comment.
alignment here is not consistent.
| return SAI_STATUS_NOT_IMPLEMENTED; | ||
| } | ||
|
|
||
| sai_status_t vs_get_policer_stats_ext( |
There was a problem hiding this comment.
this one should replace vs_sai_get_policer_stats_ext
Please remove vs_sai_get_policer_stats_ext above.
* BFN: link with just sai library for saisdkdump
* initial barefoot checkin october 2017 * Revert "Merge branch 'master' of https://github.com/Azure/sonic-sairedis into rel_6_0" This reverts commit c48a7a2, reversing changes made to aa5bf64. * missed integration diffs * Added new attr type support to sairedis. Also, some fixes for compilation issues * Changes to add new DTel api support in sairedis * Add new file to generate Dtel specific SAI stub API * Missed adding a file in the last commit * Fix ref point for SAI * Updated SAI repo to point to dtel_exp * Changes to handle new additions to DTel experimental SAI. Not compiled yet * handle platform specific lins in different directory (@runtime) * force order of library path to look for platform dir before lib dir * Change SAI branch refpoint * Update SAI submodule refpoint * enable fast-boot for barefoot platforms * Update ref point for SAI * SONiC changes due to DTel experimental SAI changes * allow Makefile to build for other platforms - restore it original for non-bfn platforms * allow clean build * Revert "allow clean build" This reverts commit adfdb86. * Revert "allow Makefile to build for other platforms - restore it original for non-bfn platforms" This reverts commit d6b0ca3. * makefile cleanup towards upstream * Support for platforms based on Barefoot Networks' device (sonic-net#304) * search for exact string - newer onie versions match multiple lines * Will need to revert this Should work without this change. Untested for now * SONiC sairedis changes needed to work with SAIv1.3 * Fix SAI path in gitmodules and add a comment * Remove sai thrift build hack * enable fast-boot for barefoot platforms * enable fast-boot for barefoot platforms * Add missing sai rpc hdr file path for bfn * Update SAI ref points * Multi p4 profile support for bfn sde (sonic-net#5) * Remove code duplicated in merge * Keep fn in same order as azure master (sonic-net#8) * Address review comment * Link just bfn sai lib and shorten linking command by removing other libraries linked at compile time (sonic-net#6) * Link only bfn sai lib * all unresolved symbols resolved at runtime * Preload some bfn libraries on syncd startup * Build fix * also remove commented code * Convert tabs to spaces * Fix alignment * Address upstream comment * BFN: link with just sai library for saisdkdump * Address review comments
* initial barefoot checkin october 2017 * Revert "Merge branch 'master' of https://github.com/Azure/sonic-sairedis into rel_6_0" This reverts commit c48a7a2, reversing changes made to aa5bf64. * missed integration diffs * Added new attr type support to sairedis. Also, some fixes for compilation issues * Changes to add new DTel api support in sairedis * Add new file to generate Dtel specific SAI stub API * Missed adding a file in the last commit * Fix ref point for SAI * Updated SAI repo to point to dtel_exp * Changes to handle new additions to DTel experimental SAI. Not compiled yet * handle platform specific lins in different directory (@runtime) * force order of library path to look for platform dir before lib dir * Change SAI branch refpoint * Update SAI submodule refpoint * enable fast-boot for barefoot platforms * Update ref point for SAI * SONiC changes due to DTel experimental SAI changes * allow Makefile to build for other platforms - restore it original for non-bfn platforms * allow clean build * Revert "allow clean build" This reverts commit adfdb86. * Revert "allow Makefile to build for other platforms - restore it original for non-bfn platforms" This reverts commit d6b0ca3. * makefile cleanup towards upstream * Support for platforms based on Barefoot Networks' device (sonic-net#304) * search for exact string - newer onie versions match multiple lines * Will need to revert this Should work without this change. Untested for now * SONiC sairedis changes needed to work with SAIv1.3 * Fix SAI path in gitmodules and add a comment * Remove sai thrift build hack * enable fast-boot for barefoot platforms * enable fast-boot for barefoot platforms * Add missing sai rpc hdr file path for bfn * Update SAI ref points * Multi p4 profile support for bfn sde (sonic-net#5) * Remove code duplicated in merge * Keep fn in same order as azure master (sonic-net#8) * Address review comment * Link just bfn sai lib and shorten linking command by removing other libraries linked at compile time (sonic-net#6) * Link only bfn sai lib * all unresolved symbols resolved at runtime * Preload some bfn libraries on syncd startup * Build fix * also remove commented code * Convert tabs to spaces * Fix alignment * Address upstream comment * BFN: link with just sai library for saisdkdump * Address review comments
This includes changes to make SONiC work with SAIv 1.3, as DTel API support is only in v 1.3. These changes can be reverted when official SONiC support for v1.3 is added.
Design for the feature is at:
sonic-net/SONiC#182