[SPAM] Is Your Wedge Obsolete?

2012-09-14 Thread Andy North
Do you want to play golf better? Is your wedge obsolete? 
We are so convinced that our F2 Wedge will allow you to play the best golf 
ever, that we guarantee it.

**View the attached brochure to get more info on this radical wedge**

I am convinced you can not shank this F2 wedge. This wedge will make the rest 
obsolete.

It wont hurt to check it out.

Andy North
2-Time US Open Champion
** View the attachment **

























Click This Link to Stop Future Messages 
mailto:listservi...@gmx.com?subject=unsubscribe%3a%20spi-devel-gene...@lists.sourceforge.net

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Nouveautés BEST OF jusqu'à -40%

2012-09-14 Thread 3Suisses par Duano
Pour voir le message, veuillez utiliser un lecteur de mail compatible HTML

Lien miroir : 
http://m10-fr.com/mc10_m/YT0xMyZiPTE5OTk4JmM9NDgzNjEyJmQ9MjAxMi0wOS0xNCAxMjowMDowMSZlPTEmaD0xOTk5NyZmPTE5OTk4Jmc9MTk5OTg=

Lien de désinscription : 
http://m10-fr.com/mc10_unsub/YT0xMyZiPTE5OTk4JmM9NDgzNjEyJmQ9MjAxMi0wOS0xNCAxMjowMDowMSZlPTEmaD0xOTk5NyZmPTE5OTk4Jmc9MTk5OTg=


--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Mark Brown
On Thu, Sep 13, 2012 at 05:36:30PM -0600, Stephen Warren wrote:

 Please note that I've applied this to Tegra's for-3.7/dmaengine branch,
 even though it hasn't been ack'd by an ASoC maintainer.

Please don't apply this without review, we've got quite enough problems
with the dmaengine stuff as it is unfortunately so I want to keep a
handle on what's going on.  I didn't look at it since when it was
originally posted people found problems in testing so I was expecting a
respin of the series.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 4/5] spi: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Mark Brown
On Thu, Sep 06, 2012 at 05:50:07PM -0600, Stephen Warren wrote:
 On 08/16/2012 08:13 AM, Laxman Dewangan wrote:

  Remove the support code which uses the legacy APB DMA driver
  for accessing the SPI FIFO.
  The driver will use the dmaengine based APB DMA driver for
  accessing reqding/writing to SPI FIFO.

 I'd like to take this patch through the Tegra tree, since it relies on
 the previous Tegra patches to convert to dmaengine. Could I please get
 an ack if that's OK? Thanks.

I don't seem to have the patch for review, not sure why.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
On 09/06/2012 05:50 PM, Stephen Warren wrote:
 On 08/16/2012 08:13 AM, Laxman Dewangan wrote:
 Remove the support code which uses the legacy APB DMA driver
 for accessing the I2S FIFO.
 The driver will use the dmaengine based APB DMA driver for
 accessing reqding/writing to I2S FIFO.

 Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
 
 Mark, Liam,
 
 I'd like to take this patch through the Tegra tree, since it relies on
 the previous Tegra patches to convert to dmaengine. Could I please get
 an ack if that's OK? Thanks.

I'm still looking for an ack.


--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 4/5] spi: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
On 09/06/2012 05:50 PM, Stephen Warren wrote:
 On 08/16/2012 08:13 AM, Laxman Dewangan wrote:
 Remove the support code which uses the legacy APB DMA driver
 for accessing the SPI FIFO.
 The driver will use the dmaengine based APB DMA driver for
 accessing reqding/writing to SPI FIFO.

 Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
 
 Grant, Mark,
 
 I'd like to take this patch through the Tegra tree, since it relies on
 the previous Tegra patches to convert to dmaengine. Could I please get
 an ack if that's OK? Thanks.

I'm still looking for an ack.


--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
On 09/14/2012 09:53 AM, Mark Brown wrote:
 On Thu, Sep 13, 2012 at 05:36:30PM -0600, Stephen Warren wrote:
 
 Please note that I've applied this to Tegra's for-3.7/dmaengine branch,
 even though it hasn't been ack'd by an ASoC maintainer.
 
 Please don't apply this without review, we've got quite enough problems
 with the dmaengine stuff as it is unfortunately so I want to keep a
 handle on what's going on.  I didn't look at it since when it was
 originally posted people found problems in testing so I was expecting a
 respin of the series.

OK, I'll remove the series from next then.

But do note that I pinged 8 days ago for an ack, and received no
objections, and you were well aware that the bug was fixed since you
applied the fix to the Tegra ASoC PCM driver yourself, and we had
discussed this being a dependency for the dmaengine patches, and you'd
told me to just base the Tegra branch on top of your tree until a signed
tag was available for me to base upon.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 4/5] spi: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Mark Brown
On Fri, Sep 14, 2012 at 09:57:48AM -0600, Stephen Warren wrote:
 On 09/06/2012 05:50 PM, Stephen Warren wrote:

  I'd like to take this patch through the Tegra tree, since it relies on
  the previous Tegra patches to convert to dmaengine. Could I please get
  an ack if that's OK? Thanks.

 I'm still looking for an ack.

Again, I don't have this patch.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCH 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Mark Brown
On Fri, Sep 14, 2012 at 09:57:35AM -0600, Stephen Warren wrote:
 On 09/06/2012 05:50 PM, Stephen Warren wrote:

  I'd like to take this patch through the Tegra tree, since it relies on
  the previous Tegra patches to convert to dmaengine. Could I please get
  an ack if that's OK? Thanks.

 I'm still looking for an ack.

As with all the others here I need to see this so it can get reviewed,
the previous review was that the patch didn't work.  In general
contentless pings like this aren't terribly helpful...

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


[PATCH RESEND 1/5] ARM: tegra: config: enable dmaengine based APB DMA driver

2012-09-14 Thread Stephen Warren
From: Laxman Dewangan ldewan...@nvidia.com

Enable config for dmaengine based Tegra APB DMA driver and
disable the legacy APB DMA driver (SYSTEM_DMA).

Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
Signed-off-by: Stephen Warren swar...@nvidia.com
---
I'm looking for Ack's on patches 4 and 5 from the SPI and ASoC maintainers
respectively, so that I can take this series through the Tegra tree for 3.7.

When this series was first posted, there was a bug in the Tegra ASoC PCM
driver which prevented it from working. A fix for this has since been
applied to ASoC's for-3.6 branch and hence should show up in 3.6.

 arch/arm/configs/tegra_defconfig |3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/arch/arm/configs/tegra_defconfig b/arch/arm/configs/tegra_defconfig
index adcf3c2..2990396 100644
--- a/arch/arm/configs/tegra_defconfig
+++ b/arch/arm/configs/tegra_defconfig
@@ -29,6 +29,7 @@ CONFIG_ARCH_TEGRA_2x_SOC=y
 CONFIG_ARCH_TEGRA_3x_SOC=y
 CONFIG_TEGRA_PCI=y
 CONFIG_TEGRA_DEBUG_UART_AUTO_ODMDATA=y
+# CONFIG_TEGRA_SYSTEM_DMA is not set
 CONFIG_TEGRA_EMC_SCALING_ENABLE=y
 CONFIG_SMP=y
 CONFIG_PREEMPT=y
@@ -175,6 +176,8 @@ CONFIG_RTC_DRV_MAX8907=y
 CONFIG_RTC_DRV_TPS65910=y
 CONFIG_RTC_DRV_EM3027=y
 CONFIG_RTC_DRV_TEGRA=y
+CONFIG_DMADEVICES=y
+CONFIG_TEGRA20_APB_DMA=y
 CONFIG_STAGING=y
 CONFIG_SENSORS_ISL29018=y
 CONFIG_SENSORS_ISL29028=y
-- 
1.7.0.4


--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


[PATCH RESEND 3/5] ARM: tegra: apbio: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
From: Laxman Dewangan ldewan...@nvidia.com

Remove the support code which uses the legacy APB DMA driver
for accessing the apbio register.
The driver will use the dmaengine based APB DMA driver for
accessing apbio register.

Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
Signed-off-by: Stephen Warren swar...@nvidia.com
---
 arch/arm/mach-tegra/apbio.c |  118 +--
 1 files changed, 1 insertions(+), 117 deletions(-)

diff --git a/arch/arm/mach-tegra/apbio.c b/arch/arm/mach-tegra/apbio.c
index 643a378..b5015d0 100644
--- a/arch/arm/mach-tegra/apbio.c
+++ b/arch/arm/mach-tegra/apbio.c
@@ -28,7 +28,7 @@
 
 #include apbio.h
 
-#if defined(CONFIG_TEGRA_SYSTEM_DMA) || defined(CONFIG_TEGRA20_APB_DMA)
+#if defined(CONFIG_TEGRA20_APB_DMA)
 static DEFINE_MUTEX(tegra_apb_dma_lock);
 static u32 *tegra_apb_bb;
 static dma_addr_t tegra_apb_bb_phys;
@@ -37,121 +37,6 @@ static DECLARE_COMPLETION(tegra_apb_wait);
 static u32 tegra_apb_readl_direct(unsigned long offset);
 static void tegra_apb_writel_direct(u32 value, unsigned long offset);
 
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-static struct tegra_dma_channel *tegra_apb_dma;
-
-bool tegra_apb_init(void)
-{
-   struct tegra_dma_channel *ch;
-
-   mutex_lock(tegra_apb_dma_lock);
-
-   /* Check to see if we raced to setup */
-   if (tegra_apb_dma)
-   goto out;
-
-   ch = tegra_dma_allocate_channel(TEGRA_DMA_MODE_ONESHOT |
-   TEGRA_DMA_SHARED);
-
-   if (!ch)
-   goto out_fail;
-
-   tegra_apb_bb = dma_alloc_coherent(NULL, sizeof(u32),
-   tegra_apb_bb_phys, GFP_KERNEL);
-   if (!tegra_apb_bb) {
-   pr_err(%s: can not allocate bounce buffer\n, __func__);
-   tegra_dma_free_channel(ch);
-   goto out_fail;
-   }
-
-   tegra_apb_dma = ch;
-out:
-   mutex_unlock(tegra_apb_dma_lock);
-   return true;
-
-out_fail:
-   mutex_unlock(tegra_apb_dma_lock);
-   return false;
-}
-
-static void apb_dma_complete(struct tegra_dma_req *req)
-{
-   complete(tegra_apb_wait);
-}
-
-static u32 tegra_apb_readl_using_dma(unsigned long offset)
-{
-   struct tegra_dma_req req;
-   int ret;
-
-   if (!tegra_apb_dma  !tegra_apb_init())
-   return tegra_apb_readl_direct(offset);
-
-   mutex_lock(tegra_apb_dma_lock);
-   req.complete = apb_dma_complete;
-   req.to_memory = 1;
-   req.dest_addr = tegra_apb_bb_phys;
-   req.dest_bus_width = 32;
-   req.dest_wrap = 1;
-   req.source_addr = offset;
-   req.source_bus_width = 32;
-   req.source_wrap = 4;
-   req.req_sel = TEGRA_DMA_REQ_SEL_CNTR;
-   req.size = 4;
-
-   INIT_COMPLETION(tegra_apb_wait);
-
-   tegra_dma_enqueue_req(tegra_apb_dma, req);
-
-   ret = wait_for_completion_timeout(tegra_apb_wait,
-   msecs_to_jiffies(50));
-
-   if (WARN(ret == 0, apb read dma timed out)) {
-   tegra_dma_dequeue_req(tegra_apb_dma, req);
-   *(u32 *)tegra_apb_bb = 0;
-   }
-
-   mutex_unlock(tegra_apb_dma_lock);
-   return *((u32 *)tegra_apb_bb);
-}
-
-static void tegra_apb_writel_using_dma(u32 value, unsigned long offset)
-{
-   struct tegra_dma_req req;
-   int ret;
-
-   if (!tegra_apb_dma  !tegra_apb_init()) {
-   tegra_apb_writel_direct(value, offset);
-   return;
-   }
-
-   mutex_lock(tegra_apb_dma_lock);
-   *((u32 *)tegra_apb_bb) = value;
-   req.complete = apb_dma_complete;
-   req.to_memory = 0;
-   req.dest_addr = offset;
-   req.dest_wrap = 4;
-   req.dest_bus_width = 32;
-   req.source_addr = tegra_apb_bb_phys;
-   req.source_bus_width = 32;
-   req.source_wrap = 1;
-   req.req_sel = TEGRA_DMA_REQ_SEL_CNTR;
-   req.size = 4;
-
-   INIT_COMPLETION(tegra_apb_wait);
-
-   tegra_dma_enqueue_req(tegra_apb_dma, req);
-
-   ret = wait_for_completion_timeout(tegra_apb_wait,
-   msecs_to_jiffies(50));
-
-   if (WARN(ret == 0, apb write dma timed out))
-   tegra_dma_dequeue_req(tegra_apb_dma, req);
-
-   mutex_unlock(tegra_apb_dma_lock);
-}
-
-#else
 static struct dma_chan *tegra_apb_dma_chan;
 static struct dma_slave_config dma_sconfig;
 
@@ -279,7 +164,6 @@ static void tegra_apb_writel_using_dma(u32 value, unsigned 
long offset)
pr_err(error in writing offset 0x%08lx using dma\n, offset);
mutex_unlock(tegra_apb_dma_lock);
 }
-#endif
 #else
 #define tegra_apb_readl_using_dma tegra_apb_readl_direct
 #define tegra_apb_writel_using_dma tegra_apb_writel_direct
-- 
1.7.0.4


--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html

[PATCH RESEND 4/5] spi: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
From: Laxman Dewangan ldewan...@nvidia.com

Remove the support code which uses the legacy APB DMA driver
for accessing the SPI FIFO.
The driver will use the dmaengine based APB DMA driver for
accessing reqding/writing to SPI FIFO.

Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
Signed-off-by: Stephen Warren swar...@nvidia.com
---
 drivers/spi/Kconfig |2 +-
 drivers/spi/spi-tegra.c |   55 +--
 2 files changed, 2 insertions(+), 55 deletions(-)

diff --git a/drivers/spi/Kconfig b/drivers/spi/Kconfig
index 76631d0..323ea8f 100644
--- a/drivers/spi/Kconfig
+++ b/drivers/spi/Kconfig
@@ -387,7 +387,7 @@ config SPI_MXS
 
 config SPI_TEGRA
tristate Nvidia Tegra SPI controller
-   depends on ARCH_TEGRA  (TEGRA_SYSTEM_DMA || TEGRA20_APB_DMA)
+   depends on ARCH_TEGRA  TEGRA20_APB_DMA
help
  SPI driver for NVidia Tegra SoCs
 
diff --git a/drivers/spi/spi-tegra.c b/drivers/spi/spi-tegra.c
index e28445d..f900506 100644
--- a/drivers/spi/spi-tegra.c
+++ b/drivers/spi/spi-tegra.c
@@ -164,23 +164,15 @@ struct spi_tegra_data {
 * for the generic case.
 */
int dma_req_len;
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-   struct tegra_dma_reqrx_dma_req;
-   struct tegra_dma_channel *rx_dma;
-#else
struct dma_chan *rx_dma;
struct dma_slave_config sconfig;
struct dma_async_tx_descriptor  *rx_dma_desc;
dma_cookie_trx_cookie;
-#endif
u32 *rx_bb;
dma_addr_t  rx_bb_phys;
 };
 
-#if !defined(CONFIG_TEGRA_SYSTEM_DMA)
 static void tegra_spi_rx_dma_complete(void *args);
-#endif
-
 static inline unsigned long spi_tegra_readl(struct spi_tegra_data *tspi,
unsigned long reg)
 {
@@ -204,10 +196,6 @@ static void spi_tegra_go(struct spi_tegra_data *tspi)
val = ~SLINK_DMA_BLOCK_SIZE(~0)  ~SLINK_DMA_EN;
val |= SLINK_DMA_BLOCK_SIZE(tspi-dma_req_len / 4 - 1);
spi_tegra_writel(tspi, val, SLINK_DMA_CTL);
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-   tspi-rx_dma_req.size = tspi-dma_req_len;
-   tegra_dma_enqueue_req(tspi-rx_dma, tspi-rx_dma_req);
-#else
tspi-rx_dma_desc = dmaengine_prep_slave_single(tspi-rx_dma,
tspi-rx_bb_phys, tspi-dma_req_len,
DMA_DEV_TO_MEM, DMA_PREP_INTERRUPT);
@@ -219,7 +207,6 @@ static void spi_tegra_go(struct spi_tegra_data *tspi)
tspi-rx_dma_desc-callback_param = tspi;
tspi-rx_cookie = dmaengine_submit(tspi-rx_dma_desc);
dma_async_issue_pending(tspi-rx_dma);
-#endif
 
val |= SLINK_DMA_EN;
spi_tegra_writel(tspi, val, SLINK_DMA_CTL);
@@ -405,19 +392,12 @@ static void handle_spi_rx_dma_complete(struct 
spi_tegra_data *tspi)
 
spin_unlock_irqrestore(tspi-lock, flags);
 }
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-static void tegra_spi_rx_dma_complete(struct tegra_dma_req *req)
-{
-   struct spi_tegra_data *tspi = req-dev;
-   handle_spi_rx_dma_complete(tspi);
-}
-#else
+
 static void tegra_spi_rx_dma_complete(void *args)
 {
struct spi_tegra_data *tspi = args;
handle_spi_rx_dma_complete(tspi);
 }
-#endif
 
 static int spi_tegra_setup(struct spi_device *spi)
 {
@@ -509,9 +489,7 @@ static int __devinit spi_tegra_probe(struct platform_device 
*pdev)
struct spi_tegra_data   *tspi;
struct resource *r;
int ret;
-#if !defined(CONFIG_TEGRA_SYSTEM_DMA)
dma_cap_mask_t mask;
-#endif
 
master = spi_alloc_master(pdev-dev, sizeof *tspi);
if (master == NULL) {
@@ -563,14 +541,6 @@ static int __devinit spi_tegra_probe(struct 
platform_device *pdev)
 
INIT_LIST_HEAD(tspi-queue);
 
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-   tspi-rx_dma = tegra_dma_allocate_channel(TEGRA_DMA_MODE_ONESHOT);
-   if (!tspi-rx_dma) {
-   dev_err(pdev-dev, can not allocate rx dma channel\n);
-   ret = -ENODEV;
-   goto err3;
-   }
-#else
dma_cap_zero(mask);
dma_cap_set(DMA_SLAVE, mask);
tspi-rx_dma = dma_request_channel(mask, NULL, NULL);
@@ -580,8 +550,6 @@ static int __devinit spi_tegra_probe(struct platform_device 
*pdev)
goto err3;
}
 
-#endif
-
tspi-rx_bb = dma_alloc_coherent(pdev-dev, sizeof(u32) * BB_LEN,
 tspi-rx_bb_phys, GFP_KERNEL);
if (!tspi-rx_bb) {
@@ -590,17 +558,6 @@ static int __devinit spi_tegra_probe(struct 
platform_device *pdev)
goto err4;
}
 
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-   tspi-rx_dma_req.complete = tegra_spi_rx_dma_complete;
-   tspi-rx_dma_req.to_memory = 1;
-   tspi-rx_dma_req.dest_addr = tspi-rx_bb_phys;
-   tspi-rx_dma_req.dest_bus_width = 32;
-   tspi-rx_dma_req.source_addr = tspi-phys + SLINK_RX_FIFO;
-   

[PATCH RESEND 2/5] ARM: tegra: dma: remove legacy APB DMA driver

2012-09-14 Thread Stephen Warren
From: Laxman Dewangan ldewan...@nvidia.com

Remove the legacy APB dma driver. The APB DMA support
is moved to dmaengine based Tegra APB DMA driver.
All clients are also moved to dmaengine based APB DMA
driver.

Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
Signed-off-by: Stephen Warren swar...@nvidia.com
---
 arch/arm/mach-tegra/Kconfig|7 -
 arch/arm/mach-tegra/Makefile   |1 -
 arch/arm/mach-tegra/dma.c  |  822 
 arch/arm/mach-tegra/include/mach/dma.h |   97 
 4 files changed, 0 insertions(+), 927 deletions(-)
 delete mode 100644 arch/arm/mach-tegra/dma.c

diff --git a/arch/arm/mach-tegra/Kconfig b/arch/arm/mach-tegra/Kconfig
index b3226f8..5f3c03b 100644
--- a/arch/arm/mach-tegra/Kconfig
+++ b/arch/arm/mach-tegra/Kconfig
@@ -110,13 +110,6 @@ config TEGRA_DEBUG_UART_AUTO_SCRATCH
 
 endchoice
 
-config TEGRA_SYSTEM_DMA
-   bool Enable system DMA driver for NVIDIA Tegra SoCs
-   default y
-   help
- Adds system DMA functionality for NVIDIA Tegra SoCs, used by
- several Tegra device drivers
-
 config TEGRA_EMC_SCALING_ENABLE
bool Enable scaling the memory frequency
 
diff --git a/arch/arm/mach-tegra/Makefile b/arch/arm/mach-tegra/Makefile
index a5cd6c1..9aa653b 100644
--- a/arch/arm/mach-tegra/Makefile
+++ b/arch/arm/mach-tegra/Makefile
@@ -20,7 +20,6 @@ obj-$(CONFIG_ARCH_TEGRA_3x_SOC)   += sleep-t30.o
 obj-$(CONFIG_SMP)  += platsmp.o headsmp.o
 obj-$(CONFIG_SMP)   += reset.o
 obj-$(CONFIG_HOTPLUG_CPU)   += hotplug.o
-obj-$(CONFIG_TEGRA_SYSTEM_DMA) += dma.o
 obj-$(CONFIG_CPU_FREQ)  += cpu-tegra.o
 obj-$(CONFIG_TEGRA_PCI)+= pcie.o
 
diff --git a/arch/arm/mach-tegra/dma.c b/arch/arm/mach-tegra/dma.c
deleted file mode 100644
index 7f27320..000
--- a/arch/arm/mach-tegra/dma.c
+++ /dev/null
@@ -1,822 +0,0 @@
-/*
- * arch/arm/mach-tegra/dma.c
- *
- * System DMA driver for NVIDIA Tegra SoCs
- *
- * Copyright (c) 2008-2009, NVIDIA Corporation.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
- * more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
- */
-
-#include linux/io.h
-#include linux/interrupt.h
-#include linux/module.h
-#include linux/spinlock.h
-#include linux/err.h
-#include linux/irq.h
-#include linux/delay.h
-#include linux/clk.h
-#include mach/dma.h
-#include mach/irqs.h
-#include mach/iomap.h
-
-#include apbio.h
-
-#define APB_DMA_GEN0x000
-#define GEN_ENABLE (131)
-
-#define APB_DMA_CNTRL  0x010
-
-#define APB_DMA_IRQ_MASK   0x01c
-
-#define APB_DMA_IRQ_MASK_SET   0x020
-
-#define APB_DMA_CHAN_CSR   0x000
-#define CSR_ENB(131)
-#define CSR_IE_EOC (130)
-#define CSR_HOLD   (129)
-#define CSR_DIR(128)
-#define CSR_ONCE   (127)
-#define CSR_FLOW   (121)
-#define CSR_REQ_SEL_SHIFT  16
-#define CSR_WCOUNT_SHIFT   2
-#define CSR_WCOUNT_MASK0xFFFC
-
-#define APB_DMA_CHAN_STA   0x004
-#define STA_BUSY   (131)
-#define STA_ISE_EOC(130)
-#define STA_HALT   (129)
-#define STA_PING_PONG  (128)
-#define STA_COUNT_SHIFT2
-#define STA_COUNT_MASK 0xFFFC
-
-#define APB_DMA_CHAN_AHB_PTR   0x010
-
-#define APB_DMA_CHAN_AHB_SEQ   0x014
-#define AHB_SEQ_INTR_ENB   (131)
-#define AHB_SEQ_BUS_WIDTH_SHIFT28
-#define AHB_SEQ_BUS_WIDTH_MASK (0x7AHB_SEQ_BUS_WIDTH_SHIFT)
-#define AHB_SEQ_BUS_WIDTH_8(0AHB_SEQ_BUS_WIDTH_SHIFT)
-#define AHB_SEQ_BUS_WIDTH_16   (1AHB_SEQ_BUS_WIDTH_SHIFT)
-#define AHB_SEQ_BUS_WIDTH_32   (2AHB_SEQ_BUS_WIDTH_SHIFT)
-#define AHB_SEQ_BUS_WIDTH_64   (3AHB_SEQ_BUS_WIDTH_SHIFT)
-#define AHB_SEQ_BUS_WIDTH_128 

[PATCH RESEND 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Stephen Warren
From: Laxman Dewangan ldewan...@nvidia.com

Remove the support code which uses the legacy APB DMA driver
for accessing the I2S FIFO.
The driver will use the dmaengine based APB DMA driver for
accessing reqding/writing to I2S FIFO.

Signed-off-by: Laxman Dewangan ldewan...@nvidia.com
Signed-off-by: Stephen Warren swar...@nvidia.com
---
 sound/soc/tegra/Kconfig |2 +-
 sound/soc/tegra/tegra_pcm.c |  232 ---
 sound/soc/tegra/tegra_pcm.h |   14 ---
 3 files changed, 1 insertions(+), 247 deletions(-)

diff --git a/sound/soc/tegra/Kconfig b/sound/soc/tegra/Kconfig
index 02bcd30..19e5fe7 100644
--- a/sound/soc/tegra/Kconfig
+++ b/sound/soc/tegra/Kconfig
@@ -1,6 +1,6 @@
 config SND_SOC_TEGRA
tristate SoC Audio for the Tegra System-on-Chip
-   depends on ARCH_TEGRA  (TEGRA_SYSTEM_DMA || TEGRA20_APB_DMA)
+   depends on ARCH_TEGRA  TEGRA20_APB_DMA
select REGMAP_MMIO
select SND_SOC_DMAENGINE_PCM if TEGRA20_APB_DMA
help
diff --git a/sound/soc/tegra/tegra_pcm.c b/sound/soc/tegra/tegra_pcm.c
index 8d6900c..e187339 100644
--- a/sound/soc/tegra/tegra_pcm.c
+++ b/sound/soc/tegra/tegra_pcm.c
@@ -57,237 +57,6 @@ static const struct snd_pcm_hardware tegra_pcm_hardware = {
.fifo_size  = 4,
 };
 
-#if defined(CONFIG_TEGRA_SYSTEM_DMA)
-static void tegra_pcm_queue_dma(struct tegra_runtime_data *prtd)
-{
-   struct snd_pcm_substream *substream = prtd-substream;
-   struct snd_dma_buffer *buf = substream-dma_buffer;
-   struct tegra_dma_req *dma_req;
-   unsigned long addr;
-
-   dma_req = prtd-dma_req[prtd-dma_req_idx];
-   prtd-dma_req_idx = 1 - prtd-dma_req_idx;
-
-   addr = buf-addr + prtd-dma_pos;
-   prtd-dma_pos += dma_req-size;
-   if (prtd-dma_pos = prtd-dma_pos_end)
-   prtd-dma_pos = 0;
-
-   if (substream-stream == SNDRV_PCM_STREAM_PLAYBACK)
-   dma_req-source_addr = addr;
-   else
-   dma_req-dest_addr = addr;
-
-   tegra_dma_enqueue_req(prtd-dma_chan, dma_req);
-}
-
-static void dma_complete_callback(struct tegra_dma_req *req)
-{
-   struct tegra_runtime_data *prtd = (struct tegra_runtime_data *)req-dev;
-   struct snd_pcm_substream *substream = prtd-substream;
-   struct snd_pcm_runtime *runtime = substream-runtime;
-
-   spin_lock(prtd-lock);
-
-   if (!prtd-running) {
-   spin_unlock(prtd-lock);
-   return;
-   }
-
-   if (++prtd-period_index = runtime-periods)
-   prtd-period_index = 0;
-
-   tegra_pcm_queue_dma(prtd);
-
-   spin_unlock(prtd-lock);
-
-   snd_pcm_period_elapsed(substream);
-}
-
-static void setup_dma_tx_request(struct tegra_dma_req *req,
-   struct tegra_pcm_dma_params * dmap)
-{
-   req-complete = dma_complete_callback;
-   req-to_memory = false;
-   req-dest_addr = dmap-addr;
-   req-dest_wrap = dmap-wrap;
-   req-source_bus_width = 32;
-   req-source_wrap = 0;
-   req-dest_bus_width = dmap-width;
-   req-req_sel = dmap-req_sel;
-}
-
-static void setup_dma_rx_request(struct tegra_dma_req *req,
-   struct tegra_pcm_dma_params * dmap)
-{
-   req-complete = dma_complete_callback;
-   req-to_memory = true;
-   req-source_addr = dmap-addr;
-   req-dest_wrap = 0;
-   req-source_bus_width = dmap-width;
-   req-source_wrap = dmap-wrap;
-   req-dest_bus_width = 32;
-   req-req_sel = dmap-req_sel;
-}
-
-static int tegra_pcm_open(struct snd_pcm_substream *substream)
-{
-   struct snd_pcm_runtime *runtime = substream-runtime;
-   struct tegra_runtime_data *prtd;
-   struct snd_soc_pcm_runtime *rtd = substream-private_data;
-   struct tegra_pcm_dma_params * dmap;
-   int ret = 0;
-
-   prtd = kzalloc(sizeof(struct tegra_runtime_data), GFP_KERNEL);
-   if (prtd == NULL)
-   return -ENOMEM;
-
-   runtime-private_data = prtd;
-   prtd-substream = substream;
-
-   spin_lock_init(prtd-lock);
-
-   if (substream-stream == SNDRV_PCM_STREAM_PLAYBACK) {
-   dmap = snd_soc_dai_get_dma_data(rtd-cpu_dai, substream);
-   setup_dma_tx_request(prtd-dma_req[0], dmap);
-   setup_dma_tx_request(prtd-dma_req[1], dmap);
-   } else {
-   dmap = snd_soc_dai_get_dma_data(rtd-cpu_dai, substream);
-   setup_dma_rx_request(prtd-dma_req[0], dmap);
-   setup_dma_rx_request(prtd-dma_req[1], dmap);
-   }
-
-   prtd-dma_req[0].dev = prtd;
-   prtd-dma_req[1].dev = prtd;
-
-   prtd-dma_chan = tegra_dma_allocate_channel(TEGRA_DMA_MODE_ONESHOT);
-   if (prtd-dma_chan == NULL) {
-   ret = -ENOMEM;
-   goto err;
-   }
-
-   /* Set HW params now that initialization is complete */
-   snd_soc_set_runtime_hwparams(substream, tegra_pcm_hardware);
-
-   /* Ensure 

Re: [PATCH 5/5] ASoC: tegra: remove support of legacy DMA driver based access

2012-09-14 Thread Mark Brown
On Fri, Sep 14, 2012 at 10:00:39AM -0600, Stephen Warren wrote:

 But do note that I pinged 8 days ago for an ack, and received no
 objections, and you were well aware that the bug was fixed since you

I didn't read these mails enough to notice that they were asking for an
ack, they were followups to already discarded patches (the were
discarded due to the testing problems).  One of the things I do to deal
with mail overload is to drop followups to patches that I don't remember
reviewing (as in this case where the negative test reports arrived
before I saw the patches) or where I remember I was already happy.

 applied the fix to the Tegra ASoC PCM driver yourself, and we had
 discussed this being a dependency for the dmaengine patches, and you'd
 told me to just base the Tegra branch on top of your tree until a signed
 tag was available for me to base upon.

I knew it was a dependency, I didn't know that there were no further
changes required to the series - your note when you posted the patch
didn't mention anything.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general


Re: [PATCHSET] kthread_worker: reimplement flush_kthread_work() to allow freeing during execution

2012-09-14 Thread Colin Cross
On Thu, Jul 19, 2012 at 2:15 PM, Tejun Heo t...@kernel.org wrote:
 Hello,

 kthread_worker was introduced together with concurrency managed
 workqueue to serve workqueue users which need a special dedicated
 worker - e.g. RT scheduling.  This is minimal queue / flush / flush
 all iterface on top of kthread and each provided interface matches the
 workqueue counterpart so that switching isn't difficult.

 However, one noticeable difference was that kthread_worker doesn't
 allow a work item to be freed while being executed.  The intention was
 to keep the code simpler but it didn't really and the restriction is
 subtle and does prevent some valid use cases.

 This two-patch series reimplements flush_kthread_work() so that it
 uses an extra work item for flushing.  While this takes a bit more
 lines, this is easier to understand and removes the annoying
 difference.

 This patchset contains the following two patches.

  0001-kthread_worker-reorganize-to-prepare-for-flush_kthre.patch
  0002-kthread_worker-reimplement-flush_kthread_work-to-all.patch

 The first one is a prep patch which makes no functional changes.  The
 second reimplements flush_kthread_work().

 All current kthread_worker users are cc'd.  If no one objects, I'll
 push it through the workqueue branch.  This patchset is also available
 in the following git branch.

  git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq.git 
 review-kthread_worker-flush

 diffstat follows.  Thanks.

  include/linux/kthread.h |8 +---
  kernel/kthread.c|   86 
 +++-
  2 files changed, 52 insertions(+), 42 deletions(-)

 --
 tejun

This patch set fixes a reproducible crash I'm seeing on a 3.4.10
kernel.  flush_kthread_worker (which is different from
flush_kthread_work) is initializing a kthread_work and a completion on
the stack, then queuing it and calling wait_for_completion.  Once the
completion is signaled, flush_kthread_worker exits and the stack
region used by the kthread_work may be immediately reused by another
object on the stack, but kthread_worker_fn continues accessing its
work pointer:
work-func(work); - calls complete,
effectively frees work
smp_wmb();  /* wmb worker-b0 paired with flush-b1 */
work-done_seq = work-queue_seq;   - overwrites a
new stack object
smp_mb();   /* mb worker-b1 paired with flush-b0 */
if (atomic_read(work-flushing))
wake_up_all(work-done);  - or crashes here

These patches fix the problem by not accessing work after work-func
is called, and should be backported to stable.  They apply cleanly to
3.4.10.  Upstream commits are 9a2e03d8ed518a61154f18d83d6466628e519f94
and 46f3d976213452350f9d10b0c2780c2681f7075b.

--
Got visibility?
Most devs has no idea what their production app looks like.
Find out how fast your code is with AppDynamics Lite.
http://ad.doubleclick.net/clk;262219671;13503038;y?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
___
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general