1 /* 2 * Copyright (c) 2013-2015, The Linux Foundation. All rights reserved. 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License version 2 and 6 * only version 2 as published by the Free Software Foundation. 7 8 * This program is distributed in the hope that it will be useful, 9 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * GNU General Public License for more details. 12 */ 13 14 #ifndef _DEV_DEP_H 15 #define _DEV_DEP_H 16 17 struct dolby_param_data { 18 int32_t version; 19 int32_t device_id; 20 int32_t be_id; 21 int32_t param_id; 22 int32_t length; 23 int32_t __user *data; 24 }; 25 26 struct dolby_param_license { 27 int32_t dmid; 28 int32_t license_key; 29 }; 30 31 #define SNDRV_DEVDEP_DAP_IOCTL_SET_PARAM\ 32 _IOWR('U', 0x10, struct dolby_param_data) 33 #define SNDRV_DEVDEP_DAP_IOCTL_GET_PARAM\ 34 _IOR('U', 0x11, struct dolby_param_data) 35 #define SNDRV_DEVDEP_DAP_IOCTL_DAP_COMMAND\ 36 _IOWR('U', 0x13, struct dolby_param_data) 37 #define SNDRV_DEVDEP_DAP_IOCTL_DAP_LICENSE\ 38 _IOWR('U', 0x14, struct dolby_param_license) 39 #define SNDRV_DEVDEP_DAP_IOCTL_GET_VISUALIZER\ 40 _IOR('U', 0x15, struct dolby_param_data) 41 42 #define DTS_EAGLE_MODULE 0x00005000 43 #define DTS_EAGLE_MODULE_ENABLE 0x00005001 44 #define EAGLE_DRIVER_ID 0xF2 45 #define DTS_EAGLE_IOCTL_GET_CACHE_SIZE _IOR(EAGLE_DRIVER_ID, 0, int) 46 #define DTS_EAGLE_IOCTL_SET_CACHE_SIZE _IOW(EAGLE_DRIVER_ID, 1, int) 47 #define DTS_EAGLE_IOCTL_GET_PARAM _IOR(EAGLE_DRIVER_ID, 2, void*) 48 #define DTS_EAGLE_IOCTL_SET_PARAM _IOW(EAGLE_DRIVER_ID, 3, void*) 49 #define DTS_EAGLE_IOCTL_SET_CACHE_BLOCK _IOW(EAGLE_DRIVER_ID, 4, void*) 50 #define DTS_EAGLE_IOCTL_SET_ACTIVE_DEVICE _IOW(EAGLE_DRIVER_ID, 5, void*) 51 #define DTS_EAGLE_IOCTL_GET_LICENSE _IOR(EAGLE_DRIVER_ID, 6, void*) 52 #define DTS_EAGLE_IOCTL_SET_LICENSE _IOW(EAGLE_DRIVER_ID, 7, void*) 53 #define DTS_EAGLE_IOCTL_SEND_LICENSE _IOW(EAGLE_DRIVER_ID, 8, int) 54 #define DTS_EAGLE_IOCTL_SET_VOLUME_COMMANDS _IOW(EAGLE_DRIVER_ID, 9, void*) 55 #define DTS_EAGLE_FLAG_IOCTL_PRE (1<<30) 56 #define DTS_EAGLE_FLAG_IOCTL_JUSTSETCACHE (1<<31) 57 #define DTS_EAGLE_FLAG_IOCTL_GETFROMCORE DTS_EAGLE_FLAG_IOCTL_JUSTSETCACHE 58 #define DTS_EAGLE_FLAG_IOCTL_MASK (~(DTS_EAGLE_FLAG_IOCTL_PRE | \ 59 DTS_EAGLE_FLAG_IOCTL_JUSTSETCACHE)) 60 #define DTS_EAGLE_FLAG_ALSA_GET (1<<31) 61 62 struct dts_eagle_param_desc { 63 uint32_t id; 64 uint32_t size; 65 int32_t offset; 66 uint32_t device; 67 } __packed; 68 69 #endif 70