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>
This commit is contained in:
parent
ed73508dec
commit
2765c4d147
|
@ -107,6 +107,7 @@ static int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
|
||||||
case 2:
|
case 2:
|
||||||
if (strncmp(argv[1], "inf", 3) == 0) {
|
if (strncmp(argv[1], "inf", 3) == 0) {
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
putc('\n');
|
putc('\n');
|
||||||
for (i = 0; i < CONFIG_SYS_SATA_MAX_DEVICE; ++i) {
|
for (i = 0; i < CONFIG_SYS_SATA_MAX_DEVICE; ++i) {
|
||||||
if (sata_dev_desc[i].type == DEV_TYPE_UNKNOWN)
|
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;
|
return 0;
|
||||||
} else if (strncmp(argv[1], "dev", 3) == 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");
|
puts("\nno SATA devices available\n");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue