rockchip: rk3308: fix rockchip_dnl_key_pressed() on roc-cc
PATCH 1/1 rockchip: rk3308: fix rockchip_dnl_key_pressed() on roc-cc
Commit 6aa4fe3912 ("dm: core: Rename and fix uclass_get_by_name_len()") changed uclass_get_device_by_name() to an exact match when previously it behaved as a prefix match.
The roc-cc code relied on this prefix match by only specifying part of the device name. Fix this by using the full name including the address.
Signed-off-by John Keeping <[email protected]>
--- board/firefly/firefly-rk3308/roc_cc_rk3308.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
board/firefly/firefly-rk3308/roc_cc_rk3308.c +1 -1
@@ -70,7 +70,7 @@ int rockchip_dnl_key_pressed(void) {unsigned int val; -if (adc_channel_single_shot ("saradc" ,1 , &val)) { +if (adc_channel_single_shot ("saradc@ff1e0000" ,1 , &val)) {printf ("%s read adc key val failed\n" , __func__);return false; }
Signature · 1 line
2.37.1
Quoted 9 lines · John Keeping
Commit
6aa4fe3912("dm: core: Rename and fixuclass_get_by_name_len()") changeduclass_get_device_by_name()to an exact match when previously it behaved as a prefix match.The roc-cc code relied on this prefix match by only specifying part of the device name. Fix this by using the full name including the address.
Signed-off-by John Keeping <[email protected]>---
Reviewed-by Kever Yang <[email protected]>
Thanks,
- Kever
Quoted 16 lines
board/firefly/firefly-rk3308/roc_cc_rk3308.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)board/firefly/firefly-rk3308/roc_cc_rk3308.c +1
-1@@ -70,7 +70,7 @@ int rockchip_dnl_key_pressed(void) {unsigned int val; -if (adc_channel_single_shot ("saradc" ,1 , &val)) { +if (adc_channel_single_shot ("saradc@ff1e0000" ,1 , &val)) {printf ("%s read adc key val failed\n" , __func__);return false; }