-
Notifications
You must be signed in to change notification settings - Fork 3k
EFM32 - Revert IRQ Handling to 5.8.0 #6976
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
Conversation
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.
Reverting is not the solution, because then we'll go back to previous behaviour that was faulty as well.
The issue that was fixed before is checking the pin state after the interrupt has fired. This may cause short pulses to be missed, ergo, the driver needs to start relying on the IRQ flags and just fire those callbacks up the chain.
According to the EFM32PG12-RM there is no other way to decide between a rise and a fall interrupt, because you have only one IRQ-Flag for rise AND fall. Therefore you need (it is mandatory) to check the pin state. So yes, reverting is the solution, because the previous behavior was correct. To prevent missing short pulses (whatever "short" means) you need to redesign the µC itself by adding another register, or use a different one. The registers Perhaps the checking of the pin state could be made faster, but that should be another pull request. |
BTW: What does "make gpio interrupts faster by offloading expected pin state check to user" mean? Where else should the check happen? Just an example to make the code faster: |
And as a closing thought to your remark: yes, saving dynamic memory does matter. This code not only goes into mbed-os, but also into mbed 2, where we have targets with as low as 4kB of RAM. That's where you really need these savings. |
#6984 has been merged for a while now, and fixes this issue. Time to close the ticket? |
Description
Referring to issue #6783 the pull request/commit #2a3d6d4 must be reverted. This commit causes the problem that the rise callback will never be called.
Pull request type