122851890Sopenharmony_ci/****************************************************************************
222851890Sopenharmony_ci ****************************************************************************
322851890Sopenharmony_ci ***
422851890Sopenharmony_ci ***   This header was automatically generated from a Linux kernel header
522851890Sopenharmony_ci ***   of the same name, to make information necessary for userspace to
622851890Sopenharmony_ci ***   call into the kernel available to libc.  It contains only constants,
722851890Sopenharmony_ci ***   structures, and macros generated from the original header, and thus,
822851890Sopenharmony_ci ***   contains no copyrightable information.
922851890Sopenharmony_ci ***
1022851890Sopenharmony_ci ***   To edit the content of this header, modify the corresponding
1122851890Sopenharmony_ci ***   source file (e.g. under external/kernel-headers/original/) then
1222851890Sopenharmony_ci ***   run bionic/libc/kernel/tools/update_all.py
1322851890Sopenharmony_ci ***
1422851890Sopenharmony_ci ***   Any manual change here will be lost the next time this script will
1522851890Sopenharmony_ci ***   be run. You've been warned!
1622851890Sopenharmony_ci ***
1722851890Sopenharmony_ci ****************************************************************************
1822851890Sopenharmony_ci ****************************************************************************/
1922851890Sopenharmony_ci#ifndef __UAPI_SOUND_TLV_H
2022851890Sopenharmony_ci#define __UAPI_SOUND_TLV_H
2122851890Sopenharmony_ci#define SNDRV_CTL_TLVT_CONTAINER 0
2222851890Sopenharmony_ci#define SNDRV_CTL_TLVT_DB_SCALE 1
2322851890Sopenharmony_ci#define SNDRV_CTL_TLVT_DB_LINEAR 2
2422851890Sopenharmony_ci#define SNDRV_CTL_TLVT_DB_RANGE 3
2522851890Sopenharmony_ci#define SNDRV_CTL_TLVT_DB_MINMAX 4
2622851890Sopenharmony_ci#define SNDRV_CTL_TLVT_DB_MINMAX_MUTE 5
2722851890Sopenharmony_ci#define SNDRV_CTL_TLVT_CHMAP_FIXED 0x101
2822851890Sopenharmony_ci#define SNDRV_CTL_TLVT_CHMAP_VAR 0x102
2922851890Sopenharmony_ci#define SNDRV_CTL_TLVT_CHMAP_PAIRED 0x103
3022851890Sopenharmony_ci#define SNDRV_CTL_TLVD_ITEM(type,...) (type), SNDRV_CTL_TLVD_LENGTH(__VA_ARGS__), __VA_ARGS__
3122851890Sopenharmony_ci#define SNDRV_CTL_TLVD_LENGTH(...) ((unsigned int) sizeof((const unsigned int[]) { __VA_ARGS__ }))
3222851890Sopenharmony_ci#define SNDRV_CTL_TLVO_TYPE 0
3322851890Sopenharmony_ci#define SNDRV_CTL_TLVO_LEN 1
3422851890Sopenharmony_ci#define SNDRV_CTL_TLVD_CONTAINER_ITEM(...) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_CONTAINER, __VA_ARGS__)
3522851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_CONTAINER(name,...) unsigned int name[] = { SNDRV_CTL_TLVD_CONTAINER_ITEM(__VA_ARGS__) }
3622851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_SCALE_MASK 0xffff
3722851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_SCALE_MUTE 0x10000
3822851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_SCALE_ITEM(min,step,mute) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_DB_SCALE, (min), ((step) & SNDRV_CTL_TLVD_DB_SCALE_MASK) | ((mute) ? SNDRV_CTL_TLVD_DB_SCALE_MUTE : 0))
3922851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_DB_SCALE(name,min,step,mute) unsigned int name[] = { SNDRV_CTL_TLVD_DB_SCALE_ITEM(min, step, mute) }
4022851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_SCALE_MIN 2
4122851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_SCALE_MUTE_AND_STEP 3
4222851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_MINMAX_ITEM(min_dB,max_dB) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_DB_MINMAX, (min_dB), (max_dB))
4322851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_MINMAX_MUTE_ITEM(min_dB,max_dB) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_DB_MINMAX_MUTE, (min_dB), (max_dB))
4422851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_DB_MINMAX(name,min_dB,max_dB) unsigned int name[] = { SNDRV_CTL_TLVD_DB_MINMAX_ITEM(min_dB, max_dB) }
4522851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_DB_MINMAX_MUTE(name,min_dB,max_dB) unsigned int name[] = { SNDRV_CTL_TLVD_DB_MINMAX_MUTE_ITEM(min_dB, max_dB) }
4622851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_MINMAX_MIN 2
4722851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_MINMAX_MAX 3
4822851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_LINEAR_ITEM(min_dB,max_dB) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_DB_LINEAR, (min_dB), (max_dB))
4922851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_DB_LINEAR(name,min_dB,max_dB) unsigned int name[] = { SNDRV_CTL_TLVD_DB_LINEAR_ITEM(min_dB, max_dB) }
5022851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_LINEAR_MIN 2
5122851890Sopenharmony_ci#define SNDRV_CTL_TLVO_DB_LINEAR_MAX 3
5222851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_RANGE_ITEM(...) SNDRV_CTL_TLVD_ITEM(SNDRV_CTL_TLVT_DB_RANGE, __VA_ARGS__)
5322851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DECLARE_DB_RANGE(name,...) unsigned int name[] = { SNDRV_CTL_TLVD_DB_RANGE_ITEM(__VA_ARGS__) }
5422851890Sopenharmony_ci#define SNDRV_CTL_TLVD_DB_GAIN_MUTE - 9999999
5522851890Sopenharmony_ci#endif
56