From 317cde826df9bea683fda5cc4207d3bb10c6bb54 Mon Sep 17 00:00:00 2001 From: Greg Watson Date: Wed, 17 Mar 2004 22:35:52 +0000 Subject: added spin-up delay git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1429 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- src/stream/fs/blockdev.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src/stream/fs') diff --git a/src/stream/fs/blockdev.c b/src/stream/fs/blockdev.c index 336f435a25..aa818dd496 100644 --- a/src/stream/fs/blockdev.c +++ b/src/stream/fs/blockdev.c @@ -2,6 +2,7 @@ #include #include #include +#include #include #include @@ -229,7 +230,7 @@ static int parse_device_name(const char *name, int *type, int *drive, int devopen(const char *name, int *reopen) { - int type, drive, part; + int type, drive, part, i; uint64_t offset, length; uint32_t disk_size = 0; @@ -258,6 +259,15 @@ int devopen(const char *name, int *reopen) switch (type) { case DISK_IDE: + printk_debug ("Trying polled ide\n"); + printk_debug ("Waiting for ide disks to spin up\n"); + printk_notice ("This is a hard coded delay and longer than necessary.\n"); + for (i = 0; i < 2; i++) { + printk_notice ("."); + delay(1); + } + printk_info ("\n"); + if (ide_probe(drive) != 0) { printk_debug("failed to open ide\n"); return 0; -- cgit v1.2.3