-
Notifications
You must be signed in to change notification settings - Fork 16
RMII dual port implementation #91
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
Open
shuchitak
wants to merge
29
commits into
xmos:develop
Choose a base branch
from
shuchitak:feature/dual_phy_feasibility
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
0c3625b
Initial API and test prog
ed-xmos 326c263
Merge branch 'develop' into feature/dual_phy_feasibility
ed-xmos 7e3d4a2
Initial API and pins for dual MAC
ed-xmos 5c44988
Use setup helpers in rmii_ethernet_rt_mac too
ed-xmos d016936
Update initial local dual mac test app
ed-xmos defd772
Fix null pointer issue with init_rx_ports
ed-xmos c2f069d
Initial dual mac basic test
ed-xmos a9eb986
Add support for second RMII PHY in tests
ed-xmos febe6ab
Add extra PHYs to test_dual_basic
ed-xmos 811cc80
More WIP dual rmii eval
ed-xmos a880f7c
Allocate memory pool and queues per ethernet port
ddb1e59
Modified rmii_master_tx_pins to pass forwarding queues
661fcf4
Add support for hp packets
8bf59f9
Fix tx timestamp andlink status update code to work with multiple mac…
cd0c227
Merge develop and resolve conflicts
3983959
Set NUM_ETHERNET_PORTS to 1 by default.
d4339dd
Changes to ensure the existing single port rmii tests are not broken
50c2317
Merge branch 'develop' of github.com:xmos/lib_ethernet into feature/d…
fb50876
Fix test failures
d28e70d
Merge develop and resolve conflicts
ab9645b
Added rmii dual phy forwarding only test
8f4288c
Sync between sim threads by writing to ports
17e9a5c
Use multiprocessing.Pipe for synchronisation between threads
7ab897c
Add filler thread
980fc1b
Remove dependence on NUM_ETHERNET_PORTS define
c05dae7
Pass mac_ports argument to rmii_master_tx_pins()
b3ec298
Remove dependence on NUM_ETHERNET_PORTS define
c9375e6
Removed examples/test_rmii_dual
50230da
review comments
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 hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -6,9 +6,12 @@ void init_rx_client_state(rx_client_state_t client_state[n], unsigned n) | |
| { | ||
| for (unsigned i = 0; i < n; i ++) { | ||
| client_state[i].dropped_pkt_cnt = 0; | ||
| client_state[i].rd_index = 0; | ||
| client_state[i].wr_index = 0; | ||
| client_state[i].status_update_state = STATUS_UPDATE_WAITING; | ||
| for(int p=0; p<MAX_ETHERNET_PORTS; p++) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah this looks like sc_ethernet!
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, all of these need to be arrays of the max supported ethernet ports. |
||
| { | ||
| client_state[i].rd_index[p] = 0; | ||
| client_state[i].wr_index[p] = 0; | ||
| client_state[i].status_update_state[p] = STATUS_UPDATE_WAITING; | ||
| } | ||
| client_state[i].num_etype_filters = 0; | ||
| client_state[i].strip_vlan_tags = 0; | ||
| } | ||
|
|
@@ -18,7 +21,10 @@ void init_tx_client_state(tx_client_state_t client_state[n], unsigned n) | |
| { | ||
| for (unsigned i = 0; i < n; i ++) { | ||
| client_state[i].requested_send_buffer_size = 0; | ||
| client_state[i].send_buffer = null; | ||
| client_state[i].has_outgoing_timestamp_info = 0; | ||
| for(int p=0; p<MAX_ETHERNET_PORTS; p++) | ||
| { | ||
| client_state[i].send_buffer[p] = null; | ||
| client_state[i].has_outgoing_timestamp_info[p] = 0; | ||
| } | ||
| } | ||
| } | ||
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
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.
I don't know yet if this the right thing to do. I'm concerned that forwarded LP traffic may block HP egress traffic from the internal port. However this is all still WIP so just noting that for now.
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.
This is only for testing. I added this cfg function so I could test forwarding in HP queues. One of the test config has the application enable this but its disabled by default. In reality, there must be some other way for the mac to learn what the priority of a forwarding stream is.