Subversion Repositories HelenOS-historic

Rev

Rev 32 | Rev 72 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 32 Rev 62
Line 30... Line 30...
30
#include <print.h>
30
#include <print.h>
31
#include <cpu.h>
31
#include <cpu.h>
32
#include <arch/asm.h>
32
#include <arch/asm.h>
33
#include <arch.h>
33
#include <arch.h>
34
 
34
 
35
__u32   haltstate = 0;
35
__u32   haltstate = 0; /**< Halt flag */
36
 
36
 
-
 
37
 
-
 
38
/** Halt wrapper
-
 
39
 *
-
 
40
 * Set halt flag and halt the cpu.
-
 
41
 *
-
 
42
 */
37
void halt(void)
43
void halt(void)
38
{
44
{
39
    haltstate = 1;
45
    haltstate = 1;
40
    cpu_priority_high();
46
    cpu_priority_high();
41
    printf("cpu%d: halted\n", CPU->id);
47
    printf("cpu%d: halted\n", CPU->id);
42
    cpu_halt();
48
    cpu_halt();
43
}
49
}
44
 
50
 
45
 
51
 
-
 
52
/** Compare two NULL terminated strings
46
/*
53
 *
-
 
54
 * Do a char-by-char comparment of two NULL terminated strings.
-
 
55
 * The strings are considered equal iff they have the same
-
 
56
 * length and consist of the same characters.
-
 
57
 *
47
 * returns 0 if src == dst
58
 * @param src First string to compare.
48
 * otherwise returns 1
59
 * @param dst Second string to compare.
-
 
60
 *
-
 
61
 * @return 0 if the strings are equal, 1 otherwise.
-
 
62
 *
49
 */
63
 */
50
int strcmp(char *src, char *dst)
64
int strcmp(char *src, char *dst)
51
{
65
{
52
    int i;
66
    int i;
53
   
67