Diff for /qemu/hw/xen_disk.c between versions 1.1.1.2 and 1.1.1.3

version 1.1.1.2, 2018/04/24 17:38:53 version 1.1.1.3, 2018/04/24 18:29:32
Line 575  static void blk_alloc(struct XenDevice * Line 575  static void blk_alloc(struct XenDevice *
 static int blk_init(struct XenDevice *xendev)  static int blk_init(struct XenDevice *xendev)
 {  {
     struct XenBlkDev *blkdev = container_of(xendev, struct XenBlkDev, xendev);      struct XenBlkDev *blkdev = container_of(xendev, struct XenBlkDev, xendev);
     int index, mode, qflags, have_barriers, info = 0;      int index, qflags, have_barriers, info = 0;
     char *h;      char *h;
   
     /* read xenstore entries */      /* read xenstore entries */
Line 609  static int blk_init(struct XenDevice *xe Line 609  static int blk_init(struct XenDevice *xe
   
     /* read-only ? */      /* read-only ? */
     if (strcmp(blkdev->mode, "w") == 0) {      if (strcmp(blkdev->mode, "w") == 0) {
         mode   = O_RDWR;  
         qflags = BDRV_O_RDWR;          qflags = BDRV_O_RDWR;
     } else {      } else {
         mode   = O_RDONLY;          qflags = 0;
         qflags = BDRV_O_RDONLY;  
         info  |= VDISK_READONLY;          info  |= VDISK_READONLY;
     }      }
   
Line 629  static int blk_init(struct XenDevice *xe Line 627  static int blk_init(struct XenDevice *xe
         xen_be_printf(&blkdev->xendev, 2, "create new bdrv (xenbus setup)\n");          xen_be_printf(&blkdev->xendev, 2, "create new bdrv (xenbus setup)\n");
         blkdev->bs = bdrv_new(blkdev->dev);          blkdev->bs = bdrv_new(blkdev->dev);
         if (blkdev->bs) {          if (blkdev->bs) {
             if (bdrv_open2(blkdev->bs, blkdev->filename, qflags,              if (bdrv_open(blkdev->bs, blkdev->filename, qflags,
                            bdrv_find_whitelisted_format(blkdev->fileproto))                             bdrv_find_whitelisted_format(blkdev->fileproto))
                 != 0) {                  != 0) {
                 bdrv_delete(blkdev->bs);                  bdrv_delete(blkdev->bs);

Removed from v.1.1.1.2  
changed lines
  Added in v.1.1.1.3


unix.superglobalmegacorp.com