summaryrefslogtreecommitdiff
path: root/common/cmd_sata.c
diff options
context:
space:
mode:
authorHaavard Skinnemoen <haavard.skinnemoen@atmel.com>2008-12-17 16:53:07 +0100
committerHaavard Skinnemoen <haavard.skinnemoen@atmel.com>2008-12-17 16:53:07 +0100
commitcb5473205206c7f14cbb1e747f28ec75b48826e2 (patch)
tree8f4808d60917100b18a10b05230f7638a0a9bbcc /common/cmd_sata.c
parentbaf449fc5ff96f071bb0e3789fd3265f6d4fd9a0 (diff)
parent92c78a3bbcb2ce508b4bf1c4a1e0940406a024bb (diff)
downloadu-boot-imx-cb5473205206c7f14cbb1e747f28ec75b48826e2.zip
u-boot-imx-cb5473205206c7f14cbb1e747f28ec75b48826e2.tar.gz
u-boot-imx-cb5473205206c7f14cbb1e747f28ec75b48826e2.tar.bz2
Merge branch 'fixes' into cleanups
Conflicts: board/atmel/atngw100/atngw100.c board/atmel/atstk1000/atstk1000.c cpu/at32ap/at32ap700x/gpio.c include/asm-avr32/arch-at32ap700x/clk.h include/configs/atngw100.h include/configs/atstk1002.h include/configs/atstk1003.h include/configs/atstk1004.h include/configs/atstk1006.h include/configs/favr-32-ezkit.h include/configs/hammerhead.h include/configs/mimc200.h
Diffstat (limited to 'common/cmd_sata.c')
-rw-r--r--common/cmd_sata.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/common/cmd_sata.c b/common/cmd_sata.c
index 79c2495..dd6f1d9 100644
--- a/common/cmd_sata.c
+++ b/common/cmd_sata.c
@@ -29,14 +29,14 @@
#include <sata.h>
int curr_device = -1;
-block_dev_desc_t sata_dev_desc[CFG_SATA_MAX_DEVICE];
+block_dev_desc_t sata_dev_desc[CONFIG_SYS_SATA_MAX_DEVICE];
int sata_initialize(void)
{
int rc;
int i;
- for (i = 0; i < CFG_SATA_MAX_DEVICE; i++) {
+ for (i = 0; i < CONFIG_SYS_SATA_MAX_DEVICE; i++) {
memset(&sata_dev_desc[i], 0, sizeof(struct block_dev_desc));
sata_dev_desc[i].if_type = IF_TYPE_SATA;
sata_dev_desc[i].dev = i;
@@ -58,7 +58,7 @@ int sata_initialize(void)
block_dev_desc_t *sata_get_dev(int dev)
{
- return (dev < CFG_SATA_MAX_DEVICE) ? &sata_dev_desc[dev] : NULL;
+ return (dev < CONFIG_SYS_SATA_MAX_DEVICE) ? &sata_dev_desc[dev] : NULL;
}
int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
@@ -74,7 +74,7 @@ int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
if (strncmp(argv[1],"inf", 3) == 0) {
int i;
putc('\n');
- for (i = 0; i < CFG_SATA_MAX_DEVICE; ++i) {
+ for (i = 0; i < CONFIG_SYS_SATA_MAX_DEVICE; ++i) {
if (sata_dev_desc[i].type == DEV_TYPE_UNKNOWN)
continue;
printf ("SATA device %d: ", i);
@@ -82,7 +82,7 @@ int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
}
return 0;
} else if (strncmp(argv[1],"dev", 3) == 0) {
- if ((curr_device < 0) || (curr_device >= CFG_SATA_MAX_DEVICE)) {
+ if ((curr_device < 0) || (curr_device >= CONFIG_SYS_SATA_MAX_DEVICE)) {
puts("\nno SATA devices available\n");
return 1;
}
@@ -92,7 +92,7 @@ int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
} else if (strncmp(argv[1],"part",4) == 0) {
int dev, ok;
- for (ok = 0, dev = 0; dev < CFG_SATA_MAX_DEVICE; ++dev) {
+ for (ok = 0, dev = 0; dev < CONFIG_SYS_SATA_MAX_DEVICE; ++dev) {
if (sata_dev_desc[dev].part_type != PART_TYPE_UNKNOWN) {
++ok;
if (dev)
@@ -113,7 +113,7 @@ int do_sata(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
int dev = (int)simple_strtoul(argv[2], NULL, 10);
printf("\nSATA device %d: ", dev);
- if (dev >= CFG_SATA_MAX_DEVICE) {
+ if (dev >= CONFIG_SYS_SATA_MAX_DEVICE) {
puts ("unknown device\n");
return 1;
}