diff --git a/bsp/nuvoton/libraries/m2354/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/m2354/rtt_port/drv_usbhost.c index 2e734253c39..12a2d44a1ac 100644 --- a/bsp/nuvoton/libraries/m2354/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/m2354/rtt_port/drv_usbhost.c @@ -802,8 +802,7 @@ static rt_err_t usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mo { case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK); diff --git a/bsp/nuvoton/libraries/m460/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/m460/rtt_port/drv_usbhost.c index 0bd7b6f3c13..2e8656d1c24 100644 --- a/bsp/nuvoton/libraries/m460/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/m460/rtt_port/drv_usbhost.c @@ -819,7 +819,7 @@ static int usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mode) case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK); diff --git a/bsp/nuvoton/libraries/m480/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/m480/rtt_port/drv_usbhost.c index 01d728e1afa..034b8c9f23b 100644 --- a/bsp/nuvoton/libraries/m480/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/m480/rtt_port/drv_usbhost.c @@ -805,7 +805,7 @@ static rt_err_t usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mo case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK); diff --git a/bsp/nuvoton/libraries/ma35/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/ma35/rtt_port/drv_usbhost.c index 3ba41bd8e75..f12238cf6b9 100644 --- a/bsp/nuvoton/libraries/ma35/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/ma35/rtt_port/drv_usbhost.c @@ -845,7 +845,7 @@ static int usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mode) case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK); diff --git a/bsp/nuvoton/libraries/n9h30/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/n9h30/rtt_port/drv_usbhost.c index 32ef34800b8..71df779bbc3 100644 --- a/bsp/nuvoton/libraries/n9h30/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/n9h30/rtt_port/drv_usbhost.c @@ -902,7 +902,7 @@ static int usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mode) case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK); diff --git a/bsp/nuvoton/libraries/nuc980/rtt_port/drv_usbhost.c b/bsp/nuvoton/libraries/nuc980/rtt_port/drv_usbhost.c index 2b080604f85..472afa36250 100644 --- a/bsp/nuvoton/libraries/nuc980/rtt_port/drv_usbhost.c +++ b/bsp/nuvoton/libraries/nuc980/rtt_port/drv_usbhost.c @@ -902,7 +902,7 @@ static int usbhost_pm_suspend(const struct rt_device *device, rt_uint8_t mode) case PM_SLEEP_MODE_LIGHT: case PM_SLEEP_MODE_DEEP: - pNuUSBHDev->polling_thread->stat = RT_THREAD_READY; + RT_SCHED_CTX(pNuUSBHDev->polling_thread).stat = RT_THREAD_READY; result = rt_thread_suspend(pNuUSBHDev->polling_thread); RT_ASSERT(result == RT_EOK);