cmd: fix do_adc_single()
authorVyacheslav Bocharov <adeep@lexina.in>
Sun, 3 Jul 2022 12:49:09 +0000 (15:49 +0300)
committerTom Rini <trini@konsulko.com>
Thu, 4 Aug 2022 17:59:59 +0000 (13:59 -0400)
commit6ac4774426d687b5c365c79c9187e88f6c874878
tree118a1fde61d446482ea93fb33c0b51d220f95c5d
parent11d30963bc19c400517c4edd83f83ca06775a05c
cmd: fix do_adc_single()

The source code contains an error:
- argv[2] contains <channel> arg, variable for env_set is in argv[3]
- number of args is 4

Revert 54d24d72601321f4470c4edf31c6b29adae424a7
  cmd: simplify do_adc_single()

Fixes 9de612ae4ded53f742f5f99929c06d0839471ced
  cmd: adc: Add support for storing ADC result in env variable
Reviewed-by: Simon Glass <sjg@chromium.org>
cmd/adc.c