]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/ibl.git/blobdiff - src/main/iblinitspinor.c
Makefile cleanup
[keystone-rtos/ibl.git] / src / main / iblinitspinor.c
index 1339c81f183e4e9ee923849c70e3acf073356eca..75e5509d7b92e5f6d4f8f556e4da86072f580502 100644 (file)
@@ -42,6 +42,7 @@
 #include "iblinit.h"
 #include <string.h>
 
+#if (!defined(EXCLUDE_NOR_SPI) || !defined(EXCLUDE_NAND_SPI))
 
 /**
  *  @brief
@@ -183,9 +184,10 @@ BOOT_MODULE_FXN_TABLE *iblInitSpiNor (void)
     /* Read the SPI mapping information from the nor flash */
     for (;;)  {
 
-        if (hwSpiRead (IBL_CFG_SPI_MAP_TABLE_DATA_ADDR,      /* The address on the flash of the data mapping */
-                       sizeof(iblBootMap_t),                 /* The number of bytes to read */
-                       (UINT8 *)&map)                        /* Where to store the data */
+        if (hwSpiRead ((IBL_CFG_SPI_MAP_TABLE_DATA_ADDR_MSW << 16) |   /* The address on the flash of the data mapping */
+                        IBL_CFG_SPI_MAP_TABLE_DATA_ADDR_LSW,
+                       sizeof(iblBootMap_t),                           /* The number of bytes to read */
+                       (UINT8 *)&map)                                  /* Where to store the data */
 
           == 0)  {
 
@@ -280,6 +282,7 @@ BOOT_MODULE_FXN_TABLE *iblInitSpiNor (void)
 }
 
 
+#endif /* (!defined(EXCLUDE_NOR_SPI) || !defined(EXCLUDE_NAND_SPI)) */