-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New p4 platform based on SAI behavioral model software switch #1105
Closed
Closed
Changes from 9 commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
336b453
removed p4 behavioral model and p4 switch
9637e30
updated SAI-P4 commit
1169e32
updated SAI-P4-BM commit and updated p4 mk files
154d033
updated docker sonic p4 with scripts and config. restored p4c-bm to a…
e45ba75
added p4-hlir-v1.1 submodule
4ebfcdc
Update README.md
cff0b77
updated SAI-P4-BM commit
2958361
Merge remote-tracking branch 'refs/remotes/origin/1.0.3' into 1.0.3
6b17880
updated SAI-P4-BM module
3a9a475
updated git modules to https
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,33 @@ | ||
# alias lanes | ||
Ethernet0 1 | ||
Ethernet1 2 | ||
Ethernet2 3 | ||
Ethernet3 4 | ||
Ethernet0 0 | ||
Ethernet1 1 | ||
Ethernet2 2 | ||
Ethernet3 3 | ||
Ethernet4 4 | ||
Ethernet5 5 | ||
Ethernet6 6 | ||
Ethernet7 7 | ||
Ethernet8 8 | ||
Ethernet9 9 | ||
Ethernet10 10 | ||
Ethernet11 11 | ||
Ethernet12 12 | ||
Ethernet13 13 | ||
Ethernet14 14 | ||
Ethernet15 15 | ||
Ethernet16 16 | ||
Ethernet17 17 | ||
Ethernet18 18 | ||
Ethernet19 19 | ||
Ethernet20 20 | ||
Ethernet21 21 | ||
Ethernet22 22 | ||
Ethernet23 23 | ||
Ethernet24 24 | ||
Ethernet25 25 | ||
Ethernet26 26 | ||
Ethernet27 27 | ||
Ethernet28 28 | ||
Ethernet29 29 | ||
Ethernet30 30 | ||
Ethernet31 31 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/sh | ||
# handler() | ||
# { | ||
# kill -s INT $ROUTER_PID | ||
# kill -s INT $BRIDGE_PID | ||
# } | ||
|
||
set -m | ||
ip netns exec sw_net simple_switch -i 0@router_port1 -i 250@router_cpu_port --thrift-port 9091 --log-file /tmp/router_log --log-flush --notifications-addr ipc:///tmp/bmv2-router-notifications.ipc /usr/share/p4-sai-bm/sai_router.json & | ||
export ROUTER_PID=$! | ||
ip netns exec sw_net simple_switch -i 0@sw_port0 -i 1@sw_port1 -i 2@sw_port2 -i 3@sw_port3 -i 4@sw_port4 -i 5@sw_port5 -i 6@sw_port6 -i 7@sw_port7 -i 7@sw_port7 -i 8@sw_port8 -i 9@sw_port9 -i 10@sw_port10 -i 11@sw_port11 -i 12@sw_port12 -i 13@sw_port13 -i 14@sw_port14 -i 15@sw_port15 -i 16@sw_port16 -i 17@sw_port17 -i 18@sw_port18 -i 19@sw_port19 -i 20@sw_port20 -i 21@sw_port21 -i 22@sw_port22 -i 23@sw_port23 -i 24@sw_port24 -i 25@sw_port25 -i 26@sw_port26 -i 27@sw_port27 -i 28@sw_port28 -i 29@sw_port29 -i 30@sw_port30 -i 31@sw_port31 -i 250@cpu_port -i 251@router_port0 --log-file /tmp/bridge_log --log-flush /usr/share/p4-sai-bm/sai_bridge.json & | ||
export BRIDGE_PID=$! | ||
sleep 10 | ||
simple_switch_CLI --pre SimplePreLAG < /usr/share/p4-sai-bm/bridge_default_config.txt | ||
simple_switch_CLI < /usr/share/p4-sai-bm/bridge_default_config_mirror.txt | ||
simple_switch_CLI --pre SimplePreLAG --thrift-port 9091 < /usr/share/p4-sai-bm/router_default_config.txt | ||
simple_switch_CLI --thrift-port 9091 < /usr/share/p4-sai-bm/router_default_config_mirror.txt | ||
|
||
# echo "router and bridge are running send SIGINT to close" | ||
|
||
# trap handler INT | ||
# sleep inf | ||
# sudo kill -s SIGINT 3319 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# p4 bmv package | ||
|
||
P4_BMV = p4-bmv2_1.0.0_amd64.deb | ||
$(P4_BMV)_DEPENDS += $(LIBTHRIFT_DEV) $(PYTHON_THRIFT) $(THRIFT_COMPILER) | ||
P4_BMV = sai-p4-bm_1.0.0_amd64.deb | ||
$(P4_BMV)_DEPENDS += $(LIBTHRIFT_DEV) $(PYTHON_THRIFT) $(THRIFT_COMPILER) $(P4C_BM) | ||
$(P4_BMV)_RDEPENDS += $(LIBTHRIFT) $(PYTHON_THRIFT) $(THRIFT_COMPILER) | ||
$(P4_BMV)_SRC_PATH = $(PLATFORM_PATH)/p4-bmv/behavioral-model | ||
$(P4_BMV)_SRC_PATH = $(PLATFORM_PATH)/SAI-P4-BM/p4-switch | ||
SONIC_DPKG_DEBS += $(P4_BMV) |
Submodule behavioral-model
deleted from
a6ccf2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
# p4 bmv package | ||
|
||
P4_HLIR_V1_1 = python-p4-hlir-v1-1_1.1.7-1_all.deb | ||
$(P4_HLIR_V1_1)_SRC_PATH = $(PLATFORM_PATH)/p4-hlir/p4-hlir-v1.1 | ||
SONIC_PYTHON_STDEB_DEBS += $(P4_HLIR_V1_1) | ||
|
||
P4_HLIR = python-p4-hlir_0.9.36-1_all.deb | ||
$(P4_HLIR)_SRC_PATH = $(PLATFORM_PATH)/p4-hlir/p4-hlir | ||
SONIC_PYTHON_STDEB_DEBS += $(P4_HLIR) |
Submodule p4-hlir-v1.1
added at
fdee55
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# p4 switch package | ||
# p4 sai adapter package | ||
|
||
P4_SWITCH = p4-switch_1.0.0_amd64.deb | ||
$(P4_SWITCH)_DEPENDS += $(P4C_BM) $(P4_BMV) | ||
$(P4_SWITCH)_RDEPENDS += $(P4C_BM) $(P4_BMV) | ||
$(P4_SWITCH)_SRC_PATH = $(PLATFORM_PATH)/p4-switch | ||
SONIC_MAKE_DEBS += $(P4_SWITCH) | ||
P4_SWITCH = p4-sai-adapter_0.1-0_amd64.deb | ||
$(P4_SWITCH)_DEPENDS += $(LIBTHRIFT_DEV) $(PYTHON_THRIFT) $(THRIFT_COMPILER) $(P4_BMV) | ||
$(P4_SWITCH)_RDEPENDS += $(LIBTHRIFT) $(PYTHON_THRIFT) $(THRIFT_COMPILER) $(P4_BMV) | ||
$(P4_SWITCH)_SRC_PATH = $(PLATFORM_PATH)/SAI-P4-BM/sai_adapter | ||
SONIC_DPKG_DEBS += $(P4_SWITCH) |
This file was deleted.
Oops, something went wrong.
Submodule switch
deleted from
e93475
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be https://github.com/p4lang/p4-hlir.git