/* cmpxchg*() fallbacks for CPU not supporting these instructions  */
unsigned long cmpxchg_386_u8(volatile void *ptr, u8 old, u8 new)
/* cmpxchg*() fallbacks for CPU not supporting these instructions  */
unsigned long cmpxchg_386_u8(volatile void *ptr, u8 old, u8 new)
{
	u8 prev;
	unsigned long flags;
	local_irq_save(flags);
	prev = *(u8 *)ptr;
	if (prev == old)
		*(u8 *)ptr = new;
	local_irq_restore(flags);
	return prev;
}