2 * linux/arch/m68k/lib/semaphore.S
4 * Copyright (C) 1996 Linus Torvalds
6 * m68k version by Andreas Schwab
8 * MAR/1999 -- modified to support ColdFire (gerg@snapgear.com)
11 #include <linux/linkage.h>
12 #include <asm/semaphore.h>
15 * "down_failed" is called with the eventual return address
16 * in %a0, and the address of the semaphore in %a1. We need
17 * to increment the number of waiters on the semaphore,
18 * call "__down()", and then eventually return to try again.
21 #ifdef CONFIG_COLDFIRE
23 moveml %a0/%d0/%d1,(%sp)
25 moveml %a0/%d0/%d1,-(%sp)
34 ENTRY(__down_failed_interruptible)
38 jbsr __down_interruptible
44 #ifdef CONFIG_COLDFIRE
46 moveml %a0/%d0/%d1,(%sp)
48 moveml %a0/%d0/%d1,-(%sp)
57 ENTRY(__down_failed_trylock)