Prepare v2023.10
[platform/kernel/u-boot.git] / arch / microblaze / cpu / interrupts.c
1 // SPDX-License-Identifier: GPL-2.0+
2 /*
3  * (C) Copyright 2007 Michal Simek
4  * (C) Copyright 2004 Atmark Techno, Inc.
5  *
6  * Michal  SIMEK <monstr@monstr.eu>
7  * Yasushi SHOJI <yashi@atmark-techno.com>
8  */
9
10 #include <common.h>
11 #include <asm/asm.h>
12
13 void enable_interrupts(void)
14 {
15         debug("Enable interrupts for the whole CPU\n");
16         MSRSET(0x2);
17 }
18
19 int disable_interrupts(void)
20 {
21         unsigned int msr;
22
23         MFS(msr, rmsr);
24         MSRCLR(0x2);
25         return (msr & 0x2) != 0;
26 }
27
28 int interrupt_init(void)
29 {
30         return 0;
31 }
32
33 void interrupt_handler(void)
34 {
35         panic("Interrupt occurred\n");
36 }