1
0
Fork 0
forked from len0rd/rockbox

ata_hard_reset should be synchronized.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17397 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Michael Sevakis 2008-05-06 10:12:05 +00:00
parent 6edb95d050
commit 35e7b25472

View file

@ -956,6 +956,8 @@ int ata_hard_reset(void)
{
int ret;
mutex_lock(&ata_mtx);
ata_reset();
/* state HRR2 */
@ -965,6 +967,8 @@ int ata_hard_reset(void)
/* Massage the return code so it is 0 on success and -1 on failure */
ret = ret?0:-1;
mutex_unlock(&ata_mtx);
return ret;
}