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
Kirill Smelkov
linux
Commits
8c617791
Commit
8c617791
authored
Feb 05, 2015
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/fix/atmel' into asoc-linus
parents
e36f014e
20cf2603
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
17 deletions
+7
-17
sound/soc/atmel/atmel_ssc_dai.c
sound/soc/atmel/atmel_ssc_dai.c
+7
-17
No files found.
sound/soc/atmel/atmel_ssc_dai.c
View file @
8c617791
...
@@ -348,7 +348,6 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -348,7 +348,6 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
struct
atmel_pcm_dma_params
*
dma_params
;
struct
atmel_pcm_dma_params
*
dma_params
;
int
dir
,
channels
,
bits
;
int
dir
,
channels
,
bits
;
u32
tfmr
,
rfmr
,
tcmr
,
rcmr
;
u32
tfmr
,
rfmr
,
tcmr
,
rcmr
;
int
start_event
;
int
ret
;
int
ret
;
int
fslen
,
fslen_ext
;
int
fslen
,
fslen_ext
;
...
@@ -457,19 +456,10 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -457,19 +456,10 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
* The SSC transmit clock is obtained from the BCLK signal on
* The SSC transmit clock is obtained from the BCLK signal on
* on the TK line, and the SSC receive clock is
* on the TK line, and the SSC receive clock is
* generated from the transmit clock.
* generated from the transmit clock.
*
* For single channel data, one sample is transferred
* on the falling edge of the LRC clock.
* For two channel data, one sample is
* transferred on both edges of the LRC clock.
*/
*/
start_event
=
((
channels
==
1
)
?
SSC_START_FALLING_RF
:
SSC_START_EDGE_RF
);
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
0
)
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
0
)
|
SSC_BF
(
RCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
RCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
RCMR_START
,
start_event
)
|
SSC_BF
(
RCMR_START
,
SSC_START_FALLING_RF
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_RISING
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_RISING
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKS
,
ssc
->
clk_from_rk_pin
?
|
SSC_BF
(
RCMR_CKS
,
ssc
->
clk_from_rk_pin
?
...
@@ -478,14 +468,14 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -478,14 +468,14 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
rfmr
=
SSC_BF
(
RFMR_FSEDGE
,
SSC_FSEDGE_POSITIVE
)
rfmr
=
SSC_BF
(
RFMR_FSEDGE
,
SSC_FSEDGE_POSITIVE
)
|
SSC_BF
(
RFMR_FSOS
,
SSC_FSOS_NONE
)
|
SSC_BF
(
RFMR_FSOS
,
SSC_FSOS_NONE
)
|
SSC_BF
(
RFMR_FSLEN
,
0
)
|
SSC_BF
(
RFMR_FSLEN
,
0
)
|
SSC_BF
(
RFMR_DATNB
,
0
)
|
SSC_BF
(
RFMR_DATNB
,
(
channels
-
1
)
)
|
SSC_BIT
(
RFMR_MSBF
)
|
SSC_BIT
(
RFMR_MSBF
)
|
SSC_BF
(
RFMR_LOOP
,
0
)
|
SSC_BF
(
RFMR_LOOP
,
0
)
|
SSC_BF
(
RFMR_DATLEN
,
(
bits
-
1
));
|
SSC_BF
(
RFMR_DATLEN
,
(
bits
-
1
));
tcmr
=
SSC_BF
(
TCMR_PERIOD
,
0
)
tcmr
=
SSC_BF
(
TCMR_PERIOD
,
0
)
|
SSC_BF
(
TCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
TCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
TCMR_START
,
start_event
)
|
SSC_BF
(
TCMR_START
,
SSC_START_FALLING_RF
)
|
SSC_BF
(
TCMR_CKI
,
SSC_CKI_FALLING
)
|
SSC_BF
(
TCMR_CKI
,
SSC_CKI_FALLING
)
|
SSC_BF
(
TCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
TCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
TCMR_CKS
,
ssc
->
clk_from_rk_pin
?
|
SSC_BF
(
TCMR_CKS
,
ssc
->
clk_from_rk_pin
?
...
@@ -495,7 +485,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -495,7 +485,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
|
SSC_BF
(
TFMR_FSDEN
,
0
)
|
SSC_BF
(
TFMR_FSDEN
,
0
)
|
SSC_BF
(
TFMR_FSOS
,
SSC_FSOS_NONE
)
|
SSC_BF
(
TFMR_FSOS
,
SSC_FSOS_NONE
)
|
SSC_BF
(
TFMR_FSLEN
,
0
)
|
SSC_BF
(
TFMR_FSLEN
,
0
)
|
SSC_BF
(
TFMR_DATNB
,
0
)
|
SSC_BF
(
TFMR_DATNB
,
(
channels
-
1
)
)
|
SSC_BIT
(
TFMR_MSBF
)
|
SSC_BIT
(
TFMR_MSBF
)
|
SSC_BF
(
TFMR_DATDEF
,
0
)
|
SSC_BF
(
TFMR_DATDEF
,
0
)
|
SSC_BF
(
TFMR_DATLEN
,
(
bits
-
1
));
|
SSC_BF
(
TFMR_DATLEN
,
(
bits
-
1
));
...
@@ -512,7 +502,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -512,7 +502,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
ssc_p
->
rcmr_period
)
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
ssc_p
->
rcmr_period
)
|
SSC_BF
(
RCMR_STTDLY
,
1
)
|
SSC_BF
(
RCMR_STTDLY
,
1
)
|
SSC_BF
(
RCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
RCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_
RIS
ING
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_
FALL
ING
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKS
,
SSC_CKS_DIV
);
|
SSC_BF
(
RCMR_CKS
,
SSC_CKS_DIV
);
...
@@ -527,7 +517,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -527,7 +517,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
tcmr
=
SSC_BF
(
TCMR_PERIOD
,
ssc_p
->
tcmr_period
)
tcmr
=
SSC_BF
(
TCMR_PERIOD
,
ssc_p
->
tcmr_period
)
|
SSC_BF
(
TCMR_STTDLY
,
1
)
|
SSC_BF
(
TCMR_STTDLY
,
1
)
|
SSC_BF
(
TCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
TCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
TCMR_CKI
,
SSC_CKI_
RIS
ING
)
|
SSC_BF
(
TCMR_CKI
,
SSC_CKI_
FALL
ING
)
|
SSC_BF
(
TCMR_CKO
,
SSC_CKO_CONTINUOUS
)
|
SSC_BF
(
TCMR_CKO
,
SSC_CKO_CONTINUOUS
)
|
SSC_BF
(
TCMR_CKS
,
SSC_CKS_DIV
);
|
SSC_BF
(
TCMR_CKS
,
SSC_CKS_DIV
);
...
@@ -556,7 +546,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
...
@@ -556,7 +546,7 @@ static int atmel_ssc_hw_params(struct snd_pcm_substream *substream,
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
0
)
rcmr
=
SSC_BF
(
RCMR_PERIOD
,
0
)
|
SSC_BF
(
RCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
RCMR_STTDLY
,
START_DELAY
)
|
SSC_BF
(
RCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
RCMR_START
,
SSC_START_RISING_RF
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_
RIS
ING
)
|
SSC_BF
(
RCMR_CKI
,
SSC_CKI_
FALL
ING
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKO
,
SSC_CKO_NONE
)
|
SSC_BF
(
RCMR_CKS
,
ssc
->
clk_from_rk_pin
?
|
SSC_BF
(
RCMR_CKS
,
ssc
->
clk_from_rk_pin
?
SSC_CKS_PIN
:
SSC_CKS_CLOCK
);
SSC_CKS_PIN
:
SSC_CKS_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