From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MM4c4-0000me-Qi for qemu-devel@nongnu.org; Wed, 01 Jul 2009 14:32:56 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MM4c0-0000km-FZ for qemu-devel@nongnu.org; Wed, 01 Jul 2009 14:32:56 -0400 Received: from [199.232.76.173] (port=59523 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MM4c0-0000kV-5L for qemu-devel@nongnu.org; Wed, 01 Jul 2009 14:32:52 -0400 Received: from smtp.eu.citrix.com ([62.200.22.115]:26137) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MM4bz-0002ER-Mj for qemu-devel@nongnu.org; Wed, 01 Jul 2009 14:32:51 -0400 From: Bique Alexandre Date: Wed, 1 Jul 2009 19:32:01 +0100 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="Boundary-00=_hu6SKlaKiQAhxoo" Message-ID: <200907011932.01263.alexandre.bique@citrix.com> Subject: [Qemu-devel] [PATCH 2/5] ATAPI pass through v2: adds few comments List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "qemu-devel@nongnu.org" --Boundary-00=_hu6SKlaKiQAhxoo Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline This patch adds few comments to some CD-ROM emulated commands. -- Alexandre Bique --Boundary-00=_hu6SKlaKiQAhxoo Content-Type: text/x-patch; charset="UTF-8"; name="atapi-comments" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="atapi-comments" diff --git a/hw/ide.c b/hw/ide.c index 1e56786..063f08d 100644 --- a/hw/ide.c +++ b/hw/ide.c @@ -1664,9 +1664,9 @@ static void ide_atapi_cmd(IDEState *s) switch(action) { case 0: /* current values */ switch(code) { - case 0x01: /* error recovery */ + case 0x01: /* read write error recovery parameters */ cpu_to_ube16(&buf[0], 16 + 6); - buf[2] = 0x70; + buf[2] = 0x70; /* Obselete: medium type code */ buf[3] = 0; buf[4] = 0; buf[5] = 0; @@ -1683,17 +1683,17 @@ static void ide_atapi_cmd(IDEState *s) buf[15] = 0x00; ide_atapi_cmd_reply(s, 16, max_len); break; - case 0x2a: + case 0x2a: /* CD/DVD capabilities & mechanical status */ cpu_to_ube16(&buf[0], 28 + 6); - buf[2] = 0x70; + buf[2] = 0x70; /* Obselete: medium type code */ buf[3] = 0; buf[4] = 0; buf[5] = 0; buf[6] = 0; buf[7] = 0; - buf[8] = 0x2a; - buf[9] = 0x12; + buf[8] = 0x2a; /* page code */ + buf[9] = 0x12; /* page lenght */ buf[10] = 0x00; buf[11] = 0x00; --Boundary-00=_hu6SKlaKiQAhxoo--