]> xenbits.xen.org Git - xenclient/ioemu-pq.git/commitdiff
Fix DVD playback
authorAndrew McNeil <andrewmcn@bob.uk.xensource.com>
Mon, 7 Sep 2009 17:59:55 +0000 (18:59 +0100)
committerAndrew McNeil <andrewmcn@bob.uk.xensource.com>
Mon, 7 Sep 2009 17:59:55 +0000 (18:59 +0100)
master/atapi-pt-write

index 3f298fdee525c55199bb223a596e0d36d43e714e..31612eec0a322607b7f60f5f87eaed8182fe7e53 100644 (file)
@@ -1,5 +1,5 @@
 diff --git a/hw/atapi-pt.c b/hw/atapi-pt.c
-index 413cc47..d5c5f0b 100644
+index 413cc47..66da45a 100644
 --- a/hw/atapi-pt.c
 +++ b/hw/atapi-pt.c
 @@ -497,124 +497,106 @@ static void ide_atapi_pt_error(IDEState *s)
@@ -436,12 +436,13 @@ index 413cc47..d5c5f0b 100644
          memcpy(s->io_buffer, &s->atapi_pt.sense, sizeof (s->atapi_pt.sense));
          ide_atapi_cmd_reply(s, size, max_size);
          return;
-@@ -1053,57 +980,40 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1053,57 +980,41 @@ static void ide_atapi_pt_cmd(IDEState *s)
  
      case GPCMD_READ_DVD_STRUCTURE:
          cmd->din_xfer_len = ube16_to_cpu(s->io_buffer + 8);
 -        //        cmd->din_xferp = (__u64)s->io_buffer;
          s->atapi_pt.cmd_sent = ide_atapi_pt_standard_reply;
++        s->atapi_pt.reply_size_init = 4;
          s->atapi_pt.reply_size_len = 2;
 -        //        ATAPI_PT_SEND_PACKET;
 -        //        return;
@@ -494,7 +495,7 @@ index 413cc47..d5c5f0b 100644
          break;
  
      case GPCMD_READ_10:
-@@ -1123,17 +1033,12 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1123,17 +1034,12 @@ static void ide_atapi_pt_cmd(IDEState *s)
          default: assert(0);
          }
          cmd->din_xfer_len = nbblocks * blocksize;
@@ -512,7 +513,7 @@ index 413cc47..d5c5f0b 100644
          cmd->din_xfer_len = ube24_to_cpu(s->io_buffer + 6);
  
          switch (s->io_buffer[1] & 0x7)
-@@ -1157,30 +1062,21 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1157,30 +1063,21 @@ static void ide_atapi_pt_cmd(IDEState *s)
              goto illegal_request;
          }
          s->atapi_pt.cmd_sent = ide_atapi_pt_standard_reply;
@@ -543,7 +544,7 @@ index 413cc47..d5c5f0b 100644
          break;
  
      case GPCMD_GET_EVENT_STATUS_NOTIFICATION:
-@@ -1188,22 +1084,16 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1188,22 +1085,16 @@ static void ide_atapi_pt_cmd(IDEState *s)
      case GPCMD_READ_TOC_PMA_ATIP:
      case GPCMD_READ_TRACK_RZONE_INFO:
          cmd->din_xfer_len = ube16_to_cpu(s->io_buffer + 7);
@@ -566,7 +567,7 @@ index 413cc47..d5c5f0b 100644
          break;
  
      case GPCMD_READ_CD:
-@@ -1214,11 +1104,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1214,11 +1105,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
          int block_size = ide_atapi_pt_read_cd_block_size(s->io_buffer);
  
          cmd->din_xfer_len = block_count * block_size;
@@ -578,7 +579,7 @@ index 413cc47..d5c5f0b 100644
          break;
      }
  
-@@ -1233,11 +1120,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1233,11 +1121,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
          int block_size = ide_atapi_pt_read_cd_block_size(s->io_buffer);
  
          cmd->din_xfer_len = block_count * block_size;
@@ -590,7 +591,7 @@ index 413cc47..d5c5f0b 100644
          break;
      }
  
-@@ -1245,11 +1129,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1245,11 +1130,8 @@ static void ide_atapi_pt_cmd(IDEState *s)
      {
          int block_count = ube16_to_cpu(s->io_buffer + 7);
          cmd->din_xfer_len = block_count * CD_FRAMESIZE;
@@ -602,7 +603,7 @@ index 413cc47..d5c5f0b 100644
          break;
      }
  
-@@ -1261,40 +1142,28 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1261,40 +1143,28 @@ static void ide_atapi_pt_cmd(IDEState *s)
              MSF_TO_FRAMES(s->io_buffer[6], s->io_buffer[7], s->io_buffer[8]);
          int block_count = ending_frame - starting_frame;
          cmd->din_xfer_len = block_count * CD_FRAMESIZE;
@@ -643,7 +644,7 @@ index 413cc47..d5c5f0b 100644
          break;
  
      case 0x01: // GPMODE_R_W_ERROR_PAGE ?
-@@ -1318,110 +1187,5 @@ static void ide_atapi_pt_cmd(IDEState *s)
+@@ -1318,110 +1188,5 @@ static void ide_atapi_pt_cmd(IDEState *s)
          return;
      }