Subversion Repositories HelenOS-historic

Compare Revisions

Ignore whitespace Rev 624 → Rev 625

/kernel/trunk/arch/mips32/include/atomic.h
41,7 → 41,7
#define atomic_dec_post(x) atomic_add(x, -1)
 
 
typedef volatile __u32 atomic_t;
typedef struct { volatile __u32 count; } atomic_t;
 
/* Atomic addition of immediate value.
*
62,7 → 62,7
" sc %0, %1\n"
" beq %0, %4, 1b\n" /* if the atomic operation failed, try again */
/* nop */ /* nop is inserted automatically by compiler */
: "=r" (tmp), "=m" (*val), "=r" (v)
: "=r" (tmp), "=m" (val->count), "=r" (v)
: "i" (i), "i" (0)
);
 
69,5 → 69,16
return v;
}
 
/* Reads/writes are atomic on mips for 4-bytes */
 
static inline void atomic_set(atomic_t *val, __u32 i)
{
val->count = i;
}
 
static inline __u32 atomic_get(atomic_t *val)
{
return val->count;
}
 
#endif
/kernel/trunk/arch/mips32/src/drivers/serial.c
38,7 → 38,6
 
static void serial_write(chardev_t *d, const char ch)
{
int i;
serial_t *sd = (serial_t *)d->data;
 
if (ch == '\n')
/kernel/trunk/arch/mips32/src/drivers/arc.c
188,6 → 188,8
arc_putchar('R');
arc_putchar('C');
arc_putchar('\n');
 
return 0;
}
 
static bool kbd_polling_enabled;
286,7 → 288,6
int total = 0;
__address base;
size_t basesize;
unsigned int i,j;
 
desc = arc_entry->getmemorydescriptor(NULL);
while (desc) {