st in case...
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index e7ffcfff6594..89e5428c8de6 100644
--- a/drivers/spi/spi-dw-core.c
+++ b/drivers/spi/spi
Simplify the dw_spi_add_host() method a bit by replacing the currently
implemented default set_cs callback setting up and later having it
overwritten by a custom function with direct if-else-based callback
assignment.
Signed-off-by: Serge Semin
---
Changelog v2:
- Replace the ternary operator
of setting it up.
By doing so we'll finally make the SPI device chip_data serving as it's
supposed to - to preserve the SPI device specific DW SPI configuration.
See spi-fsl-dspi.c, spi-pl022.c, spi-pxa2xx.c drivers for example of the
way the chip data is utilized.
Signed-off-by: Serge Semin
in case of an error or having the CS left set by a bootloader
or another software.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index cfc9f63acde4..eb1d46983319 100644
applicable for the memory
operations, since the standard SPI core interface is implemented with an
assumption that there is no problem with the automatic CS toggling.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +++-
drivers/spi/spi-dw.h | 1 +
2 files changed, 4 insertions(+), 1
of the new method to detect the errors in the IRQ- and DMA-based SPI
transfer execution procedures.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 43 +++
drivers/spi/spi-dw-dma.c | 11 ++
drivers/spi/spi-dw.h | 1 +
3 files changed, 37
controller with fixed automatic CS toggle functionality.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 1 +
drivers/spi/spi-dw-core.c | 301 ++
drivers/spi/spi-dw.h | 13 ++
3 files
that. We'll also need a way to explicitly set and clear the
corresponding CS bit at a certain moment of the operation. Let's alter
the set_cs function then to also de-activate the CS, when it's required.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 2 +-
1 file changed, 1 insertion
The parameter will be needed for another wait-done method being added in
the framework of the SPI memory operation modification in a further
commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-dma.c | 5 ++---
drivers/spi/spi-dw.h | 2 ++
2 files changed, 4 insertions(+), 3 deletions
one.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 41 ++-
1 file changed, 23 insertions(+), 18 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 4a45610c85f1..e7ffcfff6594 100644
--- a/drivers/spi/spi-dw-core.c
Add myself as a maintainer of the Synopsis DesignWare APB SSI driver.
Suggested-by: Andy Shevchenko
Signed-off-by: Serge Semin
Link:
https://lore.kernel.org/linux-spi/20201001222829.15977-1-sergey.se...@baikalelectronics.ru/
---
MAINTAINERS | 7 +++
1 file changed, 7 insertions(+)
diff
On Fri, Oct 02, 2020 at 11:08:29PM +0300, Serge Semin wrote:
> On Fri, Oct 02, 2020 at 10:46:09PM +0300, Serge Semin wrote:
> > On Fri, Oct 02, 2020 at 09:26:07PM +0300, Andy Shevchenko wrote:
> > > On Fri, Oct 2, 2020 at 8:18 PM Serge Semin
> > > wrote:
> > >
On Fri, Oct 02, 2020 at 10:46:09PM +0300, Serge Semin wrote:
> On Fri, Oct 02, 2020 at 09:26:07PM +0300, Andy Shevchenko wrote:
> > On Fri, Oct 2, 2020 at 8:18 PM Serge Semin
> > wrote:
> > >
> > > On Fri, Oct 02, 2020 at 01:19:29PM +0300, Andy Shevchenko wrote:
&
On Fri, Oct 02, 2020 at 09:24:55PM +0300, Andy Shevchenko wrote:
> On Fri, Oct 2, 2020 at 8:47 PM Serge Semin
> wrote:
> > On Fri, Oct 02, 2020 at 01:22:46PM +0300, Andy Shevchenko wrote:
> > > On Fri, Oct 02, 2020 at 01:28:11AM +0300, Serge Semin wrote:
>
> > &g
On Fri, Oct 02, 2020 at 09:26:07PM +0300, Andy Shevchenko wrote:
> On Fri, Oct 2, 2020 at 8:18 PM Serge Semin
> wrote:
> >
> > On Fri, Oct 02, 2020 at 01:19:29PM +0300, Andy Shevchenko wrote:
> > > On Fri, Oct 02, 2020 at 01:28:10AM +0300, Serge Semin wrote:
>
On Fri, Oct 02, 2020 at 01:22:46PM +0300, Andy Shevchenko wrote:
> On Fri, Oct 02, 2020 at 01:28:11AM +0300, Serge Semin wrote:
> > Indeed there is no point in detecting the SPI peripheral device parameters
> > and initializing the CR0 register fields each time an SPI transfer
On Fri, Oct 02, 2020 at 01:19:29PM +0300, Andy Shevchenko wrote:
> On Fri, Oct 02, 2020 at 01:28:10AM +0300, Serge Semin wrote:
> > Currently DWC SSI core is supported by means of setting up the
> > core-specific update_cr0() callback. It isn't suitable for multiple
> >
that. We'll also need a way to explicitly set and clear the
corresponding CS bit at a certain moment of the operation. Let's alter
the set_cs function then to also de-activate the CS, when it's required.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 2 +-
1 file changed, 1 insertion
in case of an error or having the CS left set by a bootloader
or another software.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index cfc9f63acde4..eb1d46983319 100644
driver, but by the glue layer drivers too. This will be required
in a coming further commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 29 +
drivers/spi/spi-dw.h | 10 ++
2 files changed, 27 insertions(+), 12 deletions(-)
diff --git
procedure by removing the clock-related
fields from the peripheral chip data and update the DW SPI clock divider
only if it's really changed. The later change is reached by keeping the
effective SPI bus speed in the internal DW SPI private data.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw
is sent out, we'll disable the Tx FIFO Empty IRQ. If
there is still some data to receive, we'll adjust the Rx FIFO Threshold
level, so the next IRQ would be raised at the moment of all incoming data
being available in the Rx FIFO.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 33
st in case...
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index db3fec4195f7..58a7c7465c61 100644
--- a/drivers/spi/spi-dw-core.c
+++ b/drivers/spi/spi
one.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 41 ++-
1 file changed, 23 insertions(+), 18 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 74e8f0da2883..db3fec4195f7 100644
--- a/drivers/spi/spi-dw-core.c
returned from the dma_setup
callback to be erroneous as it's supposed to be in the kernel.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 58a7c7465c61
The parameter will be needed for another wait-done method being added in
the framework of the SPI memory operation modification in a further
commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-dma.c | 5 ++---
drivers/spi/spi-dw.h | 2 ++
2 files changed, 4 insertions(+), 3 deletions
Rx sample delay can be SPI device specific, and should be synchronously
initialized with the rest of the communication and peripheral device
related controller setups. So let's move the Rx-sample delay setup into
the DW APB SSI configuration update method.
Signed-off-by: Serge Semin
---
drivers
of the DW SPI core module.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 28
drivers/spi/Makefile | 1 +
drivers/spi/spi-dw-bt1.c | 339 +++
3 files changed, 368 insertions
of the new method to detect the errors in the IRQ- and DMA-based SPI
transfer execution procedures.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 43 +++
drivers/spi/spi-dw-dma.c | 11 ++
drivers/spi/spi-dw.h | 1 +
3 files changed, 37
ATCH 00/04] spi: dw: Clear IRQ status on DW SPI controller reset
[PATCH 00/03] spi: dw: Initialize n_bytes before the memory barrier
[PATCH 00/01] spi: dw: Discard IRQ threshold macro
Changelog v3:
- Remove dw_spi_update_cr0() callback assignment from the DW APB SSI PCI
glue-driver.
Signed-o
and there in
the tx_max(), rx_max(), dw_writer() and dw_reader() methods. Such
modification will not only give us the more optimized IO procedures, but
will make the data IO methods much more readable than before.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 37
to have a generic function name not related to CR0.
Leave the too long line with the chip->clk_div setting as is for now,
since it's going to be changed later anyway.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 28 ++--
1 file changed, 14 insertions(+),
controller setup to make the dw_spi_update_cr0() method looking coherent.
Signed-off-by: Serge Semin
---
Changelog v2:
- Get back the in-code comments to the dw_spi_update_cr0() method and it'
further derivatives.
Changelog v3:
- Remove dw_spi_update_cr0() callback assignment from the DW APB SSI PCI
of setting it up.
By doing so we'll finally make the SPI device chip_data serving as it's
supposed to - to preserve the SPI device specific DW SPI configuration.
See spi-fsl-dspi.c, spi-pl022.c, spi-pxa2xx.c drivers for example of the
way the chip data is utilized.
Signed-off-by: Serge Semin
-off-by: Serge Semin
Reviewed-by: Rob Herring
---
.../bindings/spi/snps,dw-apb-ssi.yaml | 33 +--
1 file changed, 31 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml
b/Documentation/devicetree/bindings/spi/snps,dw-apb
t iteration. Finally the errors
status is checked on each iteration.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 40 ++-
1 file changed, 39 insertions(+), 1 deletion(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index cc217b
controller with fixed automatic CS toggle functionality.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 1 +
drivers/spi/spi-dw-core.c | 300 ++
drivers/spi/spi-dw.h | 13 ++
3 files
applicable for the memory
operations, since the standard SPI core interface is implemented with an
assumption that there is no problem with the automatic CS toggling.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +++-
drivers/spi/spi-dw.h | 1 +
2 files changed, 4 insertions(+), 1
Simplify the dw_spi_add_host() method a bit by replacing the currently
implemented default set_cs callback setting up and later having it
overwritten by a custom function with direct if-else-based callback
assignment.
Signed-off-by: Serge Semin
---
Changelog v2:
- Replace the ternary operator
On Thu, Oct 01, 2020 at 10:51:05PM +0100, Mark Brown wrote:
> On Wed, Sep 30, 2020 at 09:55:26PM +0300, Serge Semin wrote:
> > Currently DWC SSI core is supported by means of setting up the
> > core-specific update_cr0() callback. It isn't suitable for multiple
> > reasons
is sent out, we'll disable the Tx FIFO Empty IRQ. If
there is still some data to receive, we'll adjust the Rx FIFO Threshold
level, so the next IRQ would be raised at the moment of all incoming data
being available in the Rx FIFO.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 33
in case of an error or having the CS left set by a bootloader
or another software.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index cfc9f63acde4..eb1d46983319 100644
procedure by removing the clock-related
fields from the peripheral chip data and update the DW SPI clock divider
only if it's really changed. The later change is reached by keeping the
effective SPI bus speed in the internal DW SPI private data.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw
of the new method to detect the errors in the IRQ- and DMA-based SPI
transfer execution procedures.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 43 +++
drivers/spi/spi-dw-dma.c | 11 ++
drivers/spi/spi-dw.h | 1 +
3 files changed, 37
of setting it up.
By doing so we'll finally make the SPI device chip_data serving as it's
supposed to - to preserve the SPI device specific DW SPI configuration.
See spi-fsl-dspi.c, spi-pl022.c, spi-pxa2xx.c drivers for example of the
way the chip data is utilized.
Signed-off-by: Serge Semin
one.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 41 ++-
1 file changed, 23 insertions(+), 18 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 74e8f0da2883..db3fec4195f7 100644
--- a/drivers/spi/spi-dw-core.c
t iteration. Finally the errors
status is checked on each iteration.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 40 ++-
1 file changed, 39 insertions(+), 1 deletion(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index cc217b
applicable for the memory
operations, since the standard SPI core interface is implemented with an
assumption that there is no problem with the automatic CS toggling.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +++-
drivers/spi/spi-dw.h | 1 +
2 files changed, 4 insertions(+), 1
The parameter will be needed for another wait-done method being added in
the framework of the SPI memory operation modification in a further
commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-dma.c | 5 ++---
drivers/spi/spi-dw.h | 2 ++
2 files changed, 4 insertions(+), 3 deletions
that. We'll also need a way to explicitly set and clear the
corresponding CS bit at a certain moment of the operation. Let's alter
the set_cs function then to also de-activate the CS, when it's required.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 2 +-
1 file changed, 1 insertion
of the DW SPI core module.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 28
drivers/spi/Makefile | 1 +
drivers/spi/spi-dw-bt1.c | 339 +++
3 files changed, 368 insertions
Simplify the dw_spi_add_host() method a bit by replacing the currently
implemented default set_cs callback setting up and later having it
overwritten by a custom function with direct if-else-based callback
assignment.
Signed-off-by: Serge Semin
---
Changelog v2:
- Replace the ternary operator
st in case...
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index db3fec4195f7..58a7c7465c61 100644
--- a/drivers/spi/spi-dw-core.c
+++ b/drivers/spi/spi
controller setup to make the dw_spi_update_cr0() method looking coherent.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 80 ++-
drivers/spi/spi-dw-mmio.c | 20 +-
drivers/spi/spi-dw.h | 9 +
3 files changed, 40 insertions(+), 69
Rx sample delay can be SPI device specific, and should be synchronously
initialized with the rest of the communication and peripheral device
related controller setups. So let's move the Rx-sample delay setup into
the DW APB SSI configuration update method.
Signed-off-by: Serge Semin
---
drivers
returned from the dma_setup
callback to be erroneous as it's supposed to be in the kernel.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 58a7c7465c61
ATCH 00/04] spi: dw: Clear IRQ status on DW SPI controller reset
[PATCH 00/03] spi: dw: Initialize n_bytes before the memory barrier
[PATCH 00/01] spi: dw: Discard IRQ threshold macro
Signed-off-by: Serge Semin
Cc: Alexey Malahov
Cc: Ramil Zaripov
Cc: Pavel Parkhomenko
Cc: Andy Shevchenko
controller with fixed automatic CS toggle functionality.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 1 +
drivers/spi/spi-dw-core.c | 300 ++
drivers/spi/spi-dw.h | 13 ++
3 files
-off-by: Serge Semin
Reviewed-by: Rob Herring
---
.../bindings/spi/snps,dw-apb-ssi.yaml | 33 +--
1 file changed, 31 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml
b/Documentation/devicetree/bindings/spi/snps,dw-apb
and there in
the tx_max(), rx_max(), dw_writer() and dw_reader() methods. Such
modification will not only give us the more optimized IO procedures, but
will make the data IO methods much more readable than before.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 37
to have a generic function name not related to CR0.
Leave the too long line with the chip->clk_div setting as is for now,
since it's going to be changed later anyway.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 28 ++--
1 file changed, 14 insertions(+),
driver, but by the glue layer drivers too. This will be required
in a coming further commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 29 +
drivers/spi/spi-dw.h | 10 ++
2 files changed, 27 insertions(+), 12 deletions(-)
diff --git
On Wed, Sep 30, 2020 at 04:41:49PM +0100, Mark Brown wrote:
> On Wed, Sep 30, 2020 at 06:03:12PM +0300, Serge Semin wrote:
> > On Wed, Sep 30, 2020 at 01:17:37AM +0300, Serge Semin wrote:
>
> > > > > - /*
> > > > > - * SPI mode (SCPOL|SCPH)
On Wed, Sep 30, 2020 at 04:01:17PM +0100, Mark Brown wrote:
> On Wed, Sep 30, 2020 at 05:57:59PM +0300, Serge Semin wrote:
> > On Wed, Sep 30, 2020 at 12:55:55AM +0300, Serge Semin wrote:
>
> > > + if (dws->set_cs)
> > > + master->set_cs = dws->set_
Mark,
A concrete question is below of my previous comment.
On Wed, Sep 30, 2020 at 01:17:37AM +0300, Serge Semin wrote:
> On Tue, Sep 29, 2020 at 02:52:33PM +0100, Mark Brown wrote:
> > On Sun, Sep 20, 2020 at 02:28:55PM +0300, Serge Semin wrote:
> >
> > > - /*
> &g
Mark,
A concrete question is below the main text.)
On Wed, Sep 30, 2020 at 12:55:55AM +0300, Serge Semin wrote:
> On Tue, Sep 29, 2020 at 02:11:53PM +0100, Mark Brown wrote:
> > On Sun, Sep 20, 2020 at 02:28:46PM +0300, Serge Semin wrote:
> > > Simplify the dw_spi_add_h
On Wed, Sep 30, 2020 at 12:15:32PM +0200, Thomas Bogendoerfer wrote:
> On Wed, Sep 30, 2020 at 12:12:32AM +0300, Serge Semin wrote:
> > Thomas,
> > Any comment on the series? The changes aren't that comprehensive, so it
> > would
> > be great to merge it in before the
On Wed, Sep 30, 2020 at 12:04:04PM +0100, Mark Brown wrote:
> On Wed, Sep 30, 2020 at 01:43:03AM +0300, Serge Semin wrote:
> > On Tue, Sep 29, 2020 at 03:43:51PM +0100, Mark Brown wrote:
>
> > > This is a *huge* patch series which is a bit unweildy to review
> > >
Hi Mark
On Tue, Sep 29, 2020 at 03:43:51PM +0100, Mark Brown wrote:
> On Sun, Sep 20, 2020 at 02:28:44PM +0300, Serge Semin wrote:
>
> > First two patches are just cleanups to simplify the DW APB SSI device
> > initialization a bit. We suggest to discard the IRQ threshold m
On Tue, Sep 29, 2020 at 02:52:33PM +0100, Mark Brown wrote:
> On Sun, Sep 20, 2020 at 02:28:55PM +0300, Serge Semin wrote:
>
> > - /*
> > -* SPI mode (SCPOL|SCPH)
> > -* CTRLR0[ 8] Serial Clock Phase
> > -* CTRLR0[ 9] Serial Clock Polarity
> >
On Tue, Sep 29, 2020 at 02:28:11PM +0100, Mark Brown wrote:
> On Sun, Sep 20, 2020 at 02:28:48PM +0300, Serge Semin wrote:
> > There is no point in having the commit 19b61392c5a8 ("spi: spi-dw: Add
> > lock protect dw_spi rx/tx to prevent concurrent calls") applied. T
On Tue, Sep 29, 2020 at 02:12:25PM +0100, Mark Brown wrote:
> On Sun, Sep 20, 2020 at 02:28:47PM +0300, Serge Semin wrote:
> > Since n_bytes field of the DW SPI private data is also utilized by the
> > IRQ handler, we need to make sure it' initialization is done before the
>
On Tue, Sep 29, 2020 at 02:11:53PM +0100, Mark Brown wrote:
> On Sun, Sep 20, 2020 at 02:28:46PM +0300, Serge Semin wrote:
> > Simplify the dw_spi_add_host() method a bit by replacing the set_cs
> > callback overwrite procedure with direct setting the callback if a custom
>
Thomas,
Any comment on the series? The changes aren't that comprehensive, so it would
be great to merge it in before the 5.10 merge window is opened.
-Sergey
On Sun, Sep 20, 2020 at 02:00:08PM +0300, Serge Semin wrote:
> It has been discovered that on our MIPS P5600-based CPU the IO access
Hello,
On Sun, Sep 27, 2020 at 05:01:52PM +0200, Hans de Goede wrote:
> Hi,
>
> On 9/23/20 6:19 PM, Serge Semin wrote:
> > Hans has discovered that there is a potential deadlock between the ref
> > clock change notifier and the port suspension procedures {see the l
On Fri, Sep 25, 2020 at 11:54:20AM +0800, Jiaxun Yang wrote:
>
>
> 在 2020/9/20 19:00, Serge Semin 写道:
> > In accordance with [1, 2] memory transactions using CCA=2 (Uncached
> > Cacheability and Coherency Attribute) are always strongly ordered. This
> > means the yo
Signed-off-by: Serge Semin
---
drivers/tty/serial/8250/8250_port.c | 4
1 file changed, 4 insertions(+)
diff --git a/drivers/tty/serial/8250/8250_port.c
b/drivers/tty/serial/8250/8250_port.c
index 1259fb6b66b3..b0af13074cd3 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/
Hans de Goede
Signed-off-by: Serge Semin
---
drivers/tty/serial/8250/8250_dw.c | 54 +++
1 file changed, 19 insertions(+), 35 deletions(-)
diff --git a/drivers/tty/serial/8250/8250_dw.c
b/drivers/tty/serial/8250/8250_dw.c
index 87f450b7c177..9e204f9b799a 100644
--- a/drivers/
8250: Add 8250 port clock update method")
Signed-off-by: Serge Semin
---
drivers/tty/serial/8250/8250_port.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/tty/serial/8250/8250_port.c
b/drivers/tty/serial/8250/8250_port.c
index c71d647eb87a..1259fb6b66b3 100644
--- a/drivers/
ial: 8250_dw: Fix common clocks usage race condition")
Fixes: 868f3ee6e452 ("serial: 8250: Add 8250 port clock update method")
Reported-by: Hans de Goede
Signed-off-by: Serge Semin
Cc: Alexey Malahov
Cc: Pavel Parkhomenko
Cc: Andy Shevchenko
Cc: Maxime Ripard
Cc: Will Deacon
Cc:
of the DW SPI core module.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 28
drivers/spi/Makefile | 1 +
drivers/spi/spi-dw-bt1.c | 339 +++
3 files changed, 368 insertions
and when there is no SPI message currently being processed.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 18411f5b9954..be94ed5bb896 100644
of the new method to detect the errors in the IRQ- and DMA-based SPI
transfer execution procedures.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 43 +++
drivers/spi/spi-dw-dma.c | 11 ++
drivers/spi/spi-dw.h | 1 +
3 files changed, 37
Rx sample delay can be SPI device specific, and should be synchronously
initialized with the rest of the communication and peripheral device
related controller setups. So let's move the Rx-sample delay setup into
the DW APB SSI configuration update method.
Signed-off-by: Serge Semin
---
drivers
returned from the dma_setup
callback to be erroneous as it's supposed to be in the kernel.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 8dbe11c1821c
st in case...
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 08bc53b9de88..8dbe11c1821c 100644
--- a/drivers/spi/spi-dw-core.c
+++ b/drivers/spi/spi
by the data transfer algorithm implementation:
first we initialize the buffers pointers, then make sure the assignments
are visible by the other CPUs by calling the smp_mb(), only after that
enable the interrupt, which handler uses the buffers.
Signed-off-by: Serge Semin
---
Folks. I have also a doubt
in mind let's discard the update_cr0() callbacks,
define a generic and static dw_spi_update_cr0() method and create the
DW_SPI_CAP_DWC_SSI capability, which when enabled would activate the
alternative CR0 register layout.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 69
driver, but by the glue layer drivers too. This will be required
in a coming further commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 29 +
drivers/spi/spi-dw.h | 10 ++
2 files changed, 27 insertions(+), 12 deletions(-)
diff --git
applicable for the memory
operations, since the standard SPI core interface is implemented with an
assumption that there is no problem with the automatic CS toggling.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 4 +++-
drivers/spi/spi-dw.h | 1 +
2 files changed, 4 insertions(+), 1
is sent out, we'll disable the Tx FIFO Empty IRQ. If
there is still some data to receive, we'll adjust the Rx FIFO Threshold
level, so the next IRQ would be raised at the moment of all incoming data
being available in the Rx FIFO.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 33
one.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 41 ++-
1 file changed, 23 insertions(+), 18 deletions(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 682463b2f68b..08bc53b9de88 100644
--- a/drivers/spi/spi-dw-core.c
in the dedicated controller reset method.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index 1ab704d1ebd8..ff77f39047ce 100644
--- a/drivers/spi/spi-dw.h
+++ b/drivers/spi
and there in
the tx_max(), rx_max(), dw_writer() and dw_reader() methods. Such
modification will not only give us the more optimized IO procedures, but
will make the data IO methods much more readable than before.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 37
in case of an error or having the CS left set by a bootloader
or another software.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw.h | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index cfc9f63acde4..eb1d46983319 100644
to have a generic function name not related to CR0.
Leave the too long line with the chip->clk_div setting as is for now,
since it's going to be changed later anyway.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 28 ++--
1 file changed, 14 insertions(+),
controller with fixed automatic CS toggle functionality.
Co-developed-by: Ramil Zaripov
Signed-off-by: Ramil Zaripov
Signed-off-by: Serge Semin
---
drivers/spi/Kconfig | 1 +
drivers/spi/spi-dw-core.c | 300 ++
drivers/spi/spi-dw.h | 13 ++
3 files
The parameter will be needed for another wait-done method being added in
the framework of the SPI memory operation modification in a further
commit.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-dma.c | 5 ++---
drivers/spi/spi-dw.h | 2 ++
2 files changed, 4 insertions(+), 3 deletions
t iteration. Finally the errors
status is checked on each iteration.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw-core.c | 40 ++-
1 file changed, 39 insertions(+), 1 deletion(-)
diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 7b9012
procedure by removing the clock-related
fields from the peripheral chip data and update the DW SPI clock divider
only if it's really changed. The later change is reached by keeping the
effective SPI bus speed in the internal DW SPI private data.
Signed-off-by: Serge Semin
---
drivers/spi/spi-dw
501 - 600 of 2111 matches
Mail list logo