Changeset bebfc420 in rtems


Ignore:
Timestamp:
Sep 10, 2015, 3:20:41 PM (4 years ago)
Author:
Marcos Diaz <marcos.diaz@…>
Branches:
master
Children:
808230a
Parents:
cf2f383
git-author:
Marcos Diaz <marcos.diaz@…> (09/10/15 15:20:41)
git-committer:
Joel Sherrill <joel.sherrill@…> (09/10/15 18:21:41)
Message:

Beaglebone: fix missing clobber in inline assembly.

flush_data_cache uses R0 directly but doesn't list it as a clobbered
register. Compiling with -O3 made this code break, since the function
that calls flush_data_cache already uses r0.

closes #2416.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/arm/beagle/include/bsp.h

    rcf2f383 rbebfc420  
    113113static inline void flush_data_cache(void)
    114114{
    115     asm volatile("mov r0, #0; mcr p15, #0, r0, c7, c10, #4" : : : "memory");
     115    asm volatile(
     116        "mov r0, #0\n"
     117        "mcr p15, #0, r0, c7, c10, #4\n"
     118        : /* No outputs */
     119        : /* No inputs */
     120        : "r0","memory"
     121    );
    116122}
    117123
Note: See TracChangeset for help on using the changeset viewer.