Loading...
1/*
2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
4 * for more details.
5 *
6 * Miscellaneous ARCS PROM routines.
7 *
8 * Copyright (C) 1996 David S. Miller (davem@davemloft.net)
9 * Copyright (C) 1999 Ralf Baechle (ralf@gnu.org)
10 * Copyright (C) 1999 Silicon Graphics, Inc.
11 */
12#include <linux/compiler.h>
13#include <linux/init.h>
14#include <linux/kernel.h>
15#include <linux/irqflags.h>
16
17#include <asm/bcache.h>
18
19#include <asm/fw/arc/types.h>
20#include <asm/sgialib.h>
21#include <asm/bootinfo.h>
22
23VOID __noreturn
24ArcHalt(VOID)
25{
26 bc_disable();
27 local_irq_disable();
28 ARC_CALL0(halt);
29
30 unreachable();
31}
32
33VOID __noreturn
34ArcPowerDown(VOID)
35{
36 bc_disable();
37 local_irq_disable();
38 ARC_CALL0(pdown);
39
40 unreachable();
41}
42
43/* XXX is this a soft reset basically? XXX */
44VOID __noreturn
45ArcRestart(VOID)
46{
47 bc_disable();
48 local_irq_disable();
49 ARC_CALL0(restart);
50
51 unreachable();
52}
53
54VOID __noreturn
55ArcReboot(VOID)
56{
57 bc_disable();
58 local_irq_disable();
59 ARC_CALL0(reboot);
60
61 unreachable();
62}
63
64VOID __noreturn
65ArcEnterInteractiveMode(VOID)
66{
67 bc_disable();
68 local_irq_disable();
69 ARC_CALL0(imode);
70
71 unreachable();
72}
73
74LONG
75ArcSaveConfiguration(VOID)
76{
77 return ARC_CALL0(cfg_save);
78}
79
80struct linux_sysid *
81ArcGetSystemId(VOID)
82{
83 return (struct linux_sysid *) ARC_CALL0(get_sysid);
84}
85
86VOID __init
87ArcFlushAllCaches(VOID)
88{
89 ARC_CALL0(cache_flush);
90}
91
92DISPLAY_STATUS * __init ArcGetDisplayStatus(ULONG FileID)
93{
94 return (DISPLAY_STATUS *) ARC_CALL1(GetDisplayStatus, FileID);
95}
1/*
2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
4 * for more details.
5 *
6 * Miscellaneous ARCS PROM routines.
7 *
8 * Copyright (C) 1996 David S. Miller (davem@davemloft.net)
9 * Copyright (C) 1999 Ralf Baechle (ralf@gnu.org)
10 * Copyright (C) 1999 Silicon Graphics, Inc.
11 */
12#include <linux/init.h>
13#include <linux/kernel.h>
14
15#include <asm/bcache.h>
16
17#include <asm/fw/arc/types.h>
18#include <asm/sgialib.h>
19#include <asm/bootinfo.h>
20
21VOID
22ArcHalt(VOID)
23{
24 bc_disable();
25 local_irq_disable();
26 ARC_CALL0(halt);
27never: goto never;
28}
29
30VOID
31ArcPowerDown(VOID)
32{
33 bc_disable();
34 local_irq_disable();
35 ARC_CALL0(pdown);
36never: goto never;
37}
38
39/* XXX is this a soft reset basically? XXX */
40VOID
41ArcRestart(VOID)
42{
43 bc_disable();
44 local_irq_disable();
45 ARC_CALL0(restart);
46never: goto never;
47}
48
49VOID
50ArcReboot(VOID)
51{
52 bc_disable();
53 local_irq_disable();
54 ARC_CALL0(reboot);
55never: goto never;
56}
57
58VOID
59ArcEnterInteractiveMode(VOID)
60{
61 bc_disable();
62 local_irq_disable();
63 ARC_CALL0(imode);
64never: goto never;
65}
66
67LONG
68ArcSaveConfiguration(VOID)
69{
70 return ARC_CALL0(cfg_save);
71}
72
73struct linux_sysid *
74ArcGetSystemId(VOID)
75{
76 return (struct linux_sysid *) ARC_CALL0(get_sysid);
77}
78
79VOID __init
80ArcFlushAllCaches(VOID)
81{
82 ARC_CALL0(cache_flush);
83}
84
85DISPLAY_STATUS * __init ArcGetDisplayStatus(ULONG FileID)
86{
87 return (DISPLAY_STATUS *) ARC_CALL1(GetDisplayStatus, FileID);
88}