Stefano Voulaz
2011-05-24 12:08:03 UTC
Hello gurus,
I'm facing a nasty deadlock issue while resuming a CE 6.0 R3 device after suspend. The problem occurs only if OHCD driver is included in the image and when the system is suspended while an application is running from a storage device (i.e., NAND or SD) and accessing data on it.
Since the USB host controller does not support HCD_SUSPEND_RESUME (but only HCD_SUSPEND_ON_REQUEST), OHCD resume code - located in public\common\oak\drivers\usb\hcd\ohcd2\chw.cpp, function CHW::CeResumeThread() - simply reinitializes the controller.
During this process, the registry key [HKLM\ShimEngine] is accessed (unloading the library) while the file system is [possibly] locked on an acces performed by the application running from the storage device - whose volume has not been remounted yet. So the deadlock.
The same problem does not happen if the application relies only on RAM file system.
Any suggestion on where to go from here?
Thank you in advance - Stefano
I'm facing a nasty deadlock issue while resuming a CE 6.0 R3 device after suspend. The problem occurs only if OHCD driver is included in the image and when the system is suspended while an application is running from a storage device (i.e., NAND or SD) and accessing data on it.
Since the USB host controller does not support HCD_SUSPEND_RESUME (but only HCD_SUSPEND_ON_REQUEST), OHCD resume code - located in public\common\oak\drivers\usb\hcd\ohcd2\chw.cpp, function CHW::CeResumeThread() - simply reinitializes the controller.
During this process, the registry key [HKLM\ShimEngine] is accessed (unloading the library) while the file system is [possibly] locked on an acces performed by the application running from the storage device - whose volume has not been remounted yet. So the deadlock.
The same problem does not happen if the application relies only on RAM file system.
Any suggestion on where to go from here?
Thank you in advance - Stefano