diff options
| author | Gerd Hoffmann <kraxel@redhat.com> | 2009-07-22 16:42:57 +0200 |
|---|---|---|
| committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-07-27 14:08:23 -0500 |
| commit | 751c6a17042b5d011013d6963c0505d671cf708e (patch) | |
| tree | 61a769ed1a1c16ebdfc1397ce9d775222dfa8e57 /hw/mips_jazz.c | |
| parent | 8a14daa5a1ae22fcfc317f4727a88d6c15c39aae (diff) | |
| download | focaccia-qemu-751c6a17042b5d011013d6963c0505d671cf708e.tar.gz focaccia-qemu-751c6a17042b5d011013d6963c0505d671cf708e.zip | |
kill drives_table
First step cleaning up the drives handling. This one does nothing but removing drives_table[], still it became seriously big. drive_get_index() is gone and is replaced by drives_get() which hands out DriveInfo pointers instead of a table index. This needs adaption in *tons* of places all over. The drives are now maintained as linked list. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/mips_jazz.c')
| -rw-r--r-- | hw/mips_jazz.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/hw/mips_jazz.c b/hw/mips_jazz.c index 82cd385d26..e09a6b22dc 100644 --- a/hw/mips_jazz.c +++ b/hw/mips_jazz.c @@ -235,11 +235,8 @@ void mips_jazz_init (ram_addr_t ram_size, exit(1); } for (n = 0; n < MAX_FD; n++) { - int fd = drive_get_index(IF_FLOPPY, 0, n); - if (fd != -1) - fds[n] = drives_table[fd].bdrv; - else - fds[n] = NULL; + DriveInfo *dinfo = drive_get(IF_FLOPPY, 0, n); + fds[n] = dinfo ? dinfo->bdrv : NULL; } fdctrl_init(rc4030[1], 0, 1, 0x80003000, fds); |