Commit af2bc484 authored by Adrian Sutton's avatar Adrian Sutton Committed by Joshua Gutow

specs: Update channel bank ordering post Canyon

Other changes to make the spec match the current implementation:
* Dropping frames due to timed out channels or duplication is only done for channels that have not yet been pruned from the channel bank.
* Timed out channels are only pruned from the channel-bank if they are prior to a readable channel.
* Explicitly state that channels are removed from the channel-bank when they are read.
parent 0157165d
......@@ -513,11 +513,14 @@ New frames for timed-out channels are dropped instead of buffered.
#### Reading
The channel-bank can only output data from the first opened channel.
Upon reading, while the first opened channel is timed-out, remove it from the channel-bank.
Once the first opened channel, if any, is not timed-out and is ready, then it is read and removed from the channel-bank.
Prior to the Canyon network upgrade, once the first opened channel, if any, is not timed-out and is ready,
then it is read and removed from the channel-bank. After the Canyon network upgrade, the entire channel bank
is scanned in FIFO order (by open time) & the first ready (i.e. not timed-out) channel will be returned.
The canyon behavior will activate when frames from a L1 block whose timestamp is greater than or equal to the
canyon time first enter the channel queue.
A channel is ready if:
......@@ -534,7 +537,7 @@ a new channel is opened, tagged with the current L1 block, and appended to the c
Frame insertion conditions:
- New frames matching timed-out channels that have not yet been pruned from the channel-bank are dropped.
- Duplicate frames (by frame number) for frames that have not yet been pruned from the channel-bank are dropped.
- Duplicate frames (by frame number) for frames that have not been pruned from the channel-bank are dropped.
- Duplicate closes (new frame `is_last == 1`, but the channel has already seen a closing frame and has not yet been
pruned from the channel-bank) are dropped.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment