doc: Add gpio status output fields description

Add gpio status output fields description and one output example.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Simon Glass <sjg@chromium.org>

Tweak the formatting.
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
This commit is contained in:
Patrice Chotard 2022-08-30 16:56:28 +02:00 committed by Heinrich Schuchardt
parent d5391bf02b
commit 00cc81f4e4

View file

@ -45,6 +45,31 @@ gpio status
Display the status of one or multiple GPIOs. By default only claimed GPIOs
are displayed.
gpio status command output fields are::
<name>: <function>: <value> [x] <label>
*function* can take the following values:
output
pin configured in gpio output, *value* indicates the pin's level
input
pin configured in gpio input, *value* indicates the pin's level
func
pin configured in alternate function, followed by *label*
which shows pinmuxing label.
unused
pin not configured
*[x]* or *[ ]* indicate respectively if the gpio is used or not.
*label* shows the gpio label.
Parameters
----------
-a
Display GPIOs irrespective of being claimed.
@ -77,6 +102,23 @@ Switch the status of a GPIO::
=> echo $myvar
0
Show the GPIO status::
=> gpio status
Bank GPIOA:
GPIOA1: func rgmii-0
GPIOA2: func rgmii-0
GPIOA7: func rgmii-0
GPIOA10: output: 0 [x] hdmi-transmitter@39.reset-gpios
GPIOA13: output: 1 [x] red.gpios
Bank GPIOB:
GPIOB0: func rgmii-0
GPIOB1: func rgmii-0
GPIOB2: func uart4-0
GPIOB7: input: 0 [x] mmc@58005000.cd-gpios
GPIOB11: func rgmii-0
Configuration
-------------