]> xenbits.xen.org Git - xenclient/ioemu.git/commitdiff
Merge branch 'stable_0_10'
authorIan Jackson <ian.jackson@eu.citrix.com>
Tue, 14 Apr 2009 16:35:05 +0000 (17:35 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Tue, 14 Apr 2009 16:35:05 +0000 (17:35 +0100)
Conflicts:

block.c
hw/cirrus_vga.c
hw/vga.c

18 files changed:
1  2 
block-qcow2.c
block-raw-win32.c
block.c
block.h
block_int.h
configure
console.h
hw/lsi53c895a.c
hw/pci.c
hw/vga.c
loader.c
monitor.c
net.c
qemu-char.c
qemu-char.h
savevm.c
sdl.c
vl.c

diff --cc block-qcow2.c
Simple merge
Simple merge
diff --cc block.c
index c6f9c4d7f6d9e2aa0c567da3266ad1806da2ddf4,3f262fa590adad7582fd7c194005ea80d029b447..8a0e8b282f60a27ed1407b66926507b754fc8eb3
+++ b/block.c
@@@ -335,9 -311,7 +335,7 @@@ int bdrv_file_open(BlockDriverState **p
      int ret;
  
      bs = bdrv_new("");
-     if (!bs)
-         return -ENOMEM;
 -    ret = bdrv_open2(bs, filename, flags | BDRV_O_FILE, NULL);
 +    ret = bdrv_open2(bs, filename, flags | BDRV_O_FILE, &bdrv_raw);
      if (ret < 0) {
          bdrv_delete(bs);
          return ret;
@@@ -446,15 -421,13 +445,13 @@@ int bdrv_open2(BlockDriverState *bs, co
      if (bs->backing_file[0] != '\0') {
          /* if there is a backing file, use it */
          bs->backing_hd = bdrv_new("");
-         if (!bs->backing_hd) {
-         fail:
-             bdrv_close(bs);
-             return -ENOMEM;
-         }
          path_combine(backing_filename, sizeof(backing_filename),
                       filename, bs->backing_file);
-         if (bdrv_open2(bs->backing_hd, backing_filename, open_flags, &bdrv_raw) < 0)
-             goto fail;
 -        ret = bdrv_open(bs->backing_hd, backing_filename, open_flags);
++        ret = bdrv_open2(bs->backing_hd, backing_filename, open_flags, &bdrv_raw);
+         if (ret < 0) {
+             bdrv_close(bs);
+             return ret;
+         }
      }
  
      /* call the change callback */
diff --cc block.h
index 5a91ad43e9b74ce529885e0e9e4be824f6251073,979781a12e8f69fd72f21950e258f4a9f6aa5ae4..fc0afbbdbe1b089997b0dca34a05e8e884ff9dd0
+++ b/block.h
@@@ -101,15 -99,11 +99,13 @@@ BlockDriverAIOCB *bdrv_aio_read(BlockDr
  BlockDriverAIOCB *bdrv_aio_write(BlockDriverState *bs, int64_t sector_num,
                                   const uint8_t *buf, int nb_sectors,
                                   BlockDriverCompletionFunc *cb, void *opaque);
 +BlockDriverAIOCB *bdrv_aio_flush(BlockDriverState *bs, 
 +                                 BlockDriverCompletionFunc *cb, void *opaque);
  void bdrv_aio_cancel(BlockDriverAIOCB *acb);
  
- int qemu_key_check(BlockDriverState *bs, const char *name);
  /* Ensure contents are flushed to disk.  */
 -void bdrv_flush(BlockDriverState *bs);
 -void bdrv_flush_all(void);
 +int bdrv_flush(BlockDriverState *bs);
 +int bdrv_flush_all(void);
  
  int bdrv_is_allocated(BlockDriverState *bs, int64_t sector_num, int nb_sectors,
        int *pnum);
diff --cc block_int.h
index 1481a5c98440d87590107c6e639157f41882d33c,c6af1c64dadd45e154592e0157414bd370b23599..1c8655b2ccb81151fa211520adb2248d78668a4c
@@@ -101,8 -101,8 +106,9 @@@ struct BlockDriverState 
      int removable; /* if true, the media can be removed */
      int locked;    /* if true, the media cannot temporarily be ejected */
      int encrypted; /* if true, the media is encrypted */
+     int valid_key; /* if true, a valid encryption key has been set */
      int sg;        /* if true, the device is a /dev/sg* */
 +    int extendable;/* if true, we may write out of original range */
      /* event callback when inserting/removing */
      void (*change_cb)(void *opaque);
      void *change_opaque;
diff --cc configure
Simple merge
diff --cc console.h
Simple merge
diff --cc hw/lsi53c895a.c
Simple merge
diff --cc hw/pci.c
Simple merge
diff --cc hw/vga.c
index de5873558966525d6324e9bada652e8241ed8231,709d6bb9917df0a4eb52422d20abcba48bee4c02..7b8572af9389c2616582e60fa046b490d0a1fc30
+++ b/hw/vga.c
@@@ -1549,9 -1584,8 +1549,9 @@@ void vga_invalidate_scanlines(VGAState 
   */
  static void vga_draw_graphic(VGAState *s, int full_update)
  {
 -    int y1, y, update, page_min, page_max, linesize, y_start, double_scan, mask, depth;
 -    int width, height, shift_control, line_offset, page0, page1, bwidth, bits;
 +    int y1, y, update, linesize, y_start, double_scan, mask, depth;
-     int width, height, shift_control, line_offset, bwidth, ds_depth, bits;
++    int width, height, shift_control, line_offset, bwidth, bits;
 +    ram_addr_t page0, page1;
      int disp_width, multi_scan, multi_run;
      uint8_t *d;
      uint32_t v, addr1, addr;
          s->shift_control = shift_control;
          s->double_scan = double_scan;
      }
 +    if (shift_control == 1 && (s->sr[0x01] & 8)) {
 +        disp_width <<= 1;
 +    }
  
-     ds_depth = ds_get_bits_per_pixel(s->ds);
+     if (shift_control == 0) {
+         if (s->sr[0x01] & 8) {
+             disp_width <<= 1;
+         }
+     } else if (shift_control == 1) {
+         if (s->sr[0x01] & 8) {
+             disp_width <<= 1;
+         }
+     }
      depth = s->get_bpp(s);
 -    if (s->line_offset != s->last_line_offset ||
 +    if (s->line_offset != s->last_line_offset || 
          disp_width != s->last_width ||
          height != s->last_height ||
          s->last_depth != depth) {
@@@ -2806,6 -2646,37 +2826,7 @@@ static void vga_screen_dump(void *opaqu
  
      ppm_save(filename, ds->surface);
  
 -    qemu_free_displaysurface(ds->surface);
 +    qemu_free_displaysurface(ds);
      s->ds = saved_ds;
 -}
 -
 -static void vga_screen_dump_graphic(VGAState *s, const char *filename)
 -{
 -    int w, h;
 -
 -    s->get_resolution(s, &w, &h);
 -    vga_screen_dump_common(s, filename, w, h);
 -}
 -
 -static void vga_screen_dump_text(VGAState *s, const char *filename)
 -{
 -    int w, h, cwidth, cheight;
 -
 -    vga_get_text_resolution(s, &w, &h, &cwidth, &cheight);
 -    vga_screen_dump_common(s, filename, w * cwidth, h * cheight);
 -}
 -
 -/* save the vga display in a PPM image even if no display is
 -   available */
 -static void vga_screen_dump(void *opaque, const char *filename)
 -{
 -    VGAState *s = (VGAState *)opaque;
 -
 -    if (!(s->ar_index & 0x20))
 -        vga_screen_dump_blank(s, filename);
 -    else if (s->gr[6] & 1)
 -        vga_screen_dump_graphic(s, filename);
 -    else
 -        vga_screen_dump_text(s, filename);
+     vga_invalidate_display(s);
  }
diff --cc loader.c
Simple merge
diff --cc monitor.c
Simple merge
diff --cc net.c
Simple merge
diff --cc qemu-char.c
Simple merge
diff --cc qemu-char.h
Simple merge
diff --cc savevm.c
Simple merge
diff --cc sdl.c
Simple merge
diff --cc vl.c
Simple merge