1/****************************************************************************
2 ****************************************************************************
3 ***
4 ***   This header was automatically generated from a Linux kernel header
5 ***   of the same name, to make information necessary for userspace to
6 ***   call into the kernel available to libc.  It contains only constants,
7 ***   structures, and macros generated from the original header, and thus,
8 ***   contains no copyrightable information.
9 ***
10 ***   To edit the content of this header, modify the corresponding
11 ***   source file (e.g. under external/kernel-headers/original/) then
12 ***   run bionic/libc/kernel/tools/update_all.py
13 ***
14 ***   Any manual change here will be lost the next time this script will
15 ***   be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef _UAPI_LINUX_CDROM_H
20#define _UAPI_LINUX_CDROM_H
21#include <linux/types.h>
22#include <asm/byteorder.h>
23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24#define EDRIVE_CANT_DO_THIS EOPNOTSUPP
25#define CDROMPAUSE 0x5301
26#define CDROMRESUME 0x5302
27#define CDROMPLAYMSF 0x5303
28/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29#define CDROMPLAYTRKIND 0x5304
30#define CDROMREADTOCHDR 0x5305
31#define CDROMREADTOCENTRY 0x5306
32#define CDROMSTOP 0x5307
33/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34#define CDROMSTART 0x5308
35#define CDROMEJECT 0x5309
36#define CDROMVOLCTRL 0x530a
37#define CDROMSUBCHNL 0x530b
38/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
39#define CDROMREADMODE2 0x530c
40#define CDROMREADMODE1 0x530d
41#define CDROMREADAUDIO 0x530e
42#define CDROMEJECT_SW 0x530f
43/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
44#define CDROMMULTISESSION 0x5310
45#define CDROM_GET_MCN 0x5311
46#define CDROM_GET_UPC CDROM_GET_MCN
47#define CDROMRESET 0x5312
48/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49#define CDROMVOLREAD 0x5313
50#define CDROMREADRAW 0x5314
51#define CDROMREADCOOKED 0x5315
52#define CDROMSEEK 0x5316
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54#define CDROMPLAYBLK 0x5317
55#define CDROMREADALL 0x5318
56#define CDROMGETSPINDOWN 0x531d
57#define CDROMSETSPINDOWN 0x531e
58/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59#define CDROMCLOSETRAY 0x5319
60#define CDROM_SET_OPTIONS 0x5320
61#define CDROM_CLEAR_OPTIONS 0x5321
62#define CDROM_SELECT_SPEED 0x5322
63/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64#define CDROM_SELECT_DISC 0x5323
65#define CDROM_MEDIA_CHANGED 0x5325
66#define CDROM_DRIVE_STATUS 0x5326
67#define CDROM_DISC_STATUS 0x5327
68/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69#define CDROM_CHANGER_NSLOTS 0x5328
70#define CDROM_LOCKDOOR 0x5329
71#define CDROM_DEBUG 0x5330
72#define CDROM_GET_CAPABILITY 0x5331
73/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74#define CDROMAUDIOBUFSIZ 0x5382
75#define DVD_READ_STRUCT 0x5390
76#define DVD_WRITE_STRUCT 0x5391
77#define DVD_AUTH 0x5392
78/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79#define CDROM_SEND_PACKET 0x5393
80#define CDROM_NEXT_WRITABLE 0x5394
81#define CDROM_LAST_WRITTEN 0x5395
82struct cdrom_msf0
83/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
84{
85 __u8 minute;
86 __u8 second;
87 __u8 frame;
88/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
89};
90union cdrom_addr
91{
92 struct cdrom_msf0 msf;
93/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
94 int lba;
95};
96struct cdrom_msf
97{
98/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
99 __u8 cdmsf_min0;
100 __u8 cdmsf_sec0;
101 __u8 cdmsf_frame0;
102 __u8 cdmsf_min1;
103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
104 __u8 cdmsf_sec1;
105 __u8 cdmsf_frame1;
106};
107struct cdrom_ti
108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
109{
110 __u8 cdti_trk0;
111 __u8 cdti_ind0;
112 __u8 cdti_trk1;
113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
114 __u8 cdti_ind1;
115};
116struct cdrom_tochdr
117{
118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
119 __u8 cdth_trk0;
120 __u8 cdth_trk1;
121};
122struct cdrom_volctrl
123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
124{
125 __u8 channel0;
126 __u8 channel1;
127 __u8 channel2;
128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
129 __u8 channel3;
130};
131struct cdrom_subchnl
132{
133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
134 __u8 cdsc_format;
135 __u8 cdsc_audiostatus;
136 __u8 cdsc_adr: 4;
137 __u8 cdsc_ctrl: 4;
138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
139 __u8 cdsc_trk;
140 __u8 cdsc_ind;
141 union cdrom_addr cdsc_absaddr;
142 union cdrom_addr cdsc_reladdr;
143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
144};
145struct cdrom_tocentry
146{
147 __u8 cdte_track;
148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
149 __u8 cdte_adr :4;
150 __u8 cdte_ctrl :4;
151 __u8 cdte_format;
152 union cdrom_addr cdte_addr;
153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
154 __u8 cdte_datamode;
155};
156struct cdrom_read
157{
158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
159 int cdread_lba;
160 char *cdread_bufaddr;
161 int cdread_buflen;
162};
163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
164struct cdrom_read_audio
165{
166 union cdrom_addr addr;
167 __u8 addr_format;
168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
169 int nframes;
170 __u8 __user *buf;
171};
172struct cdrom_multisession
173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
174{
175 union cdrom_addr addr;
176 __u8 xa_flag;
177 __u8 addr_format;
178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
179};
180struct cdrom_mcn
181{
182 __u8 medium_catalog_number[14];
183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
184};
185struct cdrom_blk
186{
187 unsigned from;
188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
189 unsigned short len;
190};
191#define CDROM_PACKET_SIZE 12
192#define CGC_DATA_UNKNOWN 0
193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
194#define CGC_DATA_WRITE 1
195#define CGC_DATA_READ 2
196#define CGC_DATA_NONE 3
197struct cdrom_generic_command
198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
199{
200 unsigned char cmd[CDROM_PACKET_SIZE];
201 unsigned char __user *buffer;
202 unsigned int buflen;
203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
204 int stat;
205 struct request_sense __user *sense;
206 unsigned char data_direction;
207 int quiet;
208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
209 int timeout;
210 void __user *reserved[1];
211};
212#define CD_MINS 74
213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
214#define CD_SECS 60
215#define CD_FRAMES 75
216#define CD_SYNC_SIZE 12
217#define CD_MSF_OFFSET 150
218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
219#define CD_CHUNK_SIZE 24
220#define CD_NUM_OF_CHUNKS 98
221#define CD_FRAMESIZE_SUB 96
222#define CD_HEAD_SIZE 4
223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
224#define CD_SUBHEAD_SIZE 8
225#define CD_EDC_SIZE 4
226#define CD_ZERO_SIZE 8
227#define CD_ECC_SIZE 276
228/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
229#define CD_FRAMESIZE 2048
230#define CD_FRAMESIZE_RAW 2352
231#define CD_FRAMESIZE_RAWER 2646
232#define CD_FRAMESIZE_RAW1 (CD_FRAMESIZE_RAW-CD_SYNC_SIZE)
233/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
234#define CD_FRAMESIZE_RAW0 (CD_FRAMESIZE_RAW-CD_SYNC_SIZE-CD_HEAD_SIZE)
235#define CD_XA_HEAD (CD_HEAD_SIZE+CD_SUBHEAD_SIZE)
236#define CD_XA_TAIL (CD_EDC_SIZE+CD_ECC_SIZE)
237#define CD_XA_SYNC_HEAD (CD_SYNC_SIZE+CD_XA_HEAD)
238/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
239#define CDROM_LBA 0x01
240#define CDROM_MSF 0x02
241#define CDROM_DATA_TRACK 0x04
242#define CDROM_LEADOUT 0xAA
243/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
244#define CDROM_AUDIO_INVALID 0x00
245#define CDROM_AUDIO_PLAY 0x11
246#define CDROM_AUDIO_PAUSED 0x12
247#define CDROM_AUDIO_COMPLETED 0x13
248/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
249#define CDROM_AUDIO_ERROR 0x14
250#define CDROM_AUDIO_NO_STATUS 0x15
251#define CDC_CLOSE_TRAY 0x1
252#define CDC_OPEN_TRAY 0x2
253/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
254#define CDC_LOCK 0x4
255#define CDC_SELECT_SPEED 0x8
256#define CDC_SELECT_DISC 0x10
257#define CDC_MULTI_SESSION 0x20
258/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
259#define CDC_MCN 0x40
260#define CDC_MEDIA_CHANGED 0x80
261#define CDC_PLAY_AUDIO 0x100
262#define CDC_RESET 0x200
263/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
264#define CDC_DRIVE_STATUS 0x800
265#define CDC_GENERIC_PACKET 0x1000
266#define CDC_CD_R 0x2000
267#define CDC_CD_RW 0x4000
268/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
269#define CDC_DVD 0x8000
270#define CDC_DVD_R 0x10000
271#define CDC_DVD_RAM 0x20000
272#define CDC_MO_DRIVE 0x40000
273/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
274#define CDC_MRW 0x80000
275#define CDC_MRW_W 0x100000
276#define CDC_RAM 0x200000
277#define CDS_NO_INFO 0
278/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
279#define CDS_NO_DISC 1
280#define CDS_TRAY_OPEN 2
281#define CDS_DRIVE_NOT_READY 3
282#define CDS_DISC_OK 4
283/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
284#define CDS_AUDIO 100
285#define CDS_DATA_1 101
286#define CDS_DATA_2 102
287#define CDS_XA_2_1 103
288/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
289#define CDS_XA_2_2 104
290#define CDS_MIXED 105
291#define CDO_AUTO_CLOSE 0x1
292#define CDO_AUTO_EJECT 0x2
293/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
294#define CDO_USE_FFLAGS 0x4
295#define CDO_LOCK 0x8
296#define CDO_CHECK_TYPE 0x10
297#define CDSL_NONE (INT_MAX-1)
298/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
299#define CDSL_CURRENT INT_MAX
300#define CD_PART_MAX 64
301#define CD_PART_MASK (CD_PART_MAX - 1)
302#define GPCMD_BLANK 0xa1
303/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
304#define GPCMD_CLOSE_TRACK 0x5b
305#define GPCMD_FLUSH_CACHE 0x35
306#define GPCMD_FORMAT_UNIT 0x04
307#define GPCMD_GET_CONFIGURATION 0x46
308/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
309#define GPCMD_GET_EVENT_STATUS_NOTIFICATION 0x4a
310#define GPCMD_GET_PERFORMANCE 0xac
311#define GPCMD_INQUIRY 0x12
312#define GPCMD_LOAD_UNLOAD 0xa6
313/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
314#define GPCMD_MECHANISM_STATUS 0xbd
315#define GPCMD_MODE_SELECT_10 0x55
316#define GPCMD_MODE_SENSE_10 0x5a
317#define GPCMD_PAUSE_RESUME 0x4b
318/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
319#define GPCMD_PLAY_AUDIO_10 0x45
320#define GPCMD_PLAY_AUDIO_MSF 0x47
321#define GPCMD_PLAY_AUDIO_TI 0x48
322#define GPCMD_PLAY_CD 0xbc
323/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
324#define GPCMD_PREVENT_ALLOW_MEDIUM_REMOVAL 0x1e
325#define GPCMD_READ_10 0x28
326#define GPCMD_READ_12 0xa8
327#define GPCMD_READ_BUFFER 0x3c
328/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
329#define GPCMD_READ_BUFFER_CAPACITY 0x5c
330#define GPCMD_READ_CDVD_CAPACITY 0x25
331#define GPCMD_READ_CD 0xbe
332#define GPCMD_READ_CD_MSF 0xb9
333/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
334#define GPCMD_READ_DISC_INFO 0x51
335#define GPCMD_READ_DVD_STRUCTURE 0xad
336#define GPCMD_READ_FORMAT_CAPACITIES 0x23
337#define GPCMD_READ_HEADER 0x44
338/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
339#define GPCMD_READ_TRACK_RZONE_INFO 0x52
340#define GPCMD_READ_SUBCHANNEL 0x42
341#define GPCMD_READ_TOC_PMA_ATIP 0x43
342#define GPCMD_REPAIR_RZONE_TRACK 0x58
343/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
344#define GPCMD_REPORT_KEY 0xa4
345#define GPCMD_REQUEST_SENSE 0x03
346#define GPCMD_RESERVE_RZONE_TRACK 0x53
347#define GPCMD_SEND_CUE_SHEET 0x5d
348/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
349#define GPCMD_SCAN 0xba
350#define GPCMD_SEEK 0x2b
351#define GPCMD_SEND_DVD_STRUCTURE 0xbf
352#define GPCMD_SEND_EVENT 0xa2
353/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
354#define GPCMD_SEND_KEY 0xa3
355#define GPCMD_SEND_OPC 0x54
356#define GPCMD_SET_READ_AHEAD 0xa7
357#define GPCMD_SET_STREAMING 0xb6
358/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
359#define GPCMD_START_STOP_UNIT 0x1b
360#define GPCMD_STOP_PLAY_SCAN 0x4e
361#define GPCMD_TEST_UNIT_READY 0x00
362#define GPCMD_VERIFY_10 0x2f
363/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
364#define GPCMD_WRITE_10 0x2a
365#define GPCMD_WRITE_12 0xaa
366#define GPCMD_WRITE_AND_VERIFY_10 0x2e
367#define GPCMD_WRITE_BUFFER 0x3b
368/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
369#define GPCMD_SET_SPEED 0xbb
370#define GPCMD_PLAYAUDIO_TI 0x48
371#define GPCMD_GET_MEDIA_STATUS 0xda
372#define GPMODE_VENDOR_PAGE 0x00
373/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
374#define GPMODE_R_W_ERROR_PAGE 0x01
375#define GPMODE_WRITE_PARMS_PAGE 0x05
376#define GPMODE_WCACHING_PAGE 0x08
377#define GPMODE_AUDIO_CTL_PAGE 0x0e
378/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
379#define GPMODE_POWER_PAGE 0x1a
380#define GPMODE_FAULT_FAIL_PAGE 0x1c
381#define GPMODE_TO_PROTECT_PAGE 0x1d
382#define GPMODE_CAPABILITIES_PAGE 0x2a
383/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
384#define GPMODE_ALL_PAGES 0x3f
385#define GPMODE_CDROM_PAGE 0x0d
386#define DVD_STRUCT_PHYSICAL 0x00
387#define DVD_STRUCT_COPYRIGHT 0x01
388/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
389#define DVD_STRUCT_DISCKEY 0x02
390#define DVD_STRUCT_BCA 0x03
391#define DVD_STRUCT_MANUFACT 0x04
392struct dvd_layer {
393/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
394 __u8 book_version : 4;
395 __u8 book_type : 4;
396 __u8 min_rate : 4;
397 __u8 disc_size : 4;
398/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
399 __u8 layer_type : 4;
400 __u8 track_path : 1;
401 __u8 nlayers : 2;
402 __u8 track_density : 4;
403/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
404 __u8 linear_density : 4;
405 __u8 bca : 1;
406 __u32 start_sector;
407 __u32 end_sector;
408/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
409 __u32 end_sector_l0;
410};
411#define DVD_LAYERS 4
412struct dvd_physical {
413/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
414 __u8 type;
415 __u8 layer_num;
416 struct dvd_layer layer[DVD_LAYERS];
417};
418/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
419struct dvd_copyright {
420 __u8 type;
421 __u8 layer_num;
422 __u8 cpst;
423/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
424 __u8 rmi;
425};
426struct dvd_disckey {
427 __u8 type;
428/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
429 unsigned agid : 2;
430 __u8 value[2048];
431};
432struct dvd_bca {
433/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
434 __u8 type;
435 int len;
436 __u8 value[188];
437};
438/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
439struct dvd_manufact {
440 __u8 type;
441 __u8 layer_num;
442 int len;
443/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
444 __u8 value[2048];
445};
446typedef union {
447 __u8 type;
448/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
449 struct dvd_physical physical;
450 struct dvd_copyright copyright;
451 struct dvd_disckey disckey;
452 struct dvd_bca bca;
453/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
454 struct dvd_manufact manufact;
455} dvd_struct;
456#define DVD_LU_SEND_AGID 0
457#define DVD_HOST_SEND_CHALLENGE 1
458/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
459#define DVD_LU_SEND_KEY1 2
460#define DVD_LU_SEND_CHALLENGE 3
461#define DVD_HOST_SEND_KEY2 4
462#define DVD_AUTH_ESTABLISHED 5
463/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
464#define DVD_AUTH_FAILURE 6
465#define DVD_LU_SEND_TITLE_KEY 7
466#define DVD_LU_SEND_ASF 8
467#define DVD_INVALIDATE_AGID 9
468/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
469#define DVD_LU_SEND_RPC_STATE 10
470#define DVD_HOST_SEND_RPC_STATE 11
471typedef __u8 dvd_key[5];
472typedef __u8 dvd_challenge[10];
473/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
474struct dvd_lu_send_agid {
475 __u8 type;
476 unsigned agid : 2;
477};
478/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
479struct dvd_host_send_challenge {
480 __u8 type;
481 unsigned agid : 2;
482 dvd_challenge chal;
483/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
484};
485struct dvd_send_key {
486 __u8 type;
487 unsigned agid : 2;
488/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
489 dvd_key key;
490};
491struct dvd_lu_send_challenge {
492 __u8 type;
493/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
494 unsigned agid : 2;
495 dvd_challenge chal;
496};
497#define DVD_CPM_NO_COPYRIGHT 0
498/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
499#define DVD_CPM_COPYRIGHTED 1
500#define DVD_CP_SEC_NONE 0
501#define DVD_CP_SEC_EXIST 1
502#define DVD_CGMS_UNRESTRICTED 0
503/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
504#define DVD_CGMS_SINGLE 2
505#define DVD_CGMS_RESTRICTED 3
506struct dvd_lu_send_title_key {
507 __u8 type;
508/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
509 unsigned agid : 2;
510 dvd_key title_key;
511 int lba;
512 unsigned cpm : 1;
513/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
514 unsigned cp_sec : 1;
515 unsigned cgms : 2;
516};
517struct dvd_lu_send_asf {
518/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
519 __u8 type;
520 unsigned agid : 2;
521 unsigned asf : 1;
522};
523/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
524struct dvd_host_send_rpcstate {
525 __u8 type;
526 __u8 pdrc;
527};
528/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
529struct dvd_lu_send_rpcstate {
530 __u8 type : 2;
531 __u8 vra : 3;
532 __u8 ucca : 3;
533/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
534 __u8 region_mask;
535 __u8 rpc_scheme;
536};
537typedef union {
538/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
539 __u8 type;
540 struct dvd_lu_send_agid lsa;
541 struct dvd_host_send_challenge hsc;
542 struct dvd_send_key lsk;
543/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
544 struct dvd_lu_send_challenge lsc;
545 struct dvd_send_key hsk;
546 struct dvd_lu_send_title_key lstk;
547 struct dvd_lu_send_asf lsasf;
548/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
549 struct dvd_host_send_rpcstate hrpcs;
550 struct dvd_lu_send_rpcstate lrpcs;
551} dvd_authinfo;
552struct request_sense {
553/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
554#ifdef __BIG_ENDIAN_BITFIELD
555 __u8 valid : 1;
556 __u8 error_code : 7;
557#elif defined(__LITTLE_ENDIAN_BITFIELD)
558/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
559 __u8 error_code : 7;
560 __u8 valid : 1;
561#endif
562 __u8 segment_number;
563/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
564#ifdef __BIG_ENDIAN_BITFIELD
565 __u8 reserved1 : 2;
566 __u8 ili : 1;
567 __u8 reserved2 : 1;
568/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
569 __u8 sense_key : 4;
570#elif defined(__LITTLE_ENDIAN_BITFIELD)
571 __u8 sense_key : 4;
572 __u8 reserved2 : 1;
573/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
574 __u8 ili : 1;
575 __u8 reserved1 : 2;
576#endif
577 __u8 information[4];
578/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
579 __u8 add_sense_len;
580 __u8 command_info[4];
581 __u8 asc;
582 __u8 ascq;
583/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
584 __u8 fruc;
585 __u8 sks[3];
586 __u8 asb[46];
587};
588/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
589#define CDF_RWRT 0x0020
590#define CDF_HWDM 0x0024
591#define CDF_MRW 0x0028
592#define CDM_MRW_NOTMRW 0
593/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
594#define CDM_MRW_BGFORMAT_INACTIVE 1
595#define CDM_MRW_BGFORMAT_ACTIVE 2
596#define CDM_MRW_BGFORMAT_COMPLETE 3
597#define MRW_LBA_DMA 0
598/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
599#define MRW_LBA_GAA 1
600#define MRW_MODE_PC_PRE1 0x2c
601#define MRW_MODE_PC 0x03
602struct mrw_feature_desc {
603/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
604 __be16 feature_code;
605#ifdef __BIG_ENDIAN_BITFIELD
606 __u8 reserved1 : 2;
607 __u8 feature_version : 4;
608/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
609 __u8 persistent : 1;
610 __u8 curr : 1;
611#elif defined(__LITTLE_ENDIAN_BITFIELD)
612 __u8 curr : 1;
613/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
614 __u8 persistent : 1;
615 __u8 feature_version : 4;
616 __u8 reserved1 : 2;
617#endif
618/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
619 __u8 add_len;
620#ifdef __BIG_ENDIAN_BITFIELD
621 __u8 reserved2 : 7;
622 __u8 write : 1;
623/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
624#elif defined(__LITTLE_ENDIAN_BITFIELD)
625 __u8 write : 1;
626 __u8 reserved2 : 7;
627#endif
628/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
629 __u8 reserved3;
630 __u8 reserved4;
631 __u8 reserved5;
632};
633/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
634struct rwrt_feature_desc {
635 __be16 feature_code;
636#ifdef __BIG_ENDIAN_BITFIELD
637 __u8 reserved1 : 2;
638/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
639 __u8 feature_version : 4;
640 __u8 persistent : 1;
641 __u8 curr : 1;
642#elif defined(__LITTLE_ENDIAN_BITFIELD)
643/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
644 __u8 curr : 1;
645 __u8 persistent : 1;
646 __u8 feature_version : 4;
647 __u8 reserved1 : 2;
648/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
649#endif
650 __u8 add_len;
651 __u32 last_lba;
652 __u32 block_size;
653/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
654 __u16 blocking;
655#ifdef __BIG_ENDIAN_BITFIELD
656 __u8 reserved2 : 7;
657 __u8 page_present : 1;
658/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
659#elif defined(__LITTLE_ENDIAN_BITFIELD)
660 __u8 page_present : 1;
661 __u8 reserved2 : 7;
662#endif
663/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
664 __u8 reserved3;
665};
666typedef struct {
667 __be16 disc_information_length;
668/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
669#ifdef __BIG_ENDIAN_BITFIELD
670 __u8 reserved1 : 3;
671 __u8 erasable : 1;
672 __u8 border_status : 2;
673/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
674 __u8 disc_status : 2;
675#elif defined(__LITTLE_ENDIAN_BITFIELD)
676 __u8 disc_status : 2;
677 __u8 border_status : 2;
678/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
679 __u8 erasable : 1;
680 __u8 reserved1 : 3;
681#else
682#error "Please fix <asm/byteorder.h>"
683/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
684#endif
685 __u8 n_first_track;
686 __u8 n_sessions_lsb;
687 __u8 first_track_lsb;
688/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
689 __u8 last_track_lsb;
690#ifdef __BIG_ENDIAN_BITFIELD
691 __u8 did_v : 1;
692 __u8 dbc_v : 1;
693/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
694 __u8 uru : 1;
695 __u8 reserved2 : 2;
696 __u8 dbit : 1;
697 __u8 mrw_status : 2;
698/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
699#elif defined(__LITTLE_ENDIAN_BITFIELD)
700 __u8 mrw_status : 2;
701 __u8 dbit : 1;
702 __u8 reserved2 : 2;
703/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
704 __u8 uru : 1;
705 __u8 dbc_v : 1;
706 __u8 did_v : 1;
707#endif
708/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
709 __u8 disc_type;
710 __u8 n_sessions_msb;
711 __u8 first_track_msb;
712 __u8 last_track_msb;
713/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
714 __u32 disc_id;
715 __u32 lead_in;
716 __u32 lead_out;
717 __u8 disc_bar_code[8];
718/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
719 __u8 reserved3;
720 __u8 n_opc;
721} disc_information;
722typedef struct {
723/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
724 __be16 track_information_length;
725 __u8 track_lsb;
726 __u8 session_lsb;
727 __u8 reserved1;
728/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
729#ifdef __BIG_ENDIAN_BITFIELD
730 __u8 reserved2 : 2;
731 __u8 damage : 1;
732 __u8 copy : 1;
733/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
734 __u8 track_mode : 4;
735 __u8 rt : 1;
736 __u8 blank : 1;
737 __u8 packet : 1;
738/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
739 __u8 fp : 1;
740 __u8 data_mode : 4;
741 __u8 reserved3 : 6;
742 __u8 lra_v : 1;
743/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
744 __u8 nwa_v : 1;
745#elif defined(__LITTLE_ENDIAN_BITFIELD)
746 __u8 track_mode : 4;
747 __u8 copy : 1;
748/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
749 __u8 damage : 1;
750 __u8 reserved2 : 2;
751 __u8 data_mode : 4;
752 __u8 fp : 1;
753/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
754 __u8 packet : 1;
755 __u8 blank : 1;
756 __u8 rt : 1;
757 __u8 nwa_v : 1;
758/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
759 __u8 lra_v : 1;
760 __u8 reserved3 : 6;
761#endif
762 __be32 track_start;
763/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
764 __be32 next_writable;
765 __be32 free_blocks;
766 __be32 fixed_packet_size;
767 __be32 track_size;
768/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
769 __be32 last_rec_address;
770} track_information;
771struct feature_header {
772 __u32 data_len;
773/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
774 __u8 reserved1;
775 __u8 reserved2;
776 __u16 curr_profile;
777};
778/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
779struct mode_page_header {
780 __be16 mode_data_length;
781 __u8 medium_type;
782 __u8 reserved1;
783/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
784 __u8 reserved2;
785 __u8 reserved3;
786 __be16 desc_length;
787};
788/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
789struct rm_feature_desc {
790 __be16 feature_code;
791#ifdef __BIG_ENDIAN_BITFIELD
792 __u8 reserved1:2;
793/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
794 __u8 feature_version:4;
795 __u8 persistent:1;
796 __u8 curr:1;
797#elif defined(__LITTLE_ENDIAN_BITFIELD)
798/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
799 __u8 curr:1;
800 __u8 persistent:1;
801 __u8 feature_version:4;
802 __u8 reserved1:2;
803/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
804#endif
805 __u8 add_len;
806#ifdef __BIG_ENDIAN_BITFIELD
807 __u8 mech_type:3;
808/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
809 __u8 load:1;
810 __u8 eject:1;
811 __u8 pvnt_jmpr:1;
812 __u8 dbml:1;
813/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
814 __u8 lock:1;
815#elif defined(__LITTLE_ENDIAN_BITFIELD)
816 __u8 lock:1;
817 __u8 dbml:1;
818/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
819 __u8 pvnt_jmpr:1;
820 __u8 eject:1;
821 __u8 load:1;
822 __u8 mech_type:3;
823/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
824#endif
825 __u8 reserved2;
826 __u8 reserved3;
827 __u8 reserved4;
828/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
829};
830#endif
831