public inbox for ecos-patches@sourceware.org
 help / color / mirror / Atom feed
* STM32 SPI driver fix
@ 2009-08-24  8:43 Simon Kallweit
  2009-08-26  9:45 ` Nick Garnett
  0 siblings, 1 reply; 2+ messages in thread
From: Simon Kallweit @ 2009-08-24  8:43 UTC (permalink / raw)
  To: ecos-patches

[-- Attachment #1: Type: text/plain, Size: 148 bytes --]

This is a little fix for the STM32 SPI driver. It initializes 
spi_cr1_val with zero (as stated in the comments) and adds the testcase 
to the CDL.

[-- Attachment #2: spi_stm32_fix.patch --]
[-- Type: text/x-patch, Size: 1998 bytes --]

From: Simon Kallweit <simon.kallweit@intefo.ch>
Date: Mon, 24 Aug 2009 08:14:45 +0000 (+0200)
Subject: fixed a small bug and added testcases
X-Git-Url: http://git.inthemill.ch/?p=ecos.git;a=commitdiff_plain;h=d489213fe40325333ef88cd375535888b58c9407

fixed a small bug and added testcases
---

diff --git a/packages/devs/spi/cortexm/stm32/current/ChangeLog b/packages/devs/spi/cortexm/stm32/current/ChangeLog
index ecc4c15..96eed2c 100644
--- a/packages/devs/spi/cortexm/stm32/current/ChangeLog
+++ b/packages/devs/spi/cortexm/stm32/current/ChangeLog
@@ -1,3 +1,8 @@
+2009-08-24  Simon Kallweit  <simon.kallweit@intefo.ch>
+
+	* cdl/spi_stm32.cdl: added testcase.
+	* include/spi_stm32.h: initializing spi_cr1_val with zero.
+
 2009-02-10  Bart Veer  <bartv@ecoscentric.com>
 
 	* src/spi_stm32.c (cyg_spi_cortexm_stm32_init): mark as
diff --git a/packages/devs/spi/cortexm/stm32/current/cdl/spi_stm32.cdl b/packages/devs/spi/cortexm/stm32/current/cdl/spi_stm32.cdl
index 30015cf..51d5264 100644
--- a/packages/devs/spi/cortexm/stm32/current/cdl/spi_stm32.cdl
+++ b/packages/devs/spi/cortexm/stm32/current/cdl/spi_stm32.cdl
@@ -219,5 +219,12 @@ cdl_component CYGHWR_DEVS_SPI_CORTEXM_STM32_BUS3 {
     }
 }
 
+cdl_option CYGPKG_DEVS_SPI_CORTEXM_STM32_TESTS {
+    display         "SPI tests"
+    flavor          data
+    no_define
+    calculated      { "tests/loopback" } 
+}
+
 }
 # EOF spi_stm32.cdl
diff --git a/packages/devs/spi/cortexm/stm32/current/include/spi_stm32.h b/packages/devs/spi/cortexm/stm32/current/include/spi_stm32.h
index 21a04c0..a39c512 100644
--- a/packages/devs/spi/cortexm/stm32/current/include/spi_stm32.h
+++ b/packages/devs/spi/cortexm/stm32/current/include/spi_stm32.h
@@ -93,6 +93,7 @@ cyg_spi_cortexm_stm32_device_t _name_ ##_stm32 CYG_SPI_DEVICE_ON_BUS(_bus_) = {
   .cs_up_udly = _csup_dly_, \
   .cs_dw_udly = _csdw_dly_, \
   .tr_bt_udly = _trbt_dly_, \
+  .spi_cr1_val = 0, \
 }; \
 extern cyg_spi_device _name_ __attribute__((alias ( #_name_ "_stm32" )));
 

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: STM32 SPI driver fix
  2009-08-24  8:43 STM32 SPI driver fix Simon Kallweit
@ 2009-08-26  9:45 ` Nick Garnett
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Garnett @ 2009-08-26  9:45 UTC (permalink / raw)
  To: Simon Kallweit; +Cc: ecos-patches

Simon Kallweit <simon.kallweit@intefo.ch> writes:

> This is a little fix for the STM32 SPI driver. It initializes
> spi_cr1_val with zero (as stated in the comments) and adds the
> testcase to the CDL.

Committed. Thanks.


-- 
Nick Garnett                                       eCos Kernel Architect
eCosCentric Limited    http://www.eCosCentric.com       The eCos experts
Barnwell House, Barnwell Drive, Cambridge, UK.      Tel: +44 1223 245571
Registered in England and Wales:                         Reg No: 4422071

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-08-26  9:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-24  8:43 STM32 SPI driver fix Simon Kallweit
2009-08-26  9:45 ` Nick Garnett

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).