From 709c4d66e0b107ca606941b988bad717c0b45d9b Mon Sep 17 00:00:00 2001
From: Denys Dmytriyenko <denis@denix.org>
Date: Tue, 17 Mar 2009 14:32:59 -0400
Subject: rename packages/ to recipes/ per earlier agreement

See links below for more details:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816

Signed-off-by: Denys Dmytriyenko <denis@denix.org>
Acked-by: Mike Westerhof <mwester@dls.net>
Acked-by: Philip Balister <philip@balister.org>
Acked-by: Khem Raj <raj.khem@gmail.com>
Acked-by: Marcin Juszkiewicz <hrw@openembedded.org>
Acked-by: Koen Kooi <koen@openembedded.org>
Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
---
 ...el_spi-send-zeroes-when-tx_buf-is-not-set.patch | 48 ++++++++++++++++++++++
 1 file changed, 48 insertions(+)
 create mode 100644 recipes/linux/linux-2.6.18/atmel_spi-send-zeroes-when-tx_buf-is-not-set.patch

(limited to 'recipes/linux/linux-2.6.18/atmel_spi-send-zeroes-when-tx_buf-is-not-set.patch')

diff --git a/recipes/linux/linux-2.6.18/atmel_spi-send-zeroes-when-tx_buf-is-not-set.patch b/recipes/linux/linux-2.6.18/atmel_spi-send-zeroes-when-tx_buf-is-not-set.patch
new file mode 100644
index 0000000000..0cf703d3df
--- /dev/null
+++ b/recipes/linux/linux-2.6.18/atmel_spi-send-zeroes-when-tx_buf-is-not-set.patch
@@ -0,0 +1,48 @@
+From e9bce56d6d8913505049cde45d800bb69943f166 Mon Sep 17 00:00:00 2001
+From: Nicolas Ferre <nicolas.ferre@rfo.atmel.com>
+Date: Tue, 16 Jan 2007 15:15:36 +0100
+Subject: [ATMEL SPI] Send zeroes when tx_buf is not set
+
+send zeros when tx_buf is not set (according to the new spi
+specification by D.Brownell) cf.
+  http://lkml.org/lkml/2006/12/22/171
+  http://kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4b1badf5d9ddfc46ad075ca5bfc465972c85cc7c
+
+Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
+---
+ drivers/spi/atmel_spi.c |   21 ++++++++++-----------
+ 1 file changed, 10 insertions(+), 11 deletions(-)
+
+Index: linux-2.6.18-avr32/drivers/spi/atmel_spi.c
+===================================================================
+--- linux-2.6.18-avr32.orig/drivers/spi/atmel_spi.c	2007-01-16 18:20:06.000000000 +0100
++++ linux-2.6.18-avr32/drivers/spi/atmel_spi.c	2007-01-16 18:20:57.000000000 +0100
+@@ -120,18 +120,17 @@ static void atmel_spi_next_xfer(struct s
+ 			len = BUFFER_SIZE;
+ 	}
+ 	if (tx_dma == INVALID_DMA_ADDRESS) {
+-		if (xfer->tx_buf) {
+-			tx_dma = as->buffer_dma;
+-			if (len > BUFFER_SIZE)
+-				len = BUFFER_SIZE;
++		tx_dma = as->buffer_dma;
++		if (len > BUFFER_SIZE)
++			len = BUFFER_SIZE;
++		if (xfer->tx_buf)
+ 			memcpy(as->buffer, xfer->tx_buf, len);
+-			dma_sync_single_for_device(&as->pdev->dev,
+-						   as->buffer_dma, len,
+-						   DMA_TO_DEVICE);
+-		} else {
+-			/* Send undefined data; rx_dma is handy */
+-			tx_dma = rx_dma;
+-		}
++		else
++			/* no tx data: send zeros */
++			memset(as->buffer, 0, len);
++		dma_sync_single_for_device(&as->pdev->dev,
++					   as->buffer_dma, len,
++					   DMA_TO_DEVICE);
+ 	}
+ 
+ 	spi_writel(as, RPR, rx_dma);
-- 
cgit v1.2.3