Revision 751c6a17 hw/etraxfs.c

b/hw/etraxfs.c
55 55
    void *etraxfs_dmac;
56 56
    struct etraxfs_dma_client *eth[2] = {NULL, NULL};
57 57
    int kernel_size;
58
    DriveInfo *dinfo;
58 59
    int i;
59 60
    ram_addr_t phys_ram;
60 61
    ram_addr_t phys_flash;
......
79 80

  
80 81

  
81 82
    phys_flash = qemu_ram_alloc(FLASH_SIZE);
82
    i = drive_get_index(IF_PFLASH, 0, 0);
83
    dinfo = drive_get(IF_PFLASH, 0, 0);
83 84
    pflash_cfi02_register(0x0, phys_flash,
84
                          i != -1 ? drives_table[i].bdrv : NULL, (64 * 1024),
85
                          dinfo ? dinfo->bdrv : NULL, (64 * 1024),
85 86
                          FLASH_SIZE >> 16,
86 87
                          1, 2, 0x0000, 0x0000, 0x0000, 0x0000,
87 88
                          0x555, 0x2aa);

Also available in: Unified diff