@@ -953,37 +953,6 @@ static void pflash_cfi01_register_types(void)
type_init(pflash_cfi01_register_types)
-PFlashCFI01 *pflash_cfi01_register(hwaddr base,
- const char *name,
- hwaddr size,
- BlockBackend *blk,
- uint32_t sector_len,
- int bank_width,
- uint16_t id0, uint16_t id1,
- uint16_t id2, uint16_t id3,
- int be)
-{
- DeviceState *dev = qdev_new(TYPE_PFLASH_CFI01);
-
- if (blk) {
- qdev_prop_set_drive(dev, "drive", blk);
- }
- assert(QEMU_IS_ALIGNED(size, sector_len));
- qdev_prop_set_uint32(dev, "num-blocks", size / sector_len);
- qdev_prop_set_uint64(dev, "sector-length", sector_len);
- qdev_prop_set_uint8(dev, "width", bank_width);
- qdev_prop_set_bit(dev, "big-endian", !!be);
- qdev_prop_set_uint16(dev, "id0", id0);
- qdev_prop_set_uint16(dev, "id1", id1);
- qdev_prop_set_uint16(dev, "id2", id2);
- qdev_prop_set_uint16(dev, "id3", id3);
- qdev_prop_set_string(dev, "name", name);
- sysbus_realize_and_unref(SYS_BUS_DEVICE(dev), &error_fatal);
-
- sysbus_mmio_map(SYS_BUS_DEVICE(dev), 0, base);
- return PFLASH_CFI01(dev);
-}
-
BlockBackend *pflash_cfi01_get_blk(DeviceState *dev)
{
PFlashCFI01 *fl = PFLASH_CFI01(dev);
@@ -11,20 +11,10 @@
OBJECT_DECLARE_SIMPLE_TYPE(PFlashCFI01, PFLASH_CFI01)
-PFlashCFI01 *pflash_cfi01_register(hwaddr base,
- const char *name,
- hwaddr size,
- BlockBackend *blk,
- uint32_t sector_len,
- int width,
- uint16_t id0, uint16_t id1,
- uint16_t id2, uint16_t id3,
- int be);
BlockBackend *pflash_cfi01_get_blk(DeviceState *dev);
MemoryRegion *pflash_cfi01_get_memory(DeviceState *dev);
void pflash_cfi01_legacy_drive(DeviceState *dev, DriveInfo *dinfo);
-
/* nand.c */
DeviceState *nand_init(BlockBackend *blk, int manf_id, int chip_id);
void nand_setpins(DeviceState *dev, uint8_t cle, uint8_t ale,