/* Copyright (c) 2012, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and * only version 2 as published by the Free Software Foundation. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. */ #include #include #include #include #include "board-msm7627a.h" #define SND(desc, num) { .name = #desc, .id = num } static struct snd_endpoint snd_endpoints_list[] = { SND(HANDSET, 0), SND(MONO_HEADSET, 2), SND(HEADSET, 3), SND(SPEAKER, 6), SND(TTY_HEADSET, 8), SND(TTY_VCO, 9), SND(TTY_HCO, 10), SND(BT, 12), SND(IN_S_SADC_OUT_HANDSET, 16), SND(IN_S_SADC_OUT_SPEAKER_PHONE, 25), SND(FM_DIGITAL_STEREO_HEADSET, 26), SND(FM_DIGITAL_SPEAKER_PHONE, 27), SND(FM_DIGITAL_BT_A2DP_HEADSET, 28), SND(STEREO_HEADSET_AND_SPEAKER, 31), SND(CURRENT, 0x7FFFFFFE), SND(FM_ANALOG_STEREO_HEADSET, 35), SND(FM_ANALOG_STEREO_HEADSET_CODEC, 36), }; #undef SND static struct msm_snd_endpoints msm_device_snd_endpoints = { .endpoints = snd_endpoints_list, .num = sizeof(snd_endpoints_list) / sizeof(struct snd_endpoint) }; struct platform_device msm_device_snd = { .name = "msm_snd", .id = -1, .dev = { .platform_data = &msm_device_snd_endpoints }, }; #define DEC0_FORMAT ((1<