This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

atmel dataflash patch


Andrew or Bart please check this in the flash_V2 branch,
thanks.

Changelog:
Return correct value from cyg_dataflash_get_page_count()
Allow building without IO flash API support.
diff -ur /home/jani/work/ecoswork/flash/ecos/packages/devs/flash/atmel/dataflash/current/include/dataflash.h devs/flash/atmel/dataflash/current/include/dataflash.h
--- /home/jani/work/ecoswork/flash/ecos/packages/devs/flash/atmel/dataflash/current/include/dataflash.h	2005-02-22 23:03:49.000000000 +0200
+++ devs/flash/atmel/dataflash/current/include/dataflash.h	2005-06-29 16:56:59.399641952 +0300
@@ -97,7 +97,7 @@
 } cyg_dataflash_device_t;
 
 //----------------------------------------------------------------------------
-
+#ifdef CYGPKG_IO_FLASH
 #include <cyg/io/flash.h>
 #include <cyg/io/flash_dev.h>
 
@@ -129,6 +129,7 @@
                      & cyg_dataflash_priv_ ## name                              \
         )
     
+#endif
 //----------------------------------------------------------------------------
 
 static inline cyg_uint8
@@ -146,7 +147,7 @@
 static inline cyg_uint16
 cyg_dataflash_get_page_count(cyg_dataflash_device_t *dev)
 {
-    return dev->info->page_size;
+    return dev->info->page_count;
 }
 
 static inline cyg_uint16

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]