mirror of
https://github.com/apache/nuttx.git
synced 2026-08-20 23:49:05 +08:00
drivers/mmcsd/mmcsd_sdio.c: guard SDIO_REGISTERCALLBACK use
SDIO_REGISTERCALLBACK is only defined when both CONFIG_SCHED_WORKQUEUE and CONFIG_SCHED_HPWORK are enabled. Guard the callback registration call in mmcsd_sdio.c so the source matches the SDIO callback API availability and avoids build issues when HPWORK support is not configured. Signed-off-by: Jerry Ma <shichunma@bestechnic.com>
This commit is contained in:
@@ -4509,7 +4509,9 @@ static int mmcsd_hwinitialize(FAR struct mmcsd_state_s *priv)
|
||||
* removed from the slot (Initially all callbacks are disabled).
|
||||
*/
|
||||
|
||||
#if defined(CONFIG_SCHED_WORKQUEUE) && defined(CONFIG_SCHED_HPWORK)
|
||||
SDIO_REGISTERCALLBACK(priv->dev, mmcsd_mediachange, (FAR void *)priv);
|
||||
#endif
|
||||
|
||||
/* Is there a card in the slot now? For an MMC/SD card, there are three
|
||||
* possible card detect mechanisms:
|
||||
|
||||
Reference in New Issue
Block a user