Skip to content
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

Tracking: improvements to async_channel for MPMC and fault recovery #715

Open
2 of 3 tasks
amab8901 opened this issue Dec 5, 2022 · 2 comments
Open
2 of 3 tasks
Assignees
Labels
enhancement tracking an issue or PR used for tracking purposes only

Comments

@amab8901
Copy link
Contributor

amab8901 commented Dec 5, 2022

Checklist:

  • Properly track sender and receiver counts (Mark async_channel as disconnected only when the last Sender or the last Receiver is dropped #707, solves async_channel marks itself as disconnected too eagerly #703)
  • add Receiver::obtain_sender() and Sender::obtain_receiver() methods to enable channel to recover from disconnection
  • add test scenarios to applications/test_channel
    • the clone method on Sender/Receiver
    • dropping a Sender or Receiver when multiple ones exist already, rather than just a single one.
    • Trying to send to or receive from a disconnected channel
    • Whether the Receiver::sender() and Sender::receiver() methods properly change the Channel's state in the case of multiple endpoints or a single endpoint.
    • Actually recovering from a channel disconnection using the above methods and then successfully sending and/or receiving through the channel
    • Anything with more than two tasks -- a common use case would be to have several sending tasks and several receiving tasks, so we want to test whether that works properly.
@kevinaboos kevinaboos changed the title Need to count number of senders and receivers Maintain count of senders and receivers in async_channel Dec 5, 2022
@kevinaboos kevinaboos added enhancement tracking an issue or PR used for tracking purposes only labels Dec 15, 2022
@kevinaboos kevinaboos changed the title Maintain count of senders and receivers in async_channel Tracking: improvements to async_channel for MPMC and fault recovery Dec 15, 2022
@amab8901
Copy link
Contributor Author

amab8901 commented Dec 27, 2022

I run make run in terminal. After it finished loading everything, I press any arbitary button on the keyboard and here is the output:

[W] kernel/console/src/lib.rs:53: Currently ignoring inputs on serial port COM1. 
 --> Note: QEMU is forwarding control sequences (like Ctrl+C) to Theseus. To exit QEMU, press Ctrl+A then X.

I think I'm supposed to use the Theseus terminal for running the tests (which helps me add the test scenarios correctly). How do I run the tests on Theseus terminal?

@kevinaboos
Copy link
Member

You're typing in the host terminal, which is what Theseus is using to print its log to (over the virtual serial port). You want to type in the graphical terminal that shows up within a QEMU window.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement tracking an issue or PR used for tracking purposes only
Projects
None yet
Development

No branches or pull requests

2 participants