OpenCores
URL https://opencores.org/ocsvn/or1k_old/or1k_old/trunk

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [rc203soc/] [sw/] [uClinux/] [arch/] [m68knommu/] [lib/] [semaphore.S] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1625 jcastillo
/*
2
 *  linux/arch/m68k/lib/semaphore.S
3
 *
4
 *  Copyright (C) 1996  Linus Torvalds
5
 *
6
 *  m68k version by Andreas Schwab
7
 *
8
 *  MAR/1999 -- modified to support ColdFire (gerg@moreton.com.au)
9
 */
10
 
11
#include 
12
#include 
13
 
14
/*
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.
19
 */
20
ENTRY(__down_failed)
21
#ifdef CONFIG_COLDFIRE
22
        subl #12,%sp
23
        moveml %a0/%d0/%d1,(%sp)
24
#else
25
        moveml %a0/%d0/%d1,-(%sp)
26
#endif
27
        movel %a1,-(%sp)
28
        jbsr SYMBOL_NAME(__down)
29
        movel (%sp)+,%a1
30
        movel (%sp)+,%d0
31
        movel (%sp)+,%d1
32
        rts
33
 
34
ENTRY(__down_failed_interruptible)
35
        movel %a0,-(%sp)
36
        movel %d1,-(%sp)
37
        movel %a1,-(%sp)
38
        jbsr SYMBOL_NAME(__down_interruptible)
39
        movel (%sp)+,%a1
40
        movel (%sp)+,%d1
41
        rts
42
 
43
ENTRY(__up_wakeup)
44
#ifdef CONFIG_COLDFIRE
45
        subl #12,%sp
46
        moveml %a0/%d0/%d1,(%sp)
47
#else
48
        moveml %a0/%d0/%d1,-(%sp)
49
#endif
50
        movel %a1,-(%sp)
51
        jbsr SYMBOL_NAME(__up)
52
        movel (%sp)+,%a1
53
        movel (%sp)+,%d0
54
        movel (%sp)+,%d1
55
        rts

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.