blob: 67c010baa26ea79fa1f223c8d62a664cc03450ac [file] [log] [blame]
Christopher Ferris38062f92014-07-09 15:33:25 -07001/****************************************************************************
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_SOUND_FIREWIRE_H_INCLUDED
20#define _UAPI_SOUND_FIREWIRE_H_INCLUDED
21#include <linux/ioctl.h>
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070022#include <linux/types.h>
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070023#define SNDRV_FIREWIRE_EVENT_LOCK_STATUS 0x000010cc
Christopher Ferris38062f92014-07-09 15:33:25 -070024#define SNDRV_FIREWIRE_EVENT_DICE_NOTIFICATION 0xd1ce004e
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070025#define SNDRV_FIREWIRE_EVENT_EFW_RESPONSE 0x4e617475
Christopher Ferris05d08e92016-02-04 13:16:38 -080026#define SNDRV_FIREWIRE_EVENT_DIGI00X_MESSAGE 0x746e736c
Christopher Ferris525ce912017-07-26 13:12:53 -070027#define SNDRV_FIREWIRE_EVENT_MOTU_NOTIFICATION 0x64776479
Christopher Ferrisd842e432019-03-07 10:21:59 -080028#define SNDRV_FIREWIRE_EVENT_TASCAM_CONTROL 0x7473636d
Christopher Ferris05d08e92016-02-04 13:16:38 -080029struct snd_firewire_event_common {
Tao Baod7db5942015-01-28 10:07:51 -080030 unsigned int type;
Christopher Ferris38062f92014-07-09 15:33:25 -070031};
Christopher Ferris38062f92014-07-09 15:33:25 -070032struct snd_firewire_event_lock_status {
Christopher Ferris05d08e92016-02-04 13:16:38 -080033 unsigned int type;
Tao Baod7db5942015-01-28 10:07:51 -080034 unsigned int status;
Christopher Ferris38062f92014-07-09 15:33:25 -070035};
Christopher Ferris38062f92014-07-09 15:33:25 -070036struct snd_firewire_event_dice_notification {
Christopher Ferris05d08e92016-02-04 13:16:38 -080037 unsigned int type;
Tao Baod7db5942015-01-28 10:07:51 -080038 unsigned int notification;
Christopher Ferris38062f92014-07-09 15:33:25 -070039};
Tao Baod7db5942015-01-28 10:07:51 -080040#define SND_EFW_TRANSACTION_USER_SEQNUM_MAX ((__u32) ((__u16) ~0) - 1)
Christopher Ferris05d08e92016-02-04 13:16:38 -080041struct snd_efw_transaction {
Tao Baod7db5942015-01-28 10:07:51 -080042 __be32 length;
43 __be32 version;
44 __be32 seqnum;
Christopher Ferris05d08e92016-02-04 13:16:38 -080045 __be32 category;
Tao Baod7db5942015-01-28 10:07:51 -080046 __be32 command;
47 __be32 status;
48 __be32 params[0];
Christopher Ferris05d08e92016-02-04 13:16:38 -080049};
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070050struct snd_firewire_event_efw_response {
Tao Baod7db5942015-01-28 10:07:51 -080051 unsigned int type;
52 __be32 response[0];
Christopher Ferris05d08e92016-02-04 13:16:38 -080053};
54struct snd_firewire_event_digi00x_message {
55 unsigned int type;
56 __u32 message;
Christopher Ferris05d08e92016-02-04 13:16:38 -080057};
Christopher Ferris525ce912017-07-26 13:12:53 -070058struct snd_firewire_event_motu_notification {
59 unsigned int type;
60 __u32 message;
61};
Christopher Ferrisd842e432019-03-07 10:21:59 -080062struct snd_firewire_tascam_change {
63 unsigned int index;
64 __be32 before;
65 __be32 after;
66};
67struct snd_firewire_event_tascam_control {
68 unsigned int type;
69 struct snd_firewire_tascam_change changes[0];
70};
Christopher Ferris38062f92014-07-09 15:33:25 -070071union snd_firewire_event {
Tao Baod7db5942015-01-28 10:07:51 -080072 struct snd_firewire_event_common common;
73 struct snd_firewire_event_lock_status lock_status;
Christopher Ferris05d08e92016-02-04 13:16:38 -080074 struct snd_firewire_event_dice_notification dice_notification;
Tao Baod7db5942015-01-28 10:07:51 -080075 struct snd_firewire_event_efw_response efw_response;
Christopher Ferris05d08e92016-02-04 13:16:38 -080076 struct snd_firewire_event_digi00x_message digi00x_message;
Christopher Ferrisd842e432019-03-07 10:21:59 -080077 struct snd_firewire_event_tascam_control tascam_control;
Christopher Ferris525ce912017-07-26 13:12:53 -070078 struct snd_firewire_event_motu_notification motu_notification;
Christopher Ferris38062f92014-07-09 15:33:25 -070079};
80#define SNDRV_FIREWIRE_IOCTL_GET_INFO _IOR('H', 0xf8, struct snd_firewire_get_info)
81#define SNDRV_FIREWIRE_IOCTL_LOCK _IO('H', 0xf9)
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070082#define SNDRV_FIREWIRE_IOCTL_UNLOCK _IO('H', 0xfa)
Christopher Ferrisd842e432019-03-07 10:21:59 -080083#define SNDRV_FIREWIRE_IOCTL_TASCAM_STATE _IOR('H', 0xfb, struct snd_firewire_tascam_state)
Christopher Ferris38062f92014-07-09 15:33:25 -070084#define SNDRV_FIREWIRE_TYPE_DICE 1
Christopher Ferrisba8d4f42014-09-03 19:56:49 -070085#define SNDRV_FIREWIRE_TYPE_FIREWORKS 2
86#define SNDRV_FIREWIRE_TYPE_BEBOB 3
Christopher Ferris05d08e92016-02-04 13:16:38 -080087#define SNDRV_FIREWIRE_TYPE_OXFW 4
88#define SNDRV_FIREWIRE_TYPE_DIGI00X 5
Christopher Ferris05d08e92016-02-04 13:16:38 -080089#define SNDRV_FIREWIRE_TYPE_TASCAM 6
Christopher Ferris525ce912017-07-26 13:12:53 -070090#define SNDRV_FIREWIRE_TYPE_MOTU 7
91#define SNDRV_FIREWIRE_TYPE_FIREFACE 8
Christopher Ferris38062f92014-07-09 15:33:25 -070092struct snd_firewire_get_info {
Tao Baod7db5942015-01-28 10:07:51 -080093 unsigned int type;
94 unsigned int card;
Christopher Ferris05d08e92016-02-04 13:16:38 -080095 unsigned char guid[8];
Tao Baod7db5942015-01-28 10:07:51 -080096 char device_name[16];
Christopher Ferris38062f92014-07-09 15:33:25 -070097};
Christopher Ferrisd842e432019-03-07 10:21:59 -080098#define SNDRV_FIREWIRE_TASCAM_STATE_COUNT 64
99struct snd_firewire_tascam_state {
100 __be32 data[SNDRV_FIREWIRE_TASCAM_STATE_COUNT];
101};
Christopher Ferris38062f92014-07-09 15:33:25 -0700102#endif