]> jspc29.x-matter.uni-frankfurt.de Git - trbnettools.git/commitdiff
asm statement now as in kernel source
authorhadaq <hadaq>
Tue, 8 Sep 2009 22:23:02 +0000 (22:23 +0000)
committerhadaq <hadaq>
Tue, 8 Sep 2009 22:23:02 +0000 (22:23 +0000)
libtrbnet/trbnet.c

index d00ce8dab8b45d47dacd6ebe8fa190daa7e1c6f6..7775e142e7af269fd79238f09725e7647f83c861 100644 (file)
@@ -1,4 +1,4 @@
-const char trbnet_version[] = "$Revision: 2.43 $";
+const char trbnet_version[] = "$Revision: 2.44 $";
 
 #include <stdio.h>
 #include <stdlib.h>
@@ -195,7 +195,6 @@ typedef enum {
 
 static uint32_t fifoToggleBit = 0;
 
-
 static inline void write32_to_FPGA(uint16_t address, uint32_t value)
 {
   /* writes a 32bit word to a given address on a given device */
@@ -203,13 +202,9 @@ static inline void write32_to_FPGA(uint16_t address, uint32_t value)
   /* set address RW_WRITE */
   fifoToggleBit ^= FIFO_TOGGLE_BIT;
   writePC((address & 0x7fff) | fifoToggleBit);
-  __asm("nop");
-  __asm("nop");
-  __asm("nop");
-
-
-
-
+  __asm__ __volatile__ ("nop");
+  __asm__ __volatile__ ("nop");
+  __asm__ __volatile__ ("nop");
 
   /* write value */
   fifoToggleBit ^= FIFO_TOGGLE_BIT;
@@ -227,12 +222,9 @@ static inline void read32_from_FPGA(uint16_t address, uint32_t* value)
   /* set address RW_READ */
   fifoToggleBit ^= FIFO_TOGGLE_BIT;
   writePC((address | 0x8000) | fifoToggleBit);
-  __asm("nop");
-  __asm("nop");
-  __asm("nop");
-
-
-
+  __asm__ __volatile__ ("nop");
+  __asm__ __volatile__ ("nop");
+  __asm__ __volatile__ ("nop");
 
   /* read value */
   fifoToggleBit ^= FIFO_TOGGLE_BIT;