Re: how to include mips assembly in c code?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Oct 09, 2003 at 11:08:56AM +0530, durai wrote:

> I am having the following assembly code and i wanted to call this function
> from a c code.
> can anybody tell me how to include this code in a c program?

Several solutions:

  #define sysWbFlush()	 do { (*(volatile unsigned int *)K1BASE) } while (0)

Or using your existing code:

  extern void sysWbFlush(void);

the call as

  sysWbFlush();

No point in using inline assembler for such a small fragment.

Anyway - I suggest you dump this code and look at <asm/wbflush.h>.

  Ralf


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux