Diff for /qemu/hw/nand.c between versions 1.1.1.7 and 1.1.1.8

version 1.1.1.7, 2018/04/24 19:28:08 version 1.1.1.8, 2018/04/24 19:47:52
Line 11 Line 11
  * from ST Microelectronics.   * from ST Microelectronics.
  *   *
  * This code is licensed under the GNU GPL v2.   * This code is licensed under the GNU GPL v2.
    *
    * Contributions after 2012-01-13 are licensed under the terms of the
    * GNU GPL, version 2 or (at your option) any later version.
  */   */
   
 #ifndef NAND_IO  #ifndef NAND_IO
Line 414  static int nand_device_init(SysBusDevice Line 417  static int nand_device_init(SysBusDevice
     return 0;      return 0;
 }  }
   
 static SysBusDeviceInfo nand_info = {  static Property nand_properties[] = {
     .init = nand_device_init,      DEFINE_PROP_UINT8("manufacturer_id", NANDFlashState, manf_id, 0),
     .qdev.name = "nand",      DEFINE_PROP_UINT8("chip_id", NANDFlashState, chip_id, 0),
     .qdev.size = sizeof(NANDFlashState),      DEFINE_PROP_DRIVE("drive", NANDFlashState, bdrv),
     .qdev.reset = nand_reset,      DEFINE_PROP_END_OF_LIST(),
     .qdev.vmsd = &vmstate_nand,  };
     .qdev.props = (Property[]) {  
         DEFINE_PROP_UINT8("manufacturer_id", NANDFlashState, manf_id, 0),  static void nand_class_init(ObjectClass *klass, void *data)
         DEFINE_PROP_UINT8("chip_id", NANDFlashState, chip_id, 0),  {
         DEFINE_PROP_DRIVE("drive", NANDFlashState, bdrv),      DeviceClass *dc = DEVICE_CLASS(klass);
         DEFINE_PROP_END_OF_LIST()      SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
     }  
       k->init = nand_device_init;
       dc->reset = nand_reset;
       dc->vmsd = &vmstate_nand;
       dc->props = nand_properties;
   }
   
   static TypeInfo nand_info = {
       .name          = "nand",
       .parent        = TYPE_SYS_BUS_DEVICE,
       .instance_size = sizeof(NANDFlashState),
       .class_init    = nand_class_init,
 };  };
   
 static void nand_create_device(void)  static void nand_register_types(void)
 {  {
     sysbus_register_withprop(&nand_info);      type_register_static(&nand_info);
 }  }
   
 /*  /*
Line 621  DeviceState *nand_init(BlockDriverState  Line 635  DeviceState *nand_init(BlockDriverState 
     return dev;      return dev;
 }  }
   
 device_init(nand_create_device)  type_init(nand_register_types)
   
 #else  #else
   

Removed from v.1.1.1.7  
changed lines
  Added in v.1.1.1.8


unix.superglobalmegacorp.com