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

Solve Race Condition in ATA #83

Open
dthain opened this issue Dec 14, 2017 · 0 comments
Open

Solve Race Condition in ATA #83

dthain opened this issue Dec 14, 2017 · 0 comments
Labels

Comments

@dthain
Copy link
Owner

dthain commented Dec 14, 2017

When issuing an ata/atapi read/write, the ata driver should generally call process_wait() to wait for an interrupt to arrive. However, on "fast" virtual hardware, the interrupt is often delivered even before process_wait() has been called. Hence, the current code has these waits commented out, and just does a busy-wait on drive status.

Fix the race condition by blocking interrupts in the critical section, so that we can properly handle "slow" real hardware without busy waiting.

See PR #72 for an instance of the problem and PR #82 for the temporary workaround.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants