diff options
Diffstat (limited to 'os/hal/src')
-rw-r--r-- | os/hal/src/mmc_spi.c | 11 | ||||
-rw-r--r-- | os/hal/src/sdc.c | 4 |
2 files changed, 8 insertions, 7 deletions
diff --git a/os/hal/src/mmc_spi.c b/os/hal/src/mmc_spi.c index ee33ee618..babbf80ad 100644 --- a/os/hal/src/mmc_spi.c +++ b/os/hal/src/mmc_spi.c @@ -169,7 +169,7 @@ static void wait(MMCDriver *mmcp) { break;
#ifdef MMC_NICE_WAITING
/* Trying to be nice with the other threads.*/
- chThdSleep(1);
+ osalThreadSleep(1);
#endif
}
}
@@ -348,7 +348,8 @@ static void sync(MMCDriver *mmcp) { if (buf[0] == 0xFF)
break;
#ifdef MMC_NICE_WAITING
- chThdSleep(1); /* Trying to be nice with the other threads.*/
+ /* Trying to be nice with the other threads.*/
+ osalThreadSleep(1);
#endif
}
spiUnselect(mmcp->config->spip);
@@ -460,7 +461,7 @@ bool mmcConnect(MMCDriver *mmcp) { break;
if (++i >= MMC_CMD0_RETRY)
goto failed;
- chThdSleepMilliseconds(10);
+ osalThreadSleepMilliseconds(10);
}
/* Try to detect if this is a high capacity card and switch to block
@@ -480,7 +481,7 @@ bool mmcConnect(MMCDriver *mmcp) { if (++i >= MMC_ACMD41_RETRY)
goto failed;
- chThdSleepMilliseconds(10);
+ osalThreadSleepMilliseconds(10);
}
/* Execute dedicated read on OCR register */
@@ -501,7 +502,7 @@ bool mmcConnect(MMCDriver *mmcp) { goto failed;
if (++i >= MMC_CMD1_RETRY)
goto failed;
- chThdSleepMilliseconds(10);
+ osalThreadSleepMilliseconds(10);
}
/* Initialization complete, full speed.*/
diff --git a/os/hal/src/sdc.c b/os/hal/src/sdc.c index ef96c6a9b..d8e469e82 100644 --- a/os/hal/src/sdc.c +++ b/os/hal/src/sdc.c @@ -86,7 +86,7 @@ bool _sdc_wait_for_transfer_state(SDCDriver *sdcp) { case MMCSD_STS_RCV:
case MMCSD_STS_PRG:
#if SDC_NICE_WAITING
- osalThreadSleep(MS2ST(1));
+ osalThreadSleep(OSAL_MS2ST(1));
#endif
continue;
default:
@@ -262,7 +262,7 @@ bool sdcConnect(SDCDriver *sdcp) { }
if (++i >= SDC_INIT_RETRY)
goto failed;
- osalThreadSleep(MS2ST(10));
+ osalThreadSleep(OSAL_MS2ST(10));
}
}
|