]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/mcsdk-tools.git/blobdiff - boot_loader/examples/srio/srioboot_example/src/srioBootExample.c
Added EMAC loopback support and updated projects to use resource manager
[keystone-rtos/mcsdk-tools.git] / boot_loader / examples / srio / srioboot_example / src / srioBootExample.c
index bd72c4696e8df96635c922273c80d00ffb099e1c..03428462f17619731f968c37453864f1249f9fae 100644 (file)
@@ -36,6 +36,7 @@
 #include "platform.h"
 #include "srioDdrInit.h"
 #include "srioBootCode.h"
+#include "ti/csl/csl_semAux.h"
 
 #define DEVICE_REG32_W(x,y)   *(volatile uint32_t *)(x)=(y)
 #define DEVICE_REG32_R(x)    (*(volatile uint32_t *)(x))
@@ -105,6 +106,28 @@ uint32_t byteto32bits(uint8_t *pDspCode)
     return(temp);
 }
 
+void Osal_platformSpiCsEnter(void)
+{
+    /* Get the hardware semaphore.
+     *
+     * Acquire Multi core CPPI synchronization lock
+     */
+    while ((CSL_semAcquireDirect (3)) == 0);
+
+    return;
+}
+
+void Osal_platformSpiCsExit (void)
+{
+    /* Release the hardware semaphore
+     *
+     * Release multi-core lock.
+     */
+    CSL_semReleaseSemaphore (3);
+
+    return;
+}
+
 
 /* Convert to big endian, if the .out to be booted is big endian, this is not required */
 void