fix to allow loader.o to boot kernel with parametars
[linux-2.4.21-pre4.git] / drivers / ieee1394 / video1394.h
1 /*
2  * video1394.h - driver for OHCI 1394 boards
3  * Copyright (C)1999,2000 Sebastien Rougeaux <sebastien.rougeaux@anu.edu.au>
4  *                        Peter Schlaile <udbz@rz.uni-karlsruhe.de>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software Foundation,
18  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19  */
20
21 #ifndef _VIDEO_1394_H
22 #define _VIDEO_1394_H
23
24 #define VIDEO1394_DRIVER_NAME "video1394"
25
26 #define VIDEO1394_MAX_SIZE 0x4000000
27
28 enum {
29         VIDEO1394_BUFFER_FREE = 0,
30         VIDEO1394_BUFFER_QUEUED,
31         VIDEO1394_BUFFER_READY
32 };
33
34 enum {
35         VIDEO1394_LISTEN_CHANNEL = 0,
36         VIDEO1394_UNLISTEN_CHANNEL,
37         VIDEO1394_LISTEN_QUEUE_BUFFER,
38         VIDEO1394_LISTEN_WAIT_BUFFER,  // wait until buffer is ready
39         VIDEO1394_TALK_CHANNEL,
40         VIDEO1394_UNTALK_CHANNEL,
41         VIDEO1394_TALK_QUEUE_BUFFER,
42         VIDEO1394_TALK_WAIT_BUFFER,
43         VIDEO1394_LISTEN_POLL_BUFFER   // return immediately with -EINTR if not ready
44 };
45
46 #define VIDEO1394_SYNC_FRAMES          0x00000001
47 #define VIDEO1394_INCLUDE_ISO_HEADERS  0x00000002
48 #define VIDEO1394_VARIABLE_PACKET_SIZE 0x00000004
49
50 struct video1394_mmap {
51         int channel;                    /* -1 to find an open channel in LISTEN/TALK */
52         unsigned int sync_tag;
53         unsigned int nb_buffers;
54         unsigned int buf_size;
55         unsigned int packet_size; /* For VARIABLE_PACKET_SIZE: 
56                                      Maximum packet size */
57         unsigned int fps;
58         unsigned int syt_offset;
59         unsigned int flags;
60 };
61
62 /* For TALK_QUEUE_BUFFER with VIDEO1394_VARIABLE_PACKET_SIZE use */
63 struct video1394_queue_variable {
64         unsigned int channel;
65         unsigned int buffer;
66         unsigned int* packet_sizes; /* Buffer of size:  
67                                        buf_size / packet_size  */
68 };
69
70 struct video1394_wait {
71         unsigned int channel;
72         unsigned int buffer;
73         struct timeval filltime;        /* time of buffer full */
74 };
75
76
77 #endif