Changes in v2:
- Renamed "char *dev" to "char *dev_arg", to make it clearer that we're working
on the device argument. Use strspn(dev_arg,...) instead of strspn(argv[1],...)
Changes in v3:
- Protect against segfault when trying to access non-existant argv[2]
- Moved "handle == NULL" error
See https://github.com/linux-sunxi/sunxi-tools/issues/37
The patch was originally inspired by
https://github.com/NextThingCo/sunxi-tools/commit/16386a7
and
https://github.com/NextThingCo/sunxi-tools/commit/47bafaf
It introduces a "--dev" (-d) option to specify the desired FEL
device. This is