Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
c33ef2c9
Commit
c33ef2c9
authored
Nov 20, 2013
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/fix/arizona' into asoc-linus
parents
8b880f48
3e68ce1b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
46 additions
and
1 deletion
+46
-1
sound/soc/codecs/arizona.c
sound/soc/codecs/arizona.c
+4
-0
sound/soc/codecs/wm5110.c
sound/soc/codecs/wm5110.c
+42
-1
No files found.
sound/soc/codecs/arizona.c
View file @
c33ef2c9
...
@@ -1528,6 +1528,8 @@ static void arizona_enable_fll(struct arizona_fll *fll,
...
@@ -1528,6 +1528,8 @@ static void arizona_enable_fll(struct arizona_fll *fll,
/* Clear any pending completions */
/* Clear any pending completions */
try_wait_for_completion
(
&
fll
->
ok
);
try_wait_for_completion
(
&
fll
->
ok
);
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
1
,
ARIZONA_FLL1_FREERUN
,
0
);
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
1
,
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
1
,
ARIZONA_FLL1_ENA
,
ARIZONA_FLL1_ENA
);
ARIZONA_FLL1_ENA
,
ARIZONA_FLL1_ENA
);
if
(
use_sync
)
if
(
use_sync
)
...
@@ -1546,6 +1548,8 @@ static void arizona_disable_fll(struct arizona_fll *fll)
...
@@ -1546,6 +1548,8 @@ static void arizona_disable_fll(struct arizona_fll *fll)
struct
arizona
*
arizona
=
fll
->
arizona
;
struct
arizona
*
arizona
=
fll
->
arizona
;
bool
change
;
bool
change
;
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
1
,
ARIZONA_FLL1_FREERUN
,
ARIZONA_FLL1_FREERUN
);
regmap_update_bits_check
(
arizona
->
regmap
,
fll
->
base
+
1
,
regmap_update_bits_check
(
arizona
->
regmap
,
fll
->
base
+
1
,
ARIZONA_FLL1_ENA
,
0
,
&
change
);
ARIZONA_FLL1_ENA
,
0
,
&
change
);
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
0x11
,
regmap_update_bits
(
arizona
->
regmap
,
fll
->
base
+
0x11
,
...
...
sound/soc/codecs/wm5110.c
View file @
c33ef2c9
...
@@ -37,6 +37,47 @@ struct wm5110_priv {
...
@@ -37,6 +37,47 @@ struct wm5110_priv {
struct
arizona_fll
fll
[
2
];
struct
arizona_fll
fll
[
2
];
};
};
static
const
struct
reg_default
wm5110_sysclk_revd_patch
[]
=
{
{
0x3093
,
0x1001
},
{
0x30E3
,
0x1301
},
{
0x3133
,
0x1201
},
{
0x3183
,
0x1501
},
{
0x31D3
,
0x1401
},
};
static
int
wm5110_sysclk_ev
(
struct
snd_soc_dapm_widget
*
w
,
struct
snd_kcontrol
*
kcontrol
,
int
event
)
{
struct
snd_soc_codec
*
codec
=
w
->
codec
;
struct
arizona
*
arizona
=
dev_get_drvdata
(
codec
->
dev
->
parent
);
struct
regmap
*
regmap
=
codec
->
control_data
;
const
struct
reg_default
*
patch
=
NULL
;
int
i
,
patch_size
;
switch
(
arizona
->
rev
)
{
case
3
:
patch
=
wm5110_sysclk_revd_patch
;
patch_size
=
ARRAY_SIZE
(
wm5110_sysclk_revd_patch
);
break
;
default:
return
0
;
}
switch
(
event
)
{
case
SND_SOC_DAPM_POST_PMU
:
if
(
patch
)
for
(
i
=
0
;
i
<
patch_size
;
i
++
)
regmap_write
(
regmap
,
patch
[
i
].
reg
,
patch
[
i
].
def
);
break
;
default:
break
;
}
return
0
;
}
static
DECLARE_TLV_DB_SCALE
(
ana_tlv
,
0
,
100
,
0
);
static
DECLARE_TLV_DB_SCALE
(
ana_tlv
,
0
,
100
,
0
);
static
DECLARE_TLV_DB_SCALE
(
eq_tlv
,
-
1200
,
100
,
0
);
static
DECLARE_TLV_DB_SCALE
(
eq_tlv
,
-
1200
,
100
,
0
);
static
DECLARE_TLV_DB_SCALE
(
digital_tlv
,
-
6400
,
50
,
0
);
static
DECLARE_TLV_DB_SCALE
(
digital_tlv
,
-
6400
,
50
,
0
);
...
@@ -400,7 +441,7 @@ static const struct snd_kcontrol_new wm5110_aec_loopback_mux =
...
@@ -400,7 +441,7 @@ static const struct snd_kcontrol_new wm5110_aec_loopback_mux =
static
const
struct
snd_soc_dapm_widget
wm5110_dapm_widgets
[]
=
{
static
const
struct
snd_soc_dapm_widget
wm5110_dapm_widgets
[]
=
{
SND_SOC_DAPM_SUPPLY
(
"SYSCLK"
,
ARIZONA_SYSTEM_CLOCK_1
,
ARIZONA_SYSCLK_ENA_SHIFT
,
SND_SOC_DAPM_SUPPLY
(
"SYSCLK"
,
ARIZONA_SYSTEM_CLOCK_1
,
ARIZONA_SYSCLK_ENA_SHIFT
,
0
,
NULL
,
0
),
0
,
wm5110_sysclk_ev
,
SND_SOC_DAPM_POST_PMU
),
SND_SOC_DAPM_SUPPLY
(
"ASYNCCLK"
,
ARIZONA_ASYNC_CLOCK_1
,
SND_SOC_DAPM_SUPPLY
(
"ASYNCCLK"
,
ARIZONA_ASYNC_CLOCK_1
,
ARIZONA_ASYNC_CLK_ENA_SHIFT
,
0
,
NULL
,
0
),
ARIZONA_ASYNC_CLK_ENA_SHIFT
,
0
,
NULL
,
0
),
SND_SOC_DAPM_SUPPLY
(
"OPCLK"
,
ARIZONA_OUTPUT_SYSTEM_CLOCK
,
SND_SOC_DAPM_SUPPLY
(
"OPCLK"
,
ARIZONA_OUTPUT_SYSTEM_CLOCK
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment