Bug 57014
Summary: | Starvation in cyg_libc_stdio_flush_all_but()? | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] eCos | Reporter: | Andrew Lunn <andrew.lunn> | ||||||
Component: | C library | Assignee: | Jonathan Larmour <jlarmour> | ||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Jonathan Larmour <jlarmour> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | medium | ||||||||
Version: | 1.5.2 | CC: | acnrf, alexs | ||||||
Target Milestone: | --- | ||||||||
Target Release: | --- | ||||||||
Hardware: | i386 | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2001-12-05 09:53:08 UTC | Type: | --- | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Attachments: |
|
Description
Andrew Lunn
2001-12-03 09:44:12 UTC
[ Ideally I'll need a testcase.... ] I suspect what is required is to replace the mutex "trylock" with a lock when going through the loop a second time. This allows mutex priority inheritance to work properly. I'll look at it closer. Is this a contractual bug report or a contrib one? I suspect the former so I'll treat it as such :-). I submitted this with my Ascom Contract hat on. Created attachment 39408 [details]
Simple test case
It took me a little longer than expected (I got bogged down trying to get debug hardware to work right), but this should hopefully solve it. I've tried it with your test case (with the cyg_thread_delay in worker() removed, to give it proper effect) and it appears happy. Can you confirm? Created attachment 39647 [details]
Here is the patch
Yes, the patch solves the problem. Thanks. Great. I checked the patch into our CVS server at Solothurn. |