Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
kernel_linux
提交
e488fca7
K
kernel_linux
项目概览
OpenHarmony
/
kernel_linux
上一次同步 3 年多
通知
13
Star
8
Fork
2
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
kernel_linux
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
e488fca7
编写于
7月 03, 2009
作者:
T
Takashi Iwai
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'fix/hda' into topic/hda
上级
8ab9e0af
aa202455
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
31 addition
and
20 deletion
+31
-20
sound/pci/hda/patch_analog.c
sound/pci/hda/patch_analog.c
+26
-1
sound/pci/hda/patch_realtek.c
sound/pci/hda/patch_realtek.c
+5
-19
未找到文件。
sound/pci/hda/patch_analog.c
浏览文件 @
e488fca7
...
...
@@ -3746,9 +3746,30 @@ static struct snd_kcontrol_new ad1884a_laptop_mixers[] = {
{
}
/* end */
};
static
int
ad1884a_mobile_master_sw_put
(
struct
snd_kcontrol
*
kcontrol
,
struct
snd_ctl_elem_value
*
ucontrol
)
{
struct
hda_codec
*
codec
=
snd_kcontrol_chip
(
kcontrol
);
int
ret
=
snd_hda_mixer_amp_switch_put
(
kcontrol
,
ucontrol
);
int
mute
=
(
!
ucontrol
->
value
.
integer
.
value
[
0
]
&&
!
ucontrol
->
value
.
integer
.
value
[
1
]);
/* toggle GPIO1 according to the mute state */
snd_hda_codec_write
(
codec
,
0x01
,
0
,
AC_VERB_SET_GPIO_DATA
,
mute
?
0x02
:
0x0
);
return
ret
;
}
static
struct
snd_kcontrol_new
ad1884a_mobile_mixers
[]
=
{
HDA_CODEC_VOLUME
(
"Master Playback Volume"
,
0x21
,
0x0
,
HDA_OUTPUT
),
HDA_CODEC_MUTE
(
"Master Playback Switch"
,
0x21
,
0x0
,
HDA_OUTPUT
),
/*HDA_CODEC_MUTE("Master Playback Switch", 0x21, 0x0, HDA_OUTPUT),*/
{
.
iface
=
SNDRV_CTL_ELEM_IFACE_MIXER
,
.
name
=
"Master Playback Switch"
,
.
info
=
snd_hda_mixer_amp_switch_info
,
.
get
=
snd_hda_mixer_amp_switch_get
,
.
put
=
ad1884a_mobile_master_sw_put
,
.
private_value
=
HDA_COMPOSE_AMP_VAL
(
0x21
,
3
,
0
,
HDA_OUTPUT
),
},
HDA_CODEC_VOLUME
(
"PCM Playback Volume"
,
0x20
,
0x5
,
HDA_INPUT
),
HDA_CODEC_MUTE
(
"PCM Playback Switch"
,
0x20
,
0x5
,
HDA_INPUT
),
HDA_CODEC_VOLUME
(
"Mic Capture Volume"
,
0x14
,
0x0
,
HDA_INPUT
),
...
...
@@ -3869,6 +3890,10 @@ static struct hda_verb ad1884a_mobile_verbs[] = {
/* unsolicited event for pin-sense */
{
0x11
,
AC_VERB_SET_UNSOLICITED_ENABLE
,
AC_USRSP_EN
|
AD1884A_HP_EVENT
},
{
0x14
,
AC_VERB_SET_UNSOLICITED_ENABLE
,
AC_USRSP_EN
|
AD1884A_MIC_EVENT
},
/* allow to touch GPIO1 (for mute control) */
{
0x01
,
AC_VERB_SET_GPIO_MASK
,
0x02
},
{
0x01
,
AC_VERB_SET_GPIO_DIRECTION
,
0x02
},
{
0x01
,
AC_VERB_SET_GPIO_DATA
,
0x02
},
/* first muted */
{
}
/* end */
};
...
...
sound/pci/hda/patch_realtek.c
浏览文件 @
e488fca7
...
...
@@ -12427,20 +12427,11 @@ static struct snd_kcontrol_new alc269_lifebook_mixer[] = {
{ }
};
/* bind volumes of both NID 0x0c and 0x0d */
static struct hda_bind_ctls alc269_epc_bind_vol = {
.ops = &snd_hda_bind_vol,
.values = {
HDA_COMPOSE_AMP_VAL(0x02, 3, 0, HDA_OUTPUT),
HDA_COMPOSE_AMP_VAL(0x03, 3, 0, HDA_OUTPUT),
0
},
};
static struct snd_kcontrol_new alc269_eeepc_mixer[] = {
HDA_CODEC_MUTE("iSpeaker Playback Switch", 0x14, 0x0, HDA_OUTPUT),
HDA_BIND_VOL("LineOut Playback Volume", &alc269_epc_bind_vol),
HDA_CODEC_MUTE("LineOut Playback Switch", 0x15, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE("Speaker Playback Volume", 0x02, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE("Headphone Playback Volume", 0x03, 0x0, HDA_OUTPUT),
{ } /* end */
};
...
...
@@ -12453,12 +12444,7 @@ static struct snd_kcontrol_new alc269_epc_capture_mixer[] = {
};
/* FSC amilo */
static struct snd_kcontrol_new alc269_fujitsu_mixer[] = {
HDA_CODEC_MUTE("Speaker Playback Switch", 0x14, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE("Headphone Playback Switch", 0x15, 0x0, HDA_OUTPUT),
HDA_BIND_VOL("PCM Playback Volume", &alc269_epc_bind_vol),
{ } /* end */
};
#define alc269_fujitsu_mixer alc269_eeepc_mixer
static struct hda_verb alc269_quanta_fl1_verbs[] = {
{0x15, AC_VERB_SET_CONNECT_SEL, 0x01},
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录