This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: How to debug synchronisation in the usbs.c in a new usb-driver for the ARM at91sam7s...


I think the porblem is, that the condition-variable dont hold the signal. Only a thread in the wait, waits for the signal. If the DSR starts between the while() compare an the wait, the signal get loosed:


... while (!wait.completed) { DSR start not alowed cyg_drv_cond_wait(&wait.signal); ....


Thanks for the hints...


----- Original Message ----- From: "Andrew Lunn" <andrew@lunn.ch>
To: "Derek Bouius" <derek.bouius@sympatico.ca>
Cc: <andrew@lunn.ch>; <munz@speag.ch>; <ecos-discuss@sourceware.org>
Sent: Thursday, February 16, 2006 5:25 PM
Subject: Re: [ECOS] How to debug synchronisation in the usbs.c in a new usb-driver for the ARM at91sam7s...



On Thu, Feb 16, 2006 at 11:15:25AM -0500, Derek Bouius wrote:

I am not registered for the mailing list, but peruse it once in a
while, so I am not sure if my mail will go through to it. Feel free
to repost it if it doesn't.

It got through.


What we did to fix the locking issue was change the mutex to a
semaphore. See the patch. It seems to work reliably.

Did you understand what the problem was with the condition variable? Could you explain it?

       Thanks
               Andrew





--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]