diff options
author | Tom Rini <trini@konsulko.com> | 2021-04-09 13:10:59 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-04-09 13:10:59 -0400 |
commit | 3f2e3c7845df11ca8359a6cc804bfd6eb5ce215b (patch) | |
tree | 423c18c94b1e62122f8988b94668bada1b85340b /board/st/stm32mp1/stm32mp1.c | |
parent | 92c4eb7ae3e8fe2c2b3c5b37f882b42282a08e84 (diff) | |
parent | 2c2d7d6a72ba4a4f9323f24b8caa3b1e05546d83 (diff) |
Merge tag 'u-boot-stm32-20210409' of https://source.denx.de/u-boot/custodians/u-boot-stm
Add rt-thread art-pi board support based on STM32H750 SoC
Add Engicam i.Core STM32MP1 SoM
Add FIP header support for STM32programmer
Update uart number when no serial device found for STM32MP1
Remove board_check_usb_power function when ADC flag is not set
Update SPL size limitation for STM32MP1
Set soc_type, soc_pkg, soc_rev env variables for STM32MP1
Diffstat (limited to 'board/st/stm32mp1/stm32mp1.c')
-rw-r--r-- | board/st/stm32mp1/stm32mp1.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/board/st/stm32mp1/stm32mp1.c b/board/st/stm32mp1/stm32mp1.c index 759181fb5d..261ec15e1b 100644 --- a/board/st/stm32mp1/stm32mp1.c +++ b/board/st/stm32mp1/stm32mp1.c @@ -347,6 +347,9 @@ static int board_check_usb_power(void) u32 nb_blink; u8 i; + if (!IS_ENABLED(CONFIG_ADC)) + return -ENODEV; + node = ofnode_path("/config"); if (!ofnode_valid(node)) { log_debug("no /config node?\n"); @@ -370,11 +373,7 @@ static int board_check_usb_power(void) /* perform maximum of 2 ADC measurements to detect power supply current */ for (i = 0; i < 2; i++) { - if (IS_ENABLED(CONFIG_ADC)) - ret = adc_measurement(node, adc_count, &min_uV, &max_uV); - else - ret = -ENODEV; - + ret = adc_measurement(node, adc_count, &min_uV, &max_uV); if (ret) return ret; |