On Tue, Jun 4, 2013 at 3:13 AM, Scott Jiang scott.jiang.li...@gmail.com wrote:
diff --git a/drivers/spi/spi-bfin6xx.c b/drivers/spi/spi-bfin6xx.c
+#include linux/workqueue.h
Why do you need this?
--
Get 100%
On Wed, Sep 26, 2012 at 5:49 PM, Mark Brown
broo...@opensource.wolfsonmicro.com wrote:
On Wed, Sep 26, 2012 at 02:17:36PM +0200, Linus Walleij wrote:
On Wed, Sep 26, 2012 at 1:24 PM, Vipul Kumar Samar
SPI functional clock must be disalble/enable in non RTPM suspend/resume
hooks. Currently
On Mon, Sep 17, 2012 at 4:07 PM, Vipul Kumar Samar
vipulkumar.sa...@st.com wrote:
clk_{un}prepare is mandatory for platforms using common clock framework. Add
clk_{un}prepare() support for spi-pl022 runtime PM.
You are not calling these routines in actualy patch.. Fix commit log and add my
On Mon, Sep 17, 2012 at 7:09 PM, Linus Walleij linus.wall...@linaro.org wrote:
This driver does clk_prepare/unprepare at probe
and removed, so I guess what you're trying to say is that
on your platform the clk_unprepare() process context call
is needed to save power?
Please elaborate...
Hi
On 19 August 2012 03:56, Linus Walleij linus.wall...@linaro.org wrote:
On Sat, Aug 18, 2012 at 4:25 AM, Viresh Kumar viresh.ku...@linaro.org
wrote:
spi_register_master() calls of_register_spi_devices() to register spi
devices.
This routine expects master-dev.of_node to be a valid pointer
spi_register_master() calls of_register_spi_devices() to register spi devices.
This routine expects master-dev.of_node to be a valid pointer. This is
responsibility of master driver to fill this field, which wasn't done for pl022.
Fix it to get devices added to pl022.
Signed-off-by: Viresh Kumar
On 4/19/2012 2:44 PM, Viresh KUMAR wrote:
calculate_effective_freq() was still not optimized and there were cases when
it
returned without error and with values of cpsr and scr as zero.
Also, the variable named found is not used well.
This patch targets to optimize and correct
Shenoy vinit.she...@st.com
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers/spi/spi-pl022.c | 10 --
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c
index 09c925a..99d5f6d 100644
--- a/drivers/spi/spi-pl022.c
calculate_effective_freq() was still not optimized and there were cases when it
returned without error and with values of cpsr and scr as zero.
Also, the variable named found is not used well.
This patch targets to optimize and correct this routine. Tested for SPEAr.
Signed-off-by: Viresh Kumar
pl022_ssp_controller {
u16 bus_id;
@@ -250,6 +252,7 @@ struct pl022_ssp_controller {
void *dma_rx_param;
void *dma_tx_param;
int autosuspend_delay;
+ bool rt;
};
/**
Looks fine.
Acked-by: Viresh Kumar viresh.ku...@st.com
--
viresh
);
return 0;
}
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security
anymore?
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats
;
spin_unlock_irqrestore(pl022-queue_lock, flags);
queue_work(pl022-workqueue, pl022-pump_messages);
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
All the data continuously generated in your IT infrastructure
On 11/9/2011 4:08 PM, Linus WALLEIJ wrote:
+ /* default is to enable all interrupts except RX -
+ * this will be enabled once TX is complete
+ */
Other than fixing this multiline comment, everything other looks fine.
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
(spi-master);
unsigned int bits = spi-bits_per_word;
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
))
+ (~SSP_CR1_MASK_SSE)), SSP_CR1(pl022-virtbase));
+
/* This message is completed, so let's turn off the clocks power */
pm_runtime_put(pl022-adev-dev);
}
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
On 11/9/2011 4:09 PM, Linus WALLEIJ wrote:
From: Virupax Sadashivpetimath virupax.sadashivpetim...@stericsson.com
The loading of the default configuration before suspending has
been in the driver since its inception, but it is not really
needed. Especially so since we take to all the trouble
On 11/9/2011 4:09 PM, Linus WALLEIJ wrote:
From: Chris Blair chris.bl...@stericsson.com
diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c
index bffad2a..2e3522d 100644
--- a/drivers/spi/spi-pl022.c
+++ b/drivers/spi/spi-pl022.c
@@ -512,13 +512,6 @@ static void giveback(struct
*dma_tx_param;
+ int autosuspend_delay;
};
/**
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
(spi-master);
unsigned int bits = spi-bits_per_word;
Reviewed-by: Viresh Kumar viresh.ku...@st.com
--
viresh
--
All the data continuously generated in your IT infrastructure contains a
definitive record
status;
}
- amba_vcore_enable(adev);
- amba_pclk_enable(adev);
- load_ssp_default_config(pl022);
- amba_pclk_disable(adev);
- amba_vcore_disable(adev);
dev_dbg(adev-dev, suspended\n);
return 0;
}
Reviewed-by: Viresh Kumar viresh.ku...@st.com
On 9/1/2011 4:26 PM, Linus Walleij wrote:
I agree. Acked-by: Linus Walleij linus.wall...@linaro.org for
all except 6/6, it's probably just as possible to keep the channel handle
taken in the driver if we modify the affected DMA driver instead.
This would be better for performance I think.
Hi
On 8/10/2011 2:20 PM, Viresh KUMAR wrote:
Hi Grant,
I have added Tested-by: Linus Walleij linus.wall...@linaro.org on all
patches.
This patchset mainly covers following fixes:
- formatting related issues
- Passing GFP_ATOMIC for sg allocation from tasklet
- Fixing
tasklets don't allow invocation to sleeping routines. In configure_dma()
routine, sg_alloc_table() was called with GFP_KERNEL flag and so this causes
crash when called from tasklet.
Replace GFP_KERNEL with GFP_ATOMIC to get this fixed.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested
There were few formatting related issues in code. This patch fixes them.
Fixes include:
- Remove extra blank lines
- align code to 80 cols
- combine several lines to one line
- Replace multiple spaces with tabs
- Remove spaces before labels
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested
to get more closer rate.
This patch fixes these two issues, with some reformatting inside the code. This
also creates a inline routine to calculate prescaled rate based on spi's rate,
cpsdvsr and scr.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested-by: Linus Walleij linus.wall...@linaro.org
In routine configure_dma(), if transfer-len = PAGE_SIZE, then pages is one more
than required. While leads to one more sg getting allocated.
This is wrong. Correct this to allocate correct number of sg.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested-by: Linus Walleij linus.wall
pl022_dma_remove() should be called only if enable_dma is true. There is no
point calling it when pl022_dma_probe() is not called, which again depends on
enable_dma.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested-by: Linus Walleij linus.wall...@linaro.org
---
drivers/spi/spi-pl022.c
On 08/10/2011 02:30 PM, Russell King - ARM Linux wrote:
They must be allocated when they are required and must be freed after we
are
done with transfers. So that they can be used by other users.
Which DMA engine driver requires this?
dw_dmac.c
Normally, when we have DMA engine drivers
On 08/10/2011 02:24 PM, Russell King - ARM Linux wrote:
It would be far better for this to be:
pages = DIV_ROUND_UP(pl022-cur_transfer-len, PAGE_SIZE);
The compiler will probably optimize it to the same code anyway.
I thought of it too, but missed to update code. Thanks.
--
viresh
Currently we request DMA channels at probe time and free them at remove. They
are always occupied, irrespective of their usage.
They must be allocated when they are required and must be freed after we are
done with transfers. So that they can be used by other users.
Signed-off-by: Viresh Kumar
On 08/10/2011 03:31 PM, Koul, Vinod wrote:
And on your patch, are you able to dynamically assign the channels for
platform? What is the intended usage? (as Russell articulated it is bad
to dynamically assign channel for something like uart)
Are you talking about channels or DMA request lines?
In routine configure_dma(), if transfer-len = PAGE_SIZE, then pages is one more
than required. While leads to one more sg getting allocated.
This is wrong. Correct this to allocate correct number of sg.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Tested-by: Linus Walleij linus.wall
On 08/10/2011 05:12 PM, Sergei Shtylyov wrote:
- pages = (pl022-cur_transfer-len PAGE_SHIFT) + 1;
+ pages = ((pl022-cur_transfer-len + (1 PAGE_SHIFT) - 1)
+PAGE_SHIFT);
No need for parens around the rvalue.
Oops, that was a mistake. Anyway i have send V3 for the
There were few formatting related issues in code. This patch fixes them.
Fixes include:
- Remove extra blank lines
- align code to 80 cols
- combine several lines to one line
- Replace multiple spaces with tabs
- Remove spaces before labels
Signed-off-by: Viresh Kumar viresh.ku...@st.com
pl022_dma_remove() should be called only if enable_dma is true. There is no
point calling it when pl022_dma_probe() is not called, which again depends on
enable_dma.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers/spi/spi-pl022.c |8 ++--
1 files changed, 6 insertions(+), 2
:
commit 9be355da3bae9feb09cdaf80c3ab560f1f0172cb
Author: Stephen Rothwell s...@canb.auug.org.au
Date: Tue Aug 9 13:30:19 2011 +1000
Add linux-next specific files for 20110809
Signed-off-by: Stephen Rothwell s...@canb.auug.org.au
Looking forward to see your view on the patchset.
Viresh
In routine configure_dma(), if transfer-len = PAGE_SIZE, then pages is one more
than required. While leads to one more sg getting allocated.
This is wrong. Correct this to allocate correct number of sg.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers/spi/spi-pl022.c |3 ++-
1
Currently we request DMA channels at probe time and free them at remove. They
are always occupied, irrespective of their usage.
They must be allocated when they are required and must be freed after we are
done with transfers. So that they can be used by other users.
Signed-off-by: Viresh Kumar
tasklets don't allow invocation to sleeping routines. In configure_dma()
routine, sg_alloc_table() was called with GFP_KERNEL flag and so this causes
crash when called from tasklet.
Replace GFP_KERNEL with GFP_NOWAIT to get this fixed.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers
On 08/09/2011 04:56 PM, Jassi Brar wrote:
Since this could be called from when we actually need the transfer start,
maybe we could try harder using GFP_ATOMIC instead ?
Yes. Will do it.
--
viresh
--
uberSVN's rich
[Probably you missed reply-all by mistake, so adding them again]
On 08/10/2011 01:34 AM, Linus Walleij wrote:
On Tue, Aug 9, 2011 at 1:05 PM, Viresh Kumar viresh.ku...@st.com wrote:
There were few issues with calculate_effective_freq() routine:
- It was returning first rate found = requested
On 08/10/2011 01:40 AM, Linus Walleij wrote:
On Tue, Aug 9, 2011 at 1:05 PM, Viresh Kumar viresh.ku...@st.com wrote:
This patchset mainly covers following fixes:
- formatting related issues
- Passing GFP_NOWAIT for sg allocation from tasklet
- Fixing calculate_effective_freq() routine
On 08/04/2011 03:46 PM, Linus Walleij wrote:
No maybe not, my test cases are for single messages, and on production
systems we mainly use IRQ-driven traffic. I need to have these
tests added I believe :-/
If you fix this up it will be much appreciated!
Ya I am fixing this up. I have
Hi Linus,
I am preparing few patches for spi-pl022 for Allocating DMA channels as and
when required.
And i found something strange.
When we have many transfers in a single message, following routines are called
in
specified order:
tasklet_schedule(pump_transfers)
pump_transfers(unsigned long
On 05/16/2011 04:34 PM, Russell King - ARM Linux wrote:
On Mon, May 16, 2011 at 09:40:10AM +0530, Viresh Kumar wrote:
If pl022_dma_probe fails, we can try to transfer data in polling or
interrupt
mode. Also, set platform_info-enable_dma to 0, so that no other code
tries to
use dma
On 05/16/2011 09:40 AM, Viresh KUMAR wrote:
If pl022_dma_probe fails, we can try to transfer data in polling or interrupt
mode. Also, set platform_info-enable_dma to 0, so that no other code tries to
use dma.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Acked-by: Linus Walleij linus.wall
If pl022_dma_probe fails, we can try to transfer data in polling or interrupt
mode. Also, set platform_info-enable_dma to 0, so that no other code tries to
use dma.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
Acked-by: Linus Walleij linus.wall...@linaro.org
---
drivers/spi/amba-pl022.c
On 05/13/2011 08:01 PM, Linus Walleij wrote:
2011/5/13 viresh kumar viresh.ku...@st.com:
amba/pl022 and my dma driver dw_dmac.c, both have registered init() routines
with subsys_initcall(). Now at bootup, spi boots up before DMA and so DMA
channels are never available at spi probe.
What
On 05/13/2011 12:24 PM, Linus Walleij wrote:
2011/5/13 viresh kumar viresh.ku...@st.com:
Linus, Jamie,
Have you ever seen this kind of issue? Which spi slave memories did you used
for testing?
I am using standard pl0022 and m25p80 driver. Tried in all modes: polling,
interrupt, dma
If pl022_dma_probe fails, we can try to transfer data in polling or interrupt
mode. Also, set platform_info-enable_dma to 0, so that no other code tries to
use dma.
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers/spi/amba-pl022.c | 11 ++-
1 files changed, 6 insertions
Linus,
amba/pl022 and my dma driver dw_dmac.c, both have registered init() routines
with subsys_initcall(). Now at bootup, spi boots up before DMA and so DMA
channels are never available at spi probe.
What should be done to solve this issue?
One idea is allocate DMA channel as and when
On 5/13/11, Viresh Kumar viresh.ku...@st.com wrote:
diff --git a/drivers/spi/amba-pl022.c b/drivers/spi/amba-pl022.c
index 08de58e..82b98b8 100644
--- a/drivers/spi/amba-pl022.c
+++ b/drivers/spi/amba-pl022.c
@@ -1063,7 +1063,7 @@ static int __init pl022_dma_probe(struct pl022 *pl022
On 05/11/2011 09:37 AM, viresh kumar wrote:
Hello,
Following is what i understood after reading m25p80 driver and spi master
drivers in drivers/spi folder.
chip_select signal controls start and end of transfer. For ex: if we have to
read
status reg of spi memory, then we use
On 05/11/2011 12:47 PM, Jamie Iles wrote:
What SPI controller are you using? I've seen a similar issue with the
Synopsys DesignWare SPI controller where the controller manages the chip
select itself, and once the FIFO is emptied the CS goes away, but the
flash chip requires it to stay high
Hello,
Following is what i understood after reading m25p80 driver and spi master
drivers in drivers/spi folder.
chip_select signal controls start and end of transfer. For ex: if we have to
read
status reg of spi memory, then we use write_and_then_read() routine. which
writes
0x9F in one spi
clk_freq is used uninitialized in pl022_setup routine. This patch
fix compilation warning for using uninitialized variable
Signed-off-by: Viresh Kumar viresh.ku...@st.com
---
drivers/spi/amba-pl022.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/spi/amba-pl022
57 matches
Mail list logo