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
ec058615
Commit
ec058615
authored
Nov 26, 2014
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branches 'spi/fix/dw' and 'spi/fix/sirf' into spi-linus
parents
13616c71
0a8727e6
9c4b19a0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
7 deletions
+3
-7
drivers/spi/spi-dw.c
drivers/spi/spi-dw.c
+1
-5
drivers/spi/spi-sirf.c
drivers/spi/spi-sirf.c
+2
-2
No files found.
drivers/spi/spi-dw.c
View file @
ec058615
...
...
@@ -376,9 +376,6 @@ static void pump_transfers(unsigned long data)
chip
=
dws
->
cur_chip
;
spi
=
message
->
spi
;
if
(
unlikely
(
!
chip
->
clk_div
))
chip
->
clk_div
=
dws
->
max_freq
/
chip
->
speed_hz
;
if
(
message
->
state
==
ERROR_STATE
)
{
message
->
status
=
-
EIO
;
goto
early_exit
;
...
...
@@ -419,7 +416,7 @@ static void pump_transfers(unsigned long data)
if
(
transfer
->
speed_hz
)
{
speed
=
chip
->
speed_hz
;
if
(
transfer
->
speed_hz
!=
speed
)
{
if
(
(
transfer
->
speed_hz
!=
speed
)
||
(
!
chip
->
clk_div
)
)
{
speed
=
transfer
->
speed_hz
;
/* clk_div doesn't support odd number */
...
...
@@ -581,7 +578,6 @@ static int dw_spi_setup(struct spi_device *spi)
dev_err
(
&
spi
->
dev
,
"No max speed HZ parameter
\n
"
);
return
-
EINVAL
;
}
chip
->
speed_hz
=
spi
->
max_speed_hz
;
chip
->
tmode
=
0
;
/* Tx & Rx */
/* Default SPI mode is SCPOL = 0, SCPH = 0 */
...
...
drivers/spi/spi-sirf.c
View file @
ec058615
...
...
@@ -562,9 +562,9 @@ spi_sirfsoc_setup_transfer(struct spi_device *spi, struct spi_transfer *t)
sspi
->
word_width
=
DIV_ROUND_UP
(
bits_per_word
,
8
);
txfifo_ctrl
=
SIRFSOC_SPI_FIFO_THD
(
SIRFSOC_SPI_FIFO_SIZE
/
2
)
|
sspi
->
word_width
;
(
sspi
->
word_width
>>
1
)
;
rxfifo_ctrl
=
SIRFSOC_SPI_FIFO_THD
(
SIRFSOC_SPI_FIFO_SIZE
/
2
)
|
sspi
->
word_width
;
(
sspi
->
word_width
>>
1
)
;
if
(
!
(
spi
->
mode
&
SPI_CS_HIGH
))
regval
|=
SIRFSOC_SPI_CS_IDLE_STAT
;
...
...
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