summaryrefslogtreecommitdiff
path: root/cmd/pinmux.c
AgeCommit message (Collapse)AuthorFilesLines
2021-07-23cmd: pinmux: support pin name in status commandPatrick Delaunay1-9/+37
Allow pin name parameter for pimux staus command, as gpio command to get status of one pin. The possible usage of the command is: > pinmux dev pinctrl > pinmux status > pinmux status -a > pinmux status <pin-name> Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2021-07-23cmd: pinmux: update result of do_statusPatrick Delaunay1-14/+17
Update the result of do_status and always returns a CMD_RET_ value (-ENOSYS was a possible result of show_pinmux). This patch also adds pincontrol name in error messages (dev->name) and treats correctly the status sub command when pin-controller device is not selected. Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2020-05-19command: Remove the cmd_tbl_t typedefSimon Glass1-7/+10
We should not use typedefs in U-Boot. They cannot be used as forward declarations which means that header files must include the full header to access them. Drop the typedef and rename the struct to remove the _s suffix which is now not useful. This requires quite a few header-file additions. Signed-off-by: Simon Glass <sjg@chromium.org>
2019-07-12cmd: pinmux: Fix warnings when compiling with W=1Patrick Delaunay1-0/+1
This patch solves the following warnings: cmd/pinmux.c: In function 'do_dev': cmd/pinmux.c:26:6: warning: this statement may fall through [-Wimplicit-fallthrough=] if (ret) { ^ cmd/pinmux.c:30:2: note: here case 1: ^~~~ Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2018-11-17cmd: pinmux: Add pinmux commandPatrice Chotard1-0/+146
pinmux command allows to : - list all pin-controllers available on platforms - select a pin-controller - display the muxing of all pins of the current pin-controller or all pin-controllers depending of given options Signed-off-by: Patrice Chotard <patrice.chotard@st.com> cmd: pinmux: Fix pinmux command if "pinmux status" command is used without having set dev using "pinmux dev", print pinmux usage Reviewed-by: Simon Glass <sjg@chromium.org>