Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
58936b29
K
Kernel
项目概览
openeuler
/
Kernel
1 年多 前同步成功
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
58936b29
编写于
12月 09, 2010
作者:
T
Takashi Iwai
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'fix/hda' into for-linus
上级
2ff38c9f
8a96b1e0
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
30 addition
and
32 deletion
+30
-32
sound/pci/hda/hda_eld.c
sound/pci/hda/hda_eld.c
+10
-14
sound/pci/hda/hda_intel.c
sound/pci/hda/hda_intel.c
+1
-0
sound/pci/hda/patch_conexant.c
sound/pci/hda/patch_conexant.c
+18
-17
sound/pci/hda/patch_hdmi.c
sound/pci/hda/patch_hdmi.c
+0
-1
sound/pci/hda/patch_realtek.c
sound/pci/hda/patch_realtek.c
+1
-0
未找到文件。
sound/pci/hda/hda_eld.c
浏览文件 @
58936b29
...
@@ -189,6 +189,9 @@ static void hdmi_update_short_audio_desc(struct cea_sad *a,
...
@@ -189,6 +189,9 @@ static void hdmi_update_short_audio_desc(struct cea_sad *a,
a
->
channels
=
GRAB_BITS
(
buf
,
0
,
0
,
3
);
a
->
channels
=
GRAB_BITS
(
buf
,
0
,
0
,
3
);
a
->
channels
++
;
a
->
channels
++
;
a
->
sample_bits
=
0
;
a
->
max_bitrate
=
0
;
a
->
format
=
GRAB_BITS
(
buf
,
0
,
3
,
4
);
a
->
format
=
GRAB_BITS
(
buf
,
0
,
3
,
4
);
switch
(
a
->
format
)
{
switch
(
a
->
format
)
{
case
AUDIO_CODING_TYPE_REF_STREAM_HEADER
:
case
AUDIO_CODING_TYPE_REF_STREAM_HEADER
:
...
@@ -198,7 +201,6 @@ static void hdmi_update_short_audio_desc(struct cea_sad *a,
...
@@ -198,7 +201,6 @@ static void hdmi_update_short_audio_desc(struct cea_sad *a,
case
AUDIO_CODING_TYPE_LPCM
:
case
AUDIO_CODING_TYPE_LPCM
:
val
=
GRAB_BITS
(
buf
,
2
,
0
,
3
);
val
=
GRAB_BITS
(
buf
,
2
,
0
,
3
);
a
->
sample_bits
=
0
;
for
(
i
=
0
;
i
<
3
;
i
++
)
for
(
i
=
0
;
i
<
3
;
i
++
)
if
(
val
&
(
1
<<
i
))
if
(
val
&
(
1
<<
i
))
a
->
sample_bits
|=
cea_sample_sizes
[
i
+
1
];
a
->
sample_bits
|=
cea_sample_sizes
[
i
+
1
];
...
@@ -598,24 +600,19 @@ void hdmi_eld_update_pcm_info(struct hdmi_eld *eld, struct hda_pcm_stream *pcm,
...
@@ -598,24 +600,19 @@ void hdmi_eld_update_pcm_info(struct hdmi_eld *eld, struct hda_pcm_stream *pcm,
{
{
int
i
;
int
i
;
pcm
->
rates
=
0
;
/* assume basic audio support (the basic audio flag is not in ELD;
pcm
->
formats
=
0
;
* however, all audio capable sinks are required to support basic
pcm
->
maxbps
=
0
;
* audio) */
pcm
->
channels_min
=
-
1
;
pcm
->
rates
=
SNDRV_PCM_RATE_32000
|
SNDRV_PCM_RATE_44100
|
SNDRV_PCM_RATE_48000
;
pcm
->
channels_max
=
0
;
pcm
->
formats
=
SNDRV_PCM_FMTBIT_S16_LE
;
pcm
->
maxbps
=
16
;
pcm
->
channels_max
=
2
;
for
(
i
=
0
;
i
<
eld
->
sad_count
;
i
++
)
{
for
(
i
=
0
;
i
<
eld
->
sad_count
;
i
++
)
{
struct
cea_sad
*
a
=
&
eld
->
sad
[
i
];
struct
cea_sad
*
a
=
&
eld
->
sad
[
i
];
pcm
->
rates
|=
a
->
rates
;
pcm
->
rates
|=
a
->
rates
;
if
(
a
->
channels
<
pcm
->
channels_min
)
pcm
->
channels_min
=
a
->
channels
;
if
(
a
->
channels
>
pcm
->
channels_max
)
if
(
a
->
channels
>
pcm
->
channels_max
)
pcm
->
channels_max
=
a
->
channels
;
pcm
->
channels_max
=
a
->
channels
;
if
(
a
->
format
==
AUDIO_CODING_TYPE_LPCM
)
{
if
(
a
->
format
==
AUDIO_CODING_TYPE_LPCM
)
{
if
(
a
->
sample_bits
&
AC_SUPPCM_BITS_16
)
{
pcm
->
formats
|=
SNDRV_PCM_FMTBIT_S16_LE
;
if
(
pcm
->
maxbps
<
16
)
pcm
->
maxbps
=
16
;
}
if
(
a
->
sample_bits
&
AC_SUPPCM_BITS_20
)
{
if
(
a
->
sample_bits
&
AC_SUPPCM_BITS_20
)
{
pcm
->
formats
|=
SNDRV_PCM_FMTBIT_S32_LE
;
pcm
->
formats
|=
SNDRV_PCM_FMTBIT_S32_LE
;
if
(
pcm
->
maxbps
<
20
)
if
(
pcm
->
maxbps
<
20
)
...
@@ -635,7 +632,6 @@ void hdmi_eld_update_pcm_info(struct hdmi_eld *eld, struct hda_pcm_stream *pcm,
...
@@ -635,7 +632,6 @@ void hdmi_eld_update_pcm_info(struct hdmi_eld *eld, struct hda_pcm_stream *pcm,
/* restrict the parameters by the values the codec provides */
/* restrict the parameters by the values the codec provides */
pcm
->
rates
&=
codec_pars
->
rates
;
pcm
->
rates
&=
codec_pars
->
rates
;
pcm
->
formats
&=
codec_pars
->
formats
;
pcm
->
formats
&=
codec_pars
->
formats
;
pcm
->
channels_min
=
max
(
pcm
->
channels_min
,
codec_pars
->
channels_min
);
pcm
->
channels_max
=
min
(
pcm
->
channels_max
,
codec_pars
->
channels_max
);
pcm
->
channels_max
=
min
(
pcm
->
channels_max
,
codec_pars
->
channels_max
);
pcm
->
maxbps
=
min
(
pcm
->
maxbps
,
codec_pars
->
maxbps
);
pcm
->
maxbps
=
min
(
pcm
->
maxbps
,
codec_pars
->
maxbps
);
}
}
sound/pci/hda/hda_intel.c
浏览文件 @
58936b29
...
@@ -2296,6 +2296,7 @@ static int azx_dev_free(struct snd_device *device)
...
@@ -2296,6 +2296,7 @@ static int azx_dev_free(struct snd_device *device)
*/
*/
static
struct
snd_pci_quirk
position_fix_list
[]
__devinitdata
=
{
static
struct
snd_pci_quirk
position_fix_list
[]
__devinitdata
=
{
SND_PCI_QUIRK
(
0x1025
,
0x009f
,
"Acer Aspire 5110"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1025
,
0x009f
,
"Acer Aspire 5110"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1025
,
0x026f
,
"Acer Aspire 5538"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01cc
,
"Dell D820"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01cc
,
"Dell D820"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01de
,
"Dell Precision 390"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01de
,
"Dell Precision 390"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01f6
,
"Dell Latitude 131L"
,
POS_FIX_LPIB
),
SND_PCI_QUIRK
(
0x1028
,
0x01f6
,
"Dell Latitude 131L"
,
POS_FIX_LPIB
),
...
...
sound/pci/hda/patch_conexant.c
浏览文件 @
58936b29
...
@@ -2116,8 +2116,8 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
...
@@ -2116,8 +2116,8 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
struct
conexant_spec
*
spec
=
codec
->
spec
;
struct
conexant_spec
*
spec
=
codec
->
spec
;
unsigned
int
pinctl
;
unsigned
int
pinctl
;
snd_printdd
(
"CXT5066: update speaker, hp_present=%d
\n
"
,
snd_printdd
(
"CXT5066: update speaker, hp_present=%d
, cur_eapd=%d
\n
"
,
spec
->
hp_present
);
spec
->
hp_present
,
spec
->
cur_eapd
);
/* Port A (HP) */
/* Port A (HP) */
pinctl
=
((
spec
->
hp_present
&
1
)
&&
spec
->
cur_eapd
)
?
PIN_HP
:
0
;
pinctl
=
((
spec
->
hp_present
&
1
)
&&
spec
->
cur_eapd
)
?
PIN_HP
:
0
;
...
@@ -2125,11 +2125,20 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
...
@@ -2125,11 +2125,20 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
pinctl
);
pinctl
);
/* Port D (HP/LO) */
/* Port D (HP/LO) */
pinctl
=
((
spec
->
hp_present
&
2
)
&&
spec
->
cur_eapd
)
if
(
spec
->
dell_automute
)
{
?
spec
->
port_d_mode
:
0
;
/* DELL AIO Port Rule: PortA> PortD> IntSpk */
/* Mute if Port A is connected on Thinkpad */
pinctl
=
(
!
(
spec
->
hp_present
&
1
)
&&
spec
->
cur_eapd
)
if
(
spec
->
thinkpad
&&
(
spec
->
hp_present
&
1
))
?
PIN_OUT
:
0
;
pinctl
=
0
;
}
else
if
(
spec
->
thinkpad
)
{
if
(
spec
->
cur_eapd
)
pinctl
=
spec
->
port_d_mode
;
/* Mute dock line-out if Port A (laptop HP) is present */
if
(
spec
->
hp_present
&
1
)
pinctl
=
0
;
}
else
{
pinctl
=
((
spec
->
hp_present
&
2
)
&&
spec
->
cur_eapd
)
?
spec
->
port_d_mode
:
0
;
}
snd_hda_codec_write
(
codec
,
0x1c
,
0
,
AC_VERB_SET_PIN_WIDGET_CONTROL
,
snd_hda_codec_write
(
codec
,
0x1c
,
0
,
AC_VERB_SET_PIN_WIDGET_CONTROL
,
pinctl
);
pinctl
);
...
@@ -2137,14 +2146,6 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
...
@@ -2137,14 +2146,6 @@ static void cxt5066_update_speaker(struct hda_codec *codec)
pinctl
=
(
!
spec
->
hp_present
&&
spec
->
cur_eapd
)
?
PIN_OUT
:
0
;
pinctl
=
(
!
spec
->
hp_present
&&
spec
->
cur_eapd
)
?
PIN_OUT
:
0
;
snd_hda_codec_write
(
codec
,
0x1f
,
0
,
AC_VERB_SET_PIN_WIDGET_CONTROL
,
snd_hda_codec_write
(
codec
,
0x1f
,
0
,
AC_VERB_SET_PIN_WIDGET_CONTROL
,
pinctl
);
pinctl
);
if
(
spec
->
dell_automute
)
{
/* DELL AIO Port Rule: PortA > PortD > IntSpk */
pinctl
=
(
!
(
spec
->
hp_present
&
1
)
&&
spec
->
cur_eapd
)
?
PIN_OUT
:
0
;
snd_hda_codec_write
(
codec
,
0x1c
,
0
,
AC_VERB_SET_PIN_WIDGET_CONTROL
,
pinctl
);
}
}
}
/* turn on/off EAPD (+ mute HP) as a master switch */
/* turn on/off EAPD (+ mute HP) as a master switch */
...
@@ -3095,8 +3096,7 @@ static const char *cxt5066_models[CXT5066_MODELS] = {
...
@@ -3095,8 +3096,7 @@ static const char *cxt5066_models[CXT5066_MODELS] = {
static
struct
snd_pci_quirk
cxt5066_cfg_tbl
[]
=
{
static
struct
snd_pci_quirk
cxt5066_cfg_tbl
[]
=
{
SND_PCI_QUIRK_MASK
(
0x1025
,
0xff00
,
0x0400
,
"Acer"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK_MASK
(
0x1025
,
0xff00
,
0x0400
,
"Acer"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x1028
,
0x02d8
,
"Dell Vostro"
,
CXT5066_DELL_VOSTRO
),
SND_PCI_QUIRK
(
0x1028
,
0x02d8
,
"Dell Vostro"
,
CXT5066_DELL_VOSTRO
),
SND_PCI_QUIRK
(
0x1028
,
0x02f5
,
"Dell"
,
SND_PCI_QUIRK
(
0x1028
,
0x02f5
,
"Dell Vostro 320"
,
CXT5066_IDEAPAD
),
CXT5066_DELL_LAPTOP
),
SND_PCI_QUIRK
(
0x1028
,
0x0402
,
"Dell Vostro"
,
CXT5066_DELL_VOSTRO
),
SND_PCI_QUIRK
(
0x1028
,
0x0402
,
"Dell Vostro"
,
CXT5066_DELL_VOSTRO
),
SND_PCI_QUIRK
(
0x1028
,
0x0408
,
"Dell Inspiron One 19T"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x1028
,
0x0408
,
"Dell Inspiron One 19T"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x103c
,
0x360b
,
"HP G60"
,
CXT5066_HP_LAPTOP
),
SND_PCI_QUIRK
(
0x103c
,
0x360b
,
"HP G60"
,
CXT5066_HP_LAPTOP
),
...
@@ -3109,6 +3109,7 @@ static struct snd_pci_quirk cxt5066_cfg_tbl[] = {
...
@@ -3109,6 +3109,7 @@ static struct snd_pci_quirk cxt5066_cfg_tbl[] = {
SND_PCI_QUIRK
(
0x152d
,
0x0833
,
"OLPC XO-1.5"
,
CXT5066_OLPC_XO_1_5
),
SND_PCI_QUIRK
(
0x152d
,
0x0833
,
"OLPC XO-1.5"
,
CXT5066_OLPC_XO_1_5
),
SND_PCI_QUIRK
(
0x17aa
,
0x20f2
,
"Lenovo T400s"
,
CXT5066_THINKPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x20f2
,
"Lenovo T400s"
,
CXT5066_THINKPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b2
,
"Thinkpad X100e"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b2
,
"Thinkpad X100e"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21c5
,
"Thinkpad Edge 13"
,
CXT5066_THINKPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b3
,
"Thinkpad Edge 13 (197)"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b3
,
"Thinkpad Edge 13 (197)"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b4
,
"Thinkpad Edge"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21b4
,
"Thinkpad Edge"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21c8
,
"Thinkpad Edge 11"
,
CXT5066_IDEAPAD
),
SND_PCI_QUIRK
(
0x17aa
,
0x21c8
,
"Thinkpad Edge 11"
,
CXT5066_IDEAPAD
),
...
...
sound/pci/hda/patch_hdmi.c
浏览文件 @
58936b29
...
@@ -834,7 +834,6 @@ static int hdmi_pcm_open(struct hda_pcm_stream *hinfo,
...
@@ -834,7 +834,6 @@ static int hdmi_pcm_open(struct hda_pcm_stream *hinfo,
return
-
ENODEV
;
return
-
ENODEV
;
}
else
{
}
else
{
/* fallback to the codec default */
/* fallback to the codec default */
hinfo
->
channels_min
=
codec_pars
->
channels_min
;
hinfo
->
channels_max
=
codec_pars
->
channels_max
;
hinfo
->
channels_max
=
codec_pars
->
channels_max
;
hinfo
->
rates
=
codec_pars
->
rates
;
hinfo
->
rates
=
codec_pars
->
rates
;
hinfo
->
formats
=
codec_pars
->
formats
;
hinfo
->
formats
=
codec_pars
->
formats
;
...
...
sound/pci/hda/patch_realtek.c
浏览文件 @
58936b29
...
@@ -4595,6 +4595,7 @@ static struct snd_pci_quirk alc880_cfg_tbl[] = {
...
@@ -4595,6 +4595,7 @@ static struct snd_pci_quirk alc880_cfg_tbl[] = {
SND_PCI_QUIRK(0x1734, 0x10b0, "Fujitsu", ALC880_FUJITSU),
SND_PCI_QUIRK(0x1734, 0x10b0, "Fujitsu", ALC880_FUJITSU),
SND_PCI_QUIRK(0x1854, 0x0018, "LG LW20", ALC880_LG_LW),
SND_PCI_QUIRK(0x1854, 0x0018, "LG LW20", ALC880_LG_LW),
SND_PCI_QUIRK(0x1854, 0x003b, "LG", ALC880_LG),
SND_PCI_QUIRK(0x1854, 0x003b, "LG", ALC880_LG),
SND_PCI_QUIRK(0x1854, 0x005f, "LG P1 Express", ALC880_LG),
SND_PCI_QUIRK(0x1854, 0x0068, "LG w1", ALC880_LG),
SND_PCI_QUIRK(0x1854, 0x0068, "LG w1", ALC880_LG),
SND_PCI_QUIRK(0x1854, 0x0077, "LG LW25", ALC880_LG_LW),
SND_PCI_QUIRK(0x1854, 0x0077, "LG LW25", ALC880_LG_LW),
SND_PCI_QUIRK(0x19db, 0x4188, "TCL S700", ALC880_TCL_S700),
SND_PCI_QUIRK(0x19db, 0x4188, "TCL S700", ALC880_TCL_S700),
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录