Commit Graph

3 Commits

Author SHA1 Message Date
Simon Glass 4c12eeb8b5 Convert cmd_usage() calls in common to use a return value
Change all files in common/ to use CMD_RET_USAGE instead of calling
cmd_usage() directly. I'm not completely sure about this patch since
the code since impact is small (100 byte or so on ARM) and it might
need splitting into smaller patches. But for now here it is.

Signed-off-by: Simon Glass <sjg@chromium.org>
2012-03-06 21:09:46 +01:00
Mike Frysinger 6801201ee7 gpio: check request result
Make sure the pin request passed before attempting to use it later on.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-04-13 15:57:00 -04:00
Mike Frysinger a972b8d701 gpio: generalize for all generic gpio providers
The Blackfin gpio command isn't terribly Blackfin-specific.  So generalize
the few pieces into two new optional helpers:
	name_to_gpio() - turn a string name into a GPIO #
	gpio_status() - display current pin bindings (think /proc/gpio)

Once these pieces are pulled out, we can relocate the cmd_gpio.c into the
common directory.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-04-13 15:56:51 -04:00