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

Subversion Repositories or1k

[/] [or1k/] [trunk/] [rc203soc/] [sw/] [uClinux/] [include/] [asm-armnommu/] [arch-arc/] [system.h] - Blame information for rev 1777

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1633 jcastillo
/*
2
 * linux/include/asm-arm/arch-arc/system.h
3
 *
4
 * Copyright (c) 1996 Russell King and Dave Gilbert
5
 */
6
#ifndef __ASM_ARCH_SYSTEM_H
7
#define __ASM_ARCH_SYSTEM_H
8
 
9
#define cliIF()                         \
10
        do {                            \
11
          unsigned long temp;           \
12
          __asm__ __volatile__(         \
13
"       mov     %0, pc\n"               \
14
"       orr %0, %0, #0x0c000000\n"      \
15
"       teqp    %0, #0\n"               \
16
          : "=r" (temp) \
17
    : );        \
18
  } while(0)
19
 
20
extern __inline__ void arch_hard_reset (void)
21
{
22
        extern void ecard_reset (int card);
23
 
24
        /*
25
         * Reset all expansion cards.
26
         */
27
        ecard_reset (-1);
28
 
29
        /*
30
         * copy branch instruction to reset location and call it
31
         */
32
        *(unsigned long *)0 = *(unsigned long *)0x03800000;
33
        ((void(*)(void))0)();
34
 
35
        /*
36
         * If that didn't work, loop endlessly
37
         */
38
        while (1);
39
}
40
 
41
#endif

powered by: WebSVN 2.1.0

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