소스 검색

[drivers][spi] Fixed an issue that caused spi bus deadlock in the spi configuration

Yuqiang Wang 1 년 전
부모
커밋
9b31631df1
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      components/drivers/spi/dev_spi_core.c

+ 1 - 1
components/drivers/spi/dev_spi_core.c

@@ -111,7 +111,7 @@ rt_err_t rt_spi_bus_configure(struct rt_spi_device *device)
                 /* RT_EBUSY is not an error condition and
                 /* RT_EBUSY is not an error condition and
                  * the configuration will take effect once the device has the bus
                  * the configuration will take effect once the device has the bus
                  */
                  */
-                return -RT_EBUSY;
+                result = -RT_EBUSY;
             }
             }
 
 
             /* release lock */
             /* release lock */