diff options
author | Stefan Reinauer <reinauer@chromium.org> | 2012-01-24 16:44:35 -0800 |
---|---|---|
committer | Gerrit <chrome-bot@google.com> | 2012-01-25 15:06:01 -0800 |
commit | cf11fae2e4367bd2287b063217321efd10c5f189 (patch) | |
tree | 579a35fb6bf509ee81f573d74b325250a630bfd6 /common | |
parent | d0076d861920a2aa12ec007b29acca869c7d0cfd (diff) |
vbexport: report correct number of scsi drives
Right now our code makes the assumption that there always is one
SCSI drive in the system (the AHCI attached SDD). However, this
might not be the case.
This patch prevents vboot from using an uninitialized disk entry
when instead it should go into recovery mode.
BUG=chrome-os-partner:7716
TEST=none
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Change-Id: I761bbb3c92a60d4205a217c7b025f699deed83b0
Reviewed-on: https://gerrit.chromium.org/gerrit/14753
Tested-by: Stefan Reinauer <reinauer@chromium.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Commit-Ready: Stefan Reinauer <reinauer@chromium.org>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/cmd_scsi.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/common/cmd_scsi.c b/common/cmd_scsi.c index 7f6d7441230..7bfb3b421b3 100644 --- a/common/cmd_scsi.c +++ b/common/cmd_scsi.c @@ -186,8 +186,14 @@ removable: scsi_curr_dev=0; else scsi_curr_dev = -1; + + printf("Found %d device(s).\n", scsi_max_devs); } +int scsi_get_disk_count(void) +{ + return scsi_max_devs; +} void scsi_init(void) { |