Commit 6b658153 authored by Fabio Utzig's avatar Fabio Utzig
Browse files

Coding style fixes

parent ca6cb63d
......@@ -491,8 +491,7 @@ enum flasher_error {
};
static
enum flasher_error
static enum flasher_error
flasher_find_matching_device(
libusb_context *ctx,
libusb_device **matching_device_out,
......@@ -513,7 +512,7 @@ flasher_find_matching_device(
int device_count;
int device_index;
/* Enumberate all USB devices */
/* Enumerate all USB devices */
retval = libusb_get_device_list(ctx, &device_list);
if (retval < 0) {
libusb_error = retval;
......@@ -597,9 +596,7 @@ out:
}
static
void
flasher_usage()
static void flasher_usage()
{
printf("usage: lm4flash [-v] [-s serial] <binary-file>\n");
printf("\t-v - Enables verification after write\n");
......@@ -607,13 +604,7 @@ flasher_usage()
}
static
int
flasher_flash(
int do_verify,
const char *serial,
const char *rom_name
)
static int flasher_flash(const char *serial, const char *rom_name)
{
libusb_context *ctx = NULL;
libusb_device *device = NULL;
......@@ -705,10 +696,12 @@ int main(int argc, char *argv[])
return EXIT_FAILURE;
}
}
if (optind >= argc) {
flasher_usage();
return EXIT_FAILURE;
} else
rom_name = argv[optind];
return flasher_flash(do_verify, serial, rom_name);
return flasher_flash(serial, rom_name);
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment