Ignore:
Timestamp:
2010-02-17T14:11:07Z (15 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
b8da2a3
Parents:
101d9f4
Message:

add the possibility to compile abs32le with any cross-compiler which generates
32bit little endian code

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/libc/arch/abs32le/include/atomic.h

    r101d9f4 r81983e3  
    3636#define LIBC_abs32le_ATOMIC_H_
    3737
     38#include <bool.h>
     39
    3840#define LIBC_ARCH_ATOMIC_H_
     41#define CAS
    3942
    4043#include <atomicdflt.h>
     44
     45static inline bool cas(atomic_t *val, long ov, long nv)
     46{
     47        if (val->count == ov) {
     48                val->count = nv;
     49                return true;
     50        }
     51       
     52        return false;
     53}
    4154
    4255static inline void atomic_inc(atomic_t *val) {
Note: See TracChangeset for help on using the changeset viewer.