]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/mcsdk-tools.git/blobdiff - writer/nor/src/norwriter.c
Merge branch 'master' of gtgit01.gt.design.ti.com:git/projects/mcsdk-tools
[keystone-rtos/mcsdk-tools.git] / writer / nor / src / norwriter.c
index ca32b96053ac93ace4de6fc678c3484e35a473ff..3d6487c6d4af175c257ae0a7a28b6a422957fbd9 100644 (file)
 #include <stdio.h>
 #include <string.h>
 #include "platform.h"
-#include "../include/types.h"
+#include "types.h"
 
 /* NOR writer utility version */
-char version[] = "01.00.00.02";
+char version[] = "01.00.00.03";
 
 /* The input file name is hard coded */
 char *input_file = "nor_writer_input.txt";
@@ -82,6 +82,31 @@ typedef struct NOR_WRITER_INFO_tag
 
 NOR_WRITER_INFO_T norWriterInfo;
 
+/* OSAL functions for Platform Library */
+uint8_t *Osal_platformMalloc (uint32_t num_bytes, uint32_t alignment)
+{
+       return malloc(num_bytes);
+}
+
+void Osal_platformFree (uint8_t *dataPtr, uint32_t num_bytes)
+{
+    /* Free up the memory */
+    if (dataPtr)
+    {
+        free(dataPtr);
+    }
+}
+
+void Osal_platformSpiCsEnter(void)
+{
+    return;
+}
+
+void Osal_platformSpiCsExit (void)
+{
+    return;
+}
+
 /******************************************************************************
  * Function:    print_platform_errno
  ******************************************************************************/
@@ -279,7 +304,7 @@ parse_input_file
 )
 {
     char line[MAX_LINE_LENGTH];
-    char tokens[] = " :=;\n";
+    char tokens[] = " :=;\n\r";
     char *key, *data;
 
     memset(line, 0, MAX_LINE_LENGTH);