ide-cd.h revision f18f960c5c1568fa2f720e2cb31d6c1af9ea1e1a
1/* 2 * linux/drivers/ide/ide_cd.h 3 * 4 * Copyright (C) 1996-98 Erik Andersen 5 * Copyright (C) 1998-2000 Jens Axboe 6 */ 7#ifndef _IDE_CD_H 8#define _IDE_CD_H 9 10#include <linux/cdrom.h> 11#include <asm/byteorder.h> 12 13/* Turn this on to have the driver print out the meanings of the 14 ATAPI error codes. This will use up additional kernel-space 15 memory, though. */ 16 17#ifndef VERBOSE_IDE_CD_ERRORS 18#define VERBOSE_IDE_CD_ERRORS 1 19#endif 20 21 22/* Turning this on will remove code to work around various nonstandard 23 ATAPI implementations. If you know your drive follows the standard, 24 this will give you a slightly smaller kernel. */ 25 26#ifndef STANDARD_ATAPI 27#define STANDARD_ATAPI 0 28#endif 29 30 31/* Turning this on will disable the door-locking functionality. 32 This is apparently needed for supermount. */ 33 34#ifndef NO_DOOR_LOCKING 35#define NO_DOOR_LOCKING 0 36#endif 37 38/* 39 * typical timeout for packet command 40 */ 41#define ATAPI_WAIT_PC (60 * HZ) 42#define ATAPI_WAIT_WRITE_BUSY (10 * HZ) 43 44/************************************************************************/ 45 46#define SECTOR_BITS 9 47#ifndef SECTOR_SIZE 48#define SECTOR_SIZE (1 << SECTOR_BITS) 49#endif 50#define SECTORS_PER_FRAME (CD_FRAMESIZE >> SECTOR_BITS) 51#define SECTOR_BUFFER_SIZE (CD_FRAMESIZE * 32) 52 53/* Configuration flags. These describe the capabilities of the drive. 54 They generally do not change after initialization, unless we learn 55 more about the drive from stuff failing. */ 56struct ide_cd_config_flags { 57 __u8 drq_interrupt : 1; /* Device sends an interrupt when ready 58 for a packet command. */ 59 __u8 no_doorlock : 1; /* Drive cannot lock the door. */ 60 __u8 no_eject : 1; /* Drive cannot eject the disc. */ 61 __u8 nec260 : 1; /* Drive is a pre-1.2 NEC 260 drive. */ 62 __u8 tocaddr_as_bcd : 1; /* TOC addresses are in BCD. */ 63 __u8 toctracks_as_bcd : 1; /* TOC track numbers are in BCD. */ 64 __u8 is_changer : 1; /* Drive is a changer. */ 65 __u8 cd_r : 1; /* Drive can write to CD-R media . */ 66 __u8 cd_rw : 1; /* Drive can write to CD-R/W media . */ 67 __u8 dvd : 1; /* Drive is a DVD-ROM */ 68 __u8 dvd_r : 1; /* Drive can write DVD-R */ 69 __u8 dvd_ram : 1; /* Drive can write DVD-RAM */ 70 __u8 ram : 1; /* generic WRITE (dvd-ram/mrw) */ 71 __u8 limit_nframes : 1; /* Drive does not provide data in 72 multiples of SECTOR_SIZE when more 73 than one interrupt is needed. */ 74 __u8 seeking : 1; /* Seeking in progress */ 75 __u8 audio_play : 1; /* can do audio related commands */ 76 __u8 close_tray : 1; /* can close the tray */ 77 __u8 mo_drive : 1; /* drive is an MO device */ 78 __u8 no_speed_select : 1; /* SET_CD_SPEED command is unsupported. */ 79 byte max_speed; /* Max speed of the drive */ 80}; 81#define CDROM_CONFIG_FLAGS(drive) (&(((struct cdrom_info *)(drive->driver_data))->config_flags)) 82 83 84/* State flags. These give information about the current state of the 85 drive, and will change during normal operation. */ 86struct ide_cd_state_flags { 87 __u8 media_changed : 1; /* Driver has noticed a media change. */ 88 __u8 toc_valid : 1; /* Saved TOC information is current. */ 89 __u8 door_locked : 1; /* We think that the drive door is locked. */ 90 __u8 writing : 1; /* the drive is currently writing */ 91 __u8 reserved : 4; 92 byte current_speed; /* Current speed of the drive */ 93}; 94 95#define CDROM_STATE_FLAGS(drive) (&(((struct cdrom_info *)(drive->driver_data))->state_flags)) 96 97/* Structure of a MSF cdrom address. */ 98struct atapi_msf { 99 byte reserved; 100 byte minute; 101 byte second; 102 byte frame; 103}; 104 105/* Space to hold the disk TOC. */ 106#define MAX_TRACKS 99 107struct atapi_toc_header { 108 unsigned short toc_length; 109 byte first_track; 110 byte last_track; 111}; 112 113struct atapi_toc_entry { 114 byte reserved1; 115#if defined(__BIG_ENDIAN_BITFIELD) 116 __u8 adr : 4; 117 __u8 control : 4; 118#elif defined(__LITTLE_ENDIAN_BITFIELD) 119 __u8 control : 4; 120 __u8 adr : 4; 121#else 122#error "Please fix <asm/byteorder.h>" 123#endif 124 byte track; 125 byte reserved2; 126 union { 127 unsigned lba; 128 struct atapi_msf msf; 129 } addr; 130}; 131 132struct atapi_toc { 133 int last_session_lba; 134 int xa_flag; 135 unsigned long capacity; 136 struct atapi_toc_header hdr; 137 struct atapi_toc_entry ent[MAX_TRACKS+1]; 138 /* One extra for the leadout. */ 139}; 140 141/* This should probably go into cdrom.h along with the other 142 * generic stuff now in the Mt. Fuji spec. 143 */ 144struct atapi_capabilities_page { 145 struct mode_page_header header; 146#if defined(__BIG_ENDIAN_BITFIELD) 147 __u8 parameters_saveable : 1; 148 __u8 reserved1 : 1; 149 __u8 page_code : 6; 150#elif defined(__LITTLE_ENDIAN_BITFIELD) 151 __u8 page_code : 6; 152 __u8 reserved1 : 1; 153 __u8 parameters_saveable : 1; 154#else 155#error "Please fix <asm/byteorder.h>" 156#endif 157 158 byte page_length; 159 160#if defined(__BIG_ENDIAN_BITFIELD) 161 __u8 reserved2 : 2; 162 /* Drive supports reading of DVD-RAM discs */ 163 __u8 dvd_ram_read : 1; 164 /* Drive supports reading of DVD-R discs */ 165 __u8 dvd_r_read : 1; 166 /* Drive supports reading of DVD-ROM discs */ 167 __u8 dvd_rom : 1; 168 /* Drive supports reading CD-R discs with addressing method 2 */ 169 __u8 method2 : 1; /* reserved in 1.2 */ 170 /* Drive can read from CD-R/W (CD-E) discs (orange book, part III) */ 171 __u8 cd_rw_read : 1; /* reserved in 1.2 */ 172 /* Drive supports read from CD-R discs (orange book, part II) */ 173 __u8 cd_r_read : 1; /* reserved in 1.2 */ 174#elif defined(__LITTLE_ENDIAN_BITFIELD) 175 /* Drive supports read from CD-R discs (orange book, part II) */ 176 __u8 cd_r_read : 1; /* reserved in 1.2 */ 177 /* Drive can read from CD-R/W (CD-E) discs (orange book, part III) */ 178 __u8 cd_rw_read : 1; /* reserved in 1.2 */ 179 /* Drive supports reading CD-R discs with addressing method 2 */ 180 __u8 method2 : 1; 181 /* Drive supports reading of DVD-ROM discs */ 182 __u8 dvd_rom : 1; 183 /* Drive supports reading of DVD-R discs */ 184 __u8 dvd_r_read : 1; 185 /* Drive supports reading of DVD-RAM discs */ 186 __u8 dvd_ram_read : 1; 187 __u8 reserved2 : 2; 188#else 189#error "Please fix <asm/byteorder.h>" 190#endif 191 192#if defined(__BIG_ENDIAN_BITFIELD) 193 __u8 reserved3 : 2; 194 /* Drive can write DVD-RAM discs */ 195 __u8 dvd_ram_write : 1; 196 /* Drive can write DVD-R discs */ 197 __u8 dvd_r_write : 1; 198 __u8 reserved3a : 1; 199 /* Drive can fake writes */ 200 __u8 test_write : 1; 201 /* Drive can write to CD-R/W (CD-E) discs (orange book, part III) */ 202 __u8 cd_rw_write : 1; /* reserved in 1.2 */ 203 /* Drive supports write to CD-R discs (orange book, part II) */ 204 __u8 cd_r_write : 1; /* reserved in 1.2 */ 205#elif defined(__LITTLE_ENDIAN_BITFIELD) 206 /* Drive can write to CD-R discs (orange book, part II) */ 207 __u8 cd_r_write : 1; /* reserved in 1.2 */ 208 /* Drive can write to CD-R/W (CD-E) discs (orange book, part III) */ 209 __u8 cd_rw_write : 1; /* reserved in 1.2 */ 210 /* Drive can fake writes */ 211 __u8 test_write : 1; 212 __u8 reserved3a : 1; 213 /* Drive can write DVD-R discs */ 214 __u8 dvd_r_write : 1; 215 /* Drive can write DVD-RAM discs */ 216 __u8 dvd_ram_write : 1; 217 __u8 reserved3 : 2; 218#else 219#error "Please fix <asm/byteorder.h>" 220#endif 221 222#if defined(__BIG_ENDIAN_BITFIELD) 223 __u8 reserved4 : 1; 224 /* Drive can read multisession discs. */ 225 __u8 multisession : 1; 226 /* Drive can read mode 2, form 2 data. */ 227 __u8 mode2_form2 : 1; 228 /* Drive can read mode 2, form 1 (XA) data. */ 229 __u8 mode2_form1 : 1; 230 /* Drive supports digital output on port 2. */ 231 __u8 digport2 : 1; 232 /* Drive supports digital output on port 1. */ 233 __u8 digport1 : 1; 234 /* Drive can deliver a composite audio/video data stream. */ 235 __u8 composite : 1; 236 /* Drive supports audio play operations. */ 237 __u8 audio_play : 1; 238#elif defined(__LITTLE_ENDIAN_BITFIELD) 239 /* Drive supports audio play operations. */ 240 __u8 audio_play : 1; 241 /* Drive can deliver a composite audio/video data stream. */ 242 __u8 composite : 1; 243 /* Drive supports digital output on port 1. */ 244 __u8 digport1 : 1; 245 /* Drive supports digital output on port 2. */ 246 __u8 digport2 : 1; 247 /* Drive can read mode 2, form 1 (XA) data. */ 248 __u8 mode2_form1 : 1; 249 /* Drive can read mode 2, form 2 data. */ 250 __u8 mode2_form2 : 1; 251 /* Drive can read multisession discs. */ 252 __u8 multisession : 1; 253 __u8 reserved4 : 1; 254#else 255#error "Please fix <asm/byteorder.h>" 256#endif 257 258#if defined(__BIG_ENDIAN_BITFIELD) 259 __u8 reserved5 : 1; 260 /* Drive can return Media Catalog Number (UPC) info. */ 261 __u8 upc : 1; 262 /* Drive can return International Standard Recording Code info. */ 263 __u8 isrc : 1; 264 /* Drive supports C2 error pointers. */ 265 __u8 c2_pointers : 1; 266 /* R-W data will be returned deinterleaved and error corrected. */ 267 __u8 rw_corr : 1; 268 /* Subchannel reads can return combined R-W information. */ 269 __u8 rw_supported : 1; 270 /* Drive can continue a read cdda operation from a loss of streaming.*/ 271 __u8 cdda_accurate : 1; 272 /* Drive can read Red Book audio data. */ 273 __u8 cdda : 1; 274#elif defined(__LITTLE_ENDIAN_BITFIELD) 275 /* Drive can read Red Book audio data. */ 276 __u8 cdda : 1; 277 /* Drive can continue a read cdda operation from a loss of streaming.*/ 278 __u8 cdda_accurate : 1; 279 /* Subchannel reads can return combined R-W information. */ 280 __u8 rw_supported : 1; 281 /* R-W data will be returned deinterleaved and error corrected. */ 282 __u8 rw_corr : 1; 283 /* Drive supports C2 error pointers. */ 284 __u8 c2_pointers : 1; 285 /* Drive can return International Standard Recording Code info. */ 286 __u8 isrc : 1; 287 /* Drive can return Media Catalog Number (UPC) info. */ 288 __u8 upc : 1; 289 __u8 reserved5 : 1; 290#else 291#error "Please fix <asm/byteorder.h>" 292#endif 293 294#if defined(__BIG_ENDIAN_BITFIELD) 295 /* Drive mechanism types. */ 296 mechtype_t mechtype : 3; 297 __u8 reserved6 : 1; 298 /* Drive can eject a disc or changer cartridge. */ 299 __u8 eject : 1; 300 /* State of prevent/allow jumper. */ 301 __u8 prevent_jumper : 1; 302 /* Present state of door lock. */ 303 __u8 lock_state : 1; 304 /* Drive can lock the door. */ 305 __u8 lock : 1; 306#elif defined(__LITTLE_ENDIAN_BITFIELD) 307 308 /* Drive can lock the door. */ 309 __u8 lock : 1; 310 /* Present state of door lock. */ 311 __u8 lock_state : 1; 312 /* State of prevent/allow jumper. */ 313 __u8 prevent_jumper : 1; 314 /* Drive can eject a disc or changer cartridge. */ 315 __u8 eject : 1; 316 __u8 reserved6 : 1; 317 /* Drive mechanism types. */ 318 mechtype_t mechtype : 3; 319#else 320#error "Please fix <asm/byteorder.h>" 321#endif 322 323#if defined(__BIG_ENDIAN_BITFIELD) 324 __u8 reserved7 : 4; 325 /* Drive supports software slot selection. */ 326 __u8 sss : 1; /* reserved in 1.2 */ 327 /* Changer can report exact contents of slots. */ 328 __u8 disc_present : 1; /* reserved in 1.2 */ 329 /* Audio for each channel can be muted independently. */ 330 __u8 separate_mute : 1; 331 /* Audio level for each channel can be controlled independently. */ 332 __u8 separate_volume : 1; 333#elif defined(__LITTLE_ENDIAN_BITFIELD) 334 335 /* Audio level for each channel can be controlled independently. */ 336 __u8 separate_volume : 1; 337 /* Audio for each channel can be muted independently. */ 338 __u8 separate_mute : 1; 339 /* Changer can report exact contents of slots. */ 340 __u8 disc_present : 1; /* reserved in 1.2 */ 341 /* Drive supports software slot selection. */ 342 __u8 sss : 1; /* reserved in 1.2 */ 343 __u8 reserved7 : 4; 344#else 345#error "Please fix <asm/byteorder.h>" 346#endif 347 348 /* Note: the following four fields are returned in big-endian form. */ 349 /* Maximum speed (in kB/s). */ 350 unsigned short maxspeed; 351 /* Number of discrete volume levels. */ 352 unsigned short n_vol_levels; 353 /* Size of cache in drive, in kB. */ 354 unsigned short buffer_size; 355 /* Current speed (in kB/s). */ 356 unsigned short curspeed; 357 char pad[4]; 358}; 359 360/* Extra per-device info for cdrom drives. */ 361struct cdrom_info { 362 ide_drive_t *drive; 363 ide_driver_t *driver; 364 struct gendisk *disk; 365 struct kref kref; 366 367 /* Buffer for table of contents. NULL if we haven't allocated 368 a TOC buffer for this device yet. */ 369 370 struct atapi_toc *toc; 371 372 unsigned long sector_buffered; 373 unsigned long nsectors_buffered; 374 unsigned char *buffer; 375 376 /* The result of the last successful request sense command 377 on this device. */ 378 struct request_sense sense_data; 379 380 struct request request_sense_request; 381 int dma; 382 unsigned long last_block; 383 unsigned long start_seek; 384 385 struct ide_cd_config_flags config_flags; 386 struct ide_cd_state_flags state_flags; 387 388 /* Per-device info needed by cdrom.c generic driver. */ 389 struct cdrom_device_info devinfo; 390 391 unsigned long write_timeout; 392}; 393 394/**************************************************************************** 395 * Descriptions of ATAPI error codes. 396 */ 397 398/* This stuff should be in cdrom.h, since it is now generic... */ 399 400/* ATAPI sense keys (from table 140 of ATAPI 2.6) */ 401#define NO_SENSE 0x00 402#define RECOVERED_ERROR 0x01 403#define NOT_READY 0x02 404#define MEDIUM_ERROR 0x03 405#define HARDWARE_ERROR 0x04 406#define ILLEGAL_REQUEST 0x05 407#define UNIT_ATTENTION 0x06 408#define DATA_PROTECT 0x07 409#define BLANK_CHECK 0x08 410#define ABORTED_COMMAND 0x0b 411#define MISCOMPARE 0x0e 412 413 414 415/* This stuff should be in cdrom.h, since it is now generic... */ 416#if VERBOSE_IDE_CD_ERRORS 417 418 /* The generic packet command opcodes for CD/DVD Logical Units, 419 * From Table 57 of the SFF8090 Ver. 3 (Mt. Fuji) draft standard. */ 420static const struct { 421 unsigned short packet_command; 422 const char * const text; 423} packet_command_texts[] = { 424 { GPCMD_TEST_UNIT_READY, "Test Unit Ready" }, 425 { GPCMD_REQUEST_SENSE, "Request Sense" }, 426 { GPCMD_FORMAT_UNIT, "Format Unit" }, 427 { GPCMD_INQUIRY, "Inquiry" }, 428 { GPCMD_START_STOP_UNIT, "Start/Stop Unit" }, 429 { GPCMD_PREVENT_ALLOW_MEDIUM_REMOVAL, "Prevent/Allow Medium Removal" }, 430 { GPCMD_READ_FORMAT_CAPACITIES, "Read Format Capacities" }, 431 { GPCMD_READ_CDVD_CAPACITY, "Read Cd/Dvd Capacity" }, 432 { GPCMD_READ_10, "Read 10" }, 433 { GPCMD_WRITE_10, "Write 10" }, 434 { GPCMD_SEEK, "Seek" }, 435 { GPCMD_WRITE_AND_VERIFY_10, "Write and Verify 10" }, 436 { GPCMD_VERIFY_10, "Verify 10" }, 437 { GPCMD_FLUSH_CACHE, "Flush Cache" }, 438 { GPCMD_READ_SUBCHANNEL, "Read Subchannel" }, 439 { GPCMD_READ_TOC_PMA_ATIP, "Read Table of Contents" }, 440 { GPCMD_READ_HEADER, "Read Header" }, 441 { GPCMD_PLAY_AUDIO_10, "Play Audio 10" }, 442 { GPCMD_GET_CONFIGURATION, "Get Configuration" }, 443 { GPCMD_PLAY_AUDIO_MSF, "Play Audio MSF" }, 444 { GPCMD_PLAYAUDIO_TI, "Play Audio TrackIndex" }, 445 { GPCMD_GET_EVENT_STATUS_NOTIFICATION, "Get Event Status Notification" }, 446 { GPCMD_PAUSE_RESUME, "Pause/Resume" }, 447 { GPCMD_STOP_PLAY_SCAN, "Stop Play/Scan" }, 448 { GPCMD_READ_DISC_INFO, "Read Disc Info" }, 449 { GPCMD_READ_TRACK_RZONE_INFO, "Read Track Rzone Info" }, 450 { GPCMD_RESERVE_RZONE_TRACK, "Reserve Rzone Track" }, 451 { GPCMD_SEND_OPC, "Send OPC" }, 452 { GPCMD_MODE_SELECT_10, "Mode Select 10" }, 453 { GPCMD_REPAIR_RZONE_TRACK, "Repair Rzone Track" }, 454 { GPCMD_MODE_SENSE_10, "Mode Sense 10" }, 455 { GPCMD_CLOSE_TRACK, "Close Track" }, 456 { GPCMD_BLANK, "Blank" }, 457 { GPCMD_SEND_EVENT, "Send Event" }, 458 { GPCMD_SEND_KEY, "Send Key" }, 459 { GPCMD_REPORT_KEY, "Report Key" }, 460 { GPCMD_LOAD_UNLOAD, "Load/Unload" }, 461 { GPCMD_SET_READ_AHEAD, "Set Read-ahead" }, 462 { GPCMD_READ_12, "Read 12" }, 463 { GPCMD_GET_PERFORMANCE, "Get Performance" }, 464 { GPCMD_SEND_DVD_STRUCTURE, "Send DVD Structure" }, 465 { GPCMD_READ_DVD_STRUCTURE, "Read DVD Structure" }, 466 { GPCMD_SET_STREAMING, "Set Streaming" }, 467 { GPCMD_READ_CD_MSF, "Read CD MSF" }, 468 { GPCMD_SCAN, "Scan" }, 469 { GPCMD_SET_SPEED, "Set Speed" }, 470 { GPCMD_PLAY_CD, "Play CD" }, 471 { GPCMD_MECHANISM_STATUS, "Mechanism Status" }, 472 { GPCMD_READ_CD, "Read CD" }, 473}; 474 475 476 477/* From Table 303 of the SFF8090 Ver. 3 (Mt. Fuji) draft standard. */ 478static const char * const sense_key_texts[16] = { 479 "No sense data", 480 "Recovered error", 481 "Not ready", 482 "Medium error", 483 "Hardware error", 484 "Illegal request", 485 "Unit attention", 486 "Data protect", 487 "Blank check", 488 "(reserved)", 489 "(reserved)", 490 "Aborted command", 491 "(reserved)", 492 "(reserved)", 493 "Miscompare", 494 "(reserved)", 495}; 496 497/* From Table 304 of the SFF8090 Ver. 3 (Mt. Fuji) draft standard. */ 498static const struct { 499 unsigned long asc_ascq; 500 const char * const text; 501} sense_data_texts[] = { 502 { 0x000000, "No additional sense information" }, 503 { 0x000011, "Play operation in progress" }, 504 { 0x000012, "Play operation paused" }, 505 { 0x000013, "Play operation successfully completed" }, 506 { 0x000014, "Play operation stopped due to error" }, 507 { 0x000015, "No current audio status to return" }, 508 { 0x010c0a, "Write error - padding blocks added" }, 509 { 0x011700, "Recovered data with no error correction applied" }, 510 { 0x011701, "Recovered data with retries" }, 511 { 0x011702, "Recovered data with positive head offset" }, 512 { 0x011703, "Recovered data with negative head offset" }, 513 { 0x011704, "Recovered data with retries and/or CIRC applied" }, 514 { 0x011705, "Recovered data using previous sector ID" }, 515 { 0x011800, "Recovered data with error correction applied" }, 516 { 0x011801, "Recovered data with error correction and retries applied"}, 517 { 0x011802, "Recovered data - the data was auto-reallocated" }, 518 { 0x011803, "Recovered data with CIRC" }, 519 { 0x011804, "Recovered data with L-EC" }, 520 { 0x015d00, 521 "Failure prediction threshold exceeded - Predicted logical unit failure" }, 522 { 0x015d01, 523 "Failure prediction threshold exceeded - Predicted media failure" }, 524 { 0x015dff, "Failure prediction threshold exceeded - False" }, 525 { 0x017301, "Power calibration area almost full" }, 526 { 0x020400, "Logical unit not ready - cause not reportable" }, 527 /* Following is misspelled in ATAPI 2.6, _and_ in Mt. Fuji */ 528 { 0x020401, 529 "Logical unit not ready - in progress [sic] of becoming ready" }, 530 { 0x020402, "Logical unit not ready - initializing command required" }, 531 { 0x020403, "Logical unit not ready - manual intervention required" }, 532 { 0x020404, "Logical unit not ready - format in progress" }, 533 { 0x020407, "Logical unit not ready - operation in progress" }, 534 { 0x020408, "Logical unit not ready - long write in progress" }, 535 { 0x020600, "No reference position found (media may be upside down)" }, 536 { 0x023000, "Incompatible medium installed" }, 537 { 0x023a00, "Medium not present" }, 538 { 0x025300, "Media load or eject failed" }, 539 { 0x025700, "Unable to recover table of contents" }, 540 { 0x030300, "Peripheral device write fault" }, 541 { 0x030301, "No write current" }, 542 { 0x030302, "Excessive write errors" }, 543 { 0x030c00, "Write error" }, 544 { 0x030c01, "Write error - Recovered with auto reallocation" }, 545 { 0x030c02, "Write error - auto reallocation failed" }, 546 { 0x030c03, "Write error - recommend reassignment" }, 547 { 0x030c04, "Compression check miscompare error" }, 548 { 0x030c05, "Data expansion occurred during compress" }, 549 { 0x030c06, "Block not compressible" }, 550 { 0x030c07, "Write error - recovery needed" }, 551 { 0x030c08, "Write error - recovery failed" }, 552 { 0x030c09, "Write error - loss of streaming" }, 553 { 0x031100, "Unrecovered read error" }, 554 { 0x031106, "CIRC unrecovered error" }, 555 { 0x033101, "Format command failed" }, 556 { 0x033200, "No defect spare location available" }, 557 { 0x033201, "Defect list update failure" }, 558 { 0x035100, "Erase failure" }, 559 { 0x037200, "Session fixation error" }, 560 { 0x037201, "Session fixation error writin lead-in" }, 561 { 0x037202, "Session fixation error writin lead-out" }, 562 { 0x037300, "CD control error" }, 563 { 0x037302, "Power calibration area is full" }, 564 { 0x037303, "Power calibration area error" }, 565 { 0x037304, "Program memory area / RMA update failure" }, 566 { 0x037305, "Program memory area / RMA is full" }, 567 { 0x037306, "Program memory area / RMA is (almost) full" }, 568 569 { 0x040200, "No seek complete" }, 570 { 0x040300, "Write fault" }, 571 { 0x040900, "Track following error" }, 572 { 0x040901, "Tracking servo failure" }, 573 { 0x040902, "Focus servo failure" }, 574 { 0x040903, "Spindle servo failure" }, 575 { 0x041500, "Random positioning error" }, 576 { 0x041501, "Mechanical positioning or changer error" }, 577 { 0x041502, "Positioning error detected by read of medium" }, 578 { 0x043c00, "Mechanical positioning or changer error" }, 579 { 0x044000, "Diagnostic failure on component (ASCQ)" }, 580 { 0x044400, "Internal CD/DVD logical unit failure" }, 581 { 0x04b600, "Media load mechanism failed" }, 582 { 0x051a00, "Parameter list length error" }, 583 { 0x052000, "Invalid command operation code" }, 584 { 0x052100, "Logical block address out of range" }, 585 { 0x052102, "Invalid address for write" }, 586 { 0x052400, "Invalid field in command packet" }, 587 { 0x052600, "Invalid field in parameter list" }, 588 { 0x052601, "Parameter not supported" }, 589 { 0x052602, "Parameter value invalid" }, 590 { 0x052700, "Write protected media" }, 591 { 0x052c00, "Command sequence error" }, 592 { 0x052c03, "Current program area is not empty" }, 593 { 0x052c04, "Current program area is empty" }, 594 { 0x053001, "Cannot read medium - unknown format" }, 595 { 0x053002, "Cannot read medium - incompatible format" }, 596 { 0x053900, "Saving parameters not supported" }, 597 { 0x054e00, "Overlapped commands attempted" }, 598 { 0x055302, "Medium removal prevented" }, 599 { 0x055500, "System resource failure" }, 600 { 0x056300, "End of user area encountered on this track" }, 601 { 0x056400, "Illegal mode for this track or incompatible medium" }, 602 { 0x056f00, "Copy protection key exchange failure - Authentication failure" }, 603 { 0x056f01, "Copy protection key exchange failure - Key not present" }, 604 { 0x056f02, "Copy protection key exchange failure - Key not established" }, 605 { 0x056f03, "Read of scrambled sector without authentication" }, 606 { 0x056f04, "Media region code is mismatched to logical unit" }, 607 { 0x056f05, "Drive region must be permanent / region reset count error" }, 608 { 0x057203, "Session fixation error - incomplete track in session" }, 609 { 0x057204, "Empty or partially written reserved track" }, 610 { 0x057205, "No more RZONE reservations are allowed" }, 611 { 0x05bf00, "Loss of streaming" }, 612 { 0x062800, "Not ready to ready transition, medium may have changed" }, 613 { 0x062900, "Power on, reset or hardware reset occurred" }, 614 { 0x062a00, "Parameters changed" }, 615 { 0x062a01, "Mode parameters changed" }, 616 { 0x062e00, "Insufficient time for operation" }, 617 { 0x063f00, "Logical unit operating conditions have changed" }, 618 { 0x063f01, "Microcode has been changed" }, 619 { 0x065a00, "Operator request or state change input (unspecified)" }, 620 { 0x065a01, "Operator medium removal request" }, 621 { 0x0bb900, "Play operation aborted" }, 622 623 /* Here we use 0xff for the key (not a valid key) to signify 624 * that these can have _any_ key value associated with them... */ 625 { 0xff0401, "Logical unit is in process of becoming ready" }, 626 { 0xff0400, "Logical unit not ready, cause not reportable" }, 627 { 0xff0402, "Logical unit not ready, initializing command required" }, 628 { 0xff0403, "Logical unit not ready, manual intervention required" }, 629 { 0xff0500, "Logical unit does not respond to selection" }, 630 { 0xff0800, "Logical unit communication failure" }, 631 { 0xff0802, "Logical unit communication parity error" }, 632 { 0xff0801, "Logical unit communication time-out" }, 633 { 0xff2500, "Logical unit not supported" }, 634 { 0xff4c00, "Logical unit failed self-configuration" }, 635 { 0xff3e00, "Logical unit has not self-configured yet" }, 636}; 637#endif 638 639 640#endif /* _IDE_CD_H */ 641