sync_channel rework #52 #53

Merged
sb10q merged 1 commits from pca006132/zynq-rs:sync into master 2020-07-28 12:38:20 +08:00

The channels are now basically static.
Now uses macro to construct the sync_channel, cannot think of a better way.

The channels are now basically static. Now uses macro to construct the sync_channel, cannot think of a better way.
pca006132 changed title from WIP: sync_channel rework #52 to sync_channel rework #52 2020-07-28 11:54:05 +08:00

Tested in experiments, seems working.

Tested in experiments, seems working.
sb10q reviewed 2020-07-28 12:28:21 +08:00
@ -9,6 +10,7 @@ pub mod regs;
pub mod cache;
pub mod mmu;
pub mod mutex;
#[macro_use]

IMO the regular use statements are better than macro_use.

IMO the regular ``use`` statements are better than ``macro_use``.
sb10q reviewed 2020-07-28 12:30:14 +08:00
@ -215,3 +217,3 @@
// match stream.send((0..=255).cycle().take(CHUNK_SIZE)).await {
match stream.send_slice(&tx_data[..]).await {
Ok(len) => stats_tx.borrow_mut().1 += tx_data.len(), //CHUNK_SIZE,
Ok(_) => stats_tx.borrow_mut().1 += tx_data.len(), //CHUNK_SIZE,

unrelated change

unrelated change
sb10q reviewed 2020-07-28 12:32:02 +08:00
@ -226,2 +154,4 @@
}
}
#[macro_export]
https://doc.rust-lang.org/edition-guide/rust-2018/macros/macro-changes.html

Apart from those nitpicks LGTM.

Apart from those nitpicks LGTM.

Apart from those nitpicks LGTM.

Fixed.

> Apart from those nitpicks LGTM. Fixed.
sb10q closed this pull request 2020-07-28 12:38:20 +08:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: M-Labs/zynq-rs#53
There is no content yet.