ieee1394-ioctl.h 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. /* Base file for all ieee1394 ioctl's. Linux-1394 has allocated base '#'
  2. * with a range of 0x00-0x3f. */
  3. #ifndef __IEEE1394_IOCTL_H
  4. #define __IEEE1394_IOCTL_H
  5. #include <linux/ioctl.h>
  6. #include <linux/types.h>
  7. /* DV1394 Gets 10 */
  8. /* Get the driver ready to transmit video. pass a struct dv1394_init* as
  9. * the parameter (see below), or NULL to get default parameters */
  10. #define DV1394_IOC_INIT _IOW('#', 0x06, struct dv1394_init)
  11. /* Stop transmitting video and free the ringbuffer */
  12. #define DV1394_IOC_SHUTDOWN _IO ('#', 0x07)
  13. /* Submit N new frames to be transmitted, where the index of the first new
  14. * frame is first_clear_buffer, and the index of the last new frame is
  15. * (first_clear_buffer + N) % n_frames */
  16. #define DV1394_IOC_SUBMIT_FRAMES _IO ('#', 0x08)
  17. /* Block until N buffers are clear (pass N as the parameter) Because we
  18. * re-transmit the last frame on underrun, there will at most be n_frames
  19. * - 1 clear frames at any time */
  20. #define DV1394_IOC_WAIT_FRAMES _IO ('#', 0x09)
  21. /* Capture new frames that have been received, where the index of the
  22. * first new frame is first_clear_buffer, and the index of the last new
  23. * frame is (first_clear_buffer + N) % n_frames */
  24. #define DV1394_IOC_RECEIVE_FRAMES _IO ('#', 0x0a)
  25. /* Tell card to start receiving DMA */
  26. #define DV1394_IOC_START_RECEIVE _IO ('#', 0x0b)
  27. /* Pass a struct dv1394_status* as the parameter */
  28. #define DV1394_IOC_GET_STATUS _IOR('#', 0x0c, struct dv1394_status)
  29. /* Video1394 Gets 10 */
  30. #define VIDEO1394_IOC_LISTEN_CHANNEL \
  31. _IOWR('#', 0x10, struct video1394_mmap)
  32. #define VIDEO1394_IOC_UNLISTEN_CHANNEL \
  33. _IOW ('#', 0x11, int)
  34. #define VIDEO1394_IOC_LISTEN_QUEUE_BUFFER \
  35. _IOW ('#', 0x12, struct video1394_wait)
  36. #define VIDEO1394_IOC_LISTEN_WAIT_BUFFER \
  37. _IOWR('#', 0x13, struct video1394_wait)
  38. #define VIDEO1394_IOC_TALK_CHANNEL \
  39. _IOWR('#', 0x14, struct video1394_mmap)
  40. #define VIDEO1394_IOC_UNTALK_CHANNEL \
  41. _IOW ('#', 0x15, int)
  42. /*
  43. * This one is broken: it really wanted
  44. * "sizeof (struct video1394_wait) + sizeof (struct video1394_queue_variable)"
  45. * but got just a "size_t"
  46. */
  47. #define VIDEO1394_IOC_TALK_QUEUE_BUFFER \
  48. _IOW ('#', 0x16, size_t)
  49. #define VIDEO1394_IOC_TALK_WAIT_BUFFER \
  50. _IOW ('#', 0x17, struct video1394_wait)
  51. #define VIDEO1394_IOC_LISTEN_POLL_BUFFER \
  52. _IOWR('#', 0x18, struct video1394_wait)
  53. /* Raw1394's ISO interface */
  54. #define RAW1394_IOC_ISO_XMIT_INIT \
  55. _IOW ('#', 0x1a, struct raw1394_iso_status)
  56. #define RAW1394_IOC_ISO_RECV_INIT \
  57. _IOWR('#', 0x1b, struct raw1394_iso_status)
  58. #define RAW1394_IOC_ISO_RECV_START \
  59. _IOC (_IOC_WRITE, '#', 0x1c, sizeof(int) * 3)
  60. #define RAW1394_IOC_ISO_XMIT_START \
  61. _IOC (_IOC_WRITE, '#', 0x1d, sizeof(int) * 2)
  62. #define RAW1394_IOC_ISO_XMIT_RECV_STOP \
  63. _IO ('#', 0x1e)
  64. #define RAW1394_IOC_ISO_GET_STATUS \
  65. _IOR ('#', 0x1f, struct raw1394_iso_status)
  66. #define RAW1394_IOC_ISO_SHUTDOWN \
  67. _IO ('#', 0x20)
  68. #define RAW1394_IOC_ISO_QUEUE_ACTIVITY \
  69. _IO ('#', 0x21)
  70. #define RAW1394_IOC_ISO_RECV_LISTEN_CHANNEL \
  71. _IOW ('#', 0x22, unsigned char)
  72. #define RAW1394_IOC_ISO_RECV_UNLISTEN_CHANNEL \
  73. _IOW ('#', 0x23, unsigned char)
  74. #define RAW1394_IOC_ISO_RECV_SET_CHANNEL_MASK \
  75. _IOW ('#', 0x24, __u64)
  76. #define RAW1394_IOC_ISO_RECV_PACKETS \
  77. _IOW ('#', 0x25, struct raw1394_iso_packets)
  78. #define RAW1394_IOC_ISO_RECV_RELEASE_PACKETS \
  79. _IOW ('#', 0x26, unsigned int)
  80. #define RAW1394_IOC_ISO_XMIT_PACKETS \
  81. _IOW ('#', 0x27, struct raw1394_iso_packets)
  82. #define RAW1394_IOC_ISO_XMIT_SYNC \
  83. _IO ('#', 0x28)
  84. #define RAW1394_IOC_ISO_RECV_FLUSH \
  85. _IO ('#', 0x29)
  86. #endif /* __IEEE1394_IOCTL_H */