GPIO NAND: Move definitions to header file
authorSandeep Paulraj <s-paulraj@ti.com>
Tue, 14 Jun 2011 17:43:30 +0000 (13:43 -0400)
committerSandeep Paulraj <s-paulraj@ti.com>
Thu, 30 Jun 2011 16:04:36 +0000 (12:04 -0400)
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
src/device/c66x/target.h
src/hw/nands/gpio/nandgpio.c

index 853a4a073373d1063f2f59235036d9952af03f60..6498114c9099b3a2c32199db8a03954a8a5761e9 100644 (file)
@@ -332,6 +332,13 @@ Int32 targetMacRcv (void *ptr_device, UINT8 *buffer);
 #define DEVICE_PSTREAM_CFG_REG_VAL_ROUTE_PDSP0      0
 #define hwConfigStreamingSwitch()                   DEVICE_REG32_W(DEVICE_PSTREAM_CFG_REG_ADDR, DEVICE_PSTREAM_CFG_REG_VAL_ROUTE_PDSP0);
 
+#define NAND_BYTES_PER_PAGE            512
+#define ECC_BLOCK_SIZE                 256
+#define NAND_SPARE_BYTES_PER_PAGE      16
+
+/* NAND address pack macro */
+#define PACK_ADDR(col, page, block) \
+        ((col & 0x000000ff) | ((page & 0x0000001f) << 9) | ((block & 0x00000fff) << 14))
 
 /**
  *  @brief
index 205d8ae32cf94f97e8e944bf1dbb143a61723180..5ca9c76a2820f0012cf8830855491adbd6e3c52f 100644 (file)
 #include "target.h"
 #include "nandgpioloc.h"
 
-#define NAND_BYTES_PER_PAGE            512
-#define ECC_BLOCK_SIZE                 256
-#define NAND_SPARE_BYTES_PER_PAGE      16
-#define ECC_SPARE_OFFSET  (NAND_SPARE_BYTES_PER_PAGE - 3 * (NAND_BYTES_PER_PAGE / ECC_BLOCK_SIZE))
-
-/* NAND address pack macro */
-#define PACK_ADDR(col, page, block) \
-        ((col & 0x000000ff) | ((page & 0x0000001f) << 9) | ((block & 0x00000fff) << 14))
-
 /* Pointer to the device configuration */
 extern volatile cregister Uint32 TSCL;
 nandDevInfo_t *hwDevInfo;