dm: sata: Fix code style problems in cmd/sata.c

This file has a few coding style problems. Fix these to make future updates
easier.

Signed-off-by: Simon Glass <sjg@chromium.org>
master
Simon Glass 8 years ago
parent ed73508dec
commit 2765c4d147
  1. 4
      cmd/sata.c

@ -107,6 +107,7 @@ static int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
case 2:
if (strncmp(argv[1], "inf", 3) == 0) {
int i;
putc('\n');
for (i = 0; i < CONFIG_SYS_SATA_MAX_DEVICE; ++i) {
if (sata_dev_desc[i].type == DEV_TYPE_UNKNOWN)
@ -116,7 +117,8 @@ static int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
}
return 0;
} else if (strncmp(argv[1], "dev", 3) == 0) {
if ((sata_curr_device < 0) || (sata_curr_device >= CONFIG_SYS_SATA_MAX_DEVICE)) {
if (sata_curr_device < 0 ||
sata_curr_device >= CONFIG_SYS_SATA_MAX_DEVICE) {
puts("\nno SATA devices available\n");
return 1;
}

Loading…
Cancel
Save