[2/4] ATAPI pass through v3

Submitted by Bique Alexandre on Aug. 6, 2009, 3:48 p.m.

Details

Message ID 200908061648.20407.alexandre.bique@citrix.com
State Superseded
Headers show

Commit Message

Bique Alexandre Aug. 6, 2009, 3:48 p.m.
Few comments

Comments

Christoph Hellwig Aug. 6, 2009, 4:09 p.m.
On Thu, Aug 06, 2009 at 04:48:20PM +0100, Bique Alexandre wrote:
> Few comments

Again not a very useful format for the patch.

I'd say something like

Subject: [PATCH n/m] atapi: fix up a few comments

Patch hide | download patch | download mbox

diff --git a/hw/ide.c b/hw/ide.c
index 1e56786..16ca80c 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; /* Obsolete: 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; /* Obsolete: 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 length */
                     buf[10] = 0x00;
                     buf[11] = 0x00;