Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
[cris-mirror.git] / arch / parisc / kernel / pa7300lc.c
blob0d770ac83f70b5ee5d54df5e56559c997cd19f10
1 // SPDX-License-Identifier: GPL-2.0
2 /*
3 * linux/arch/parisc/kernel/pa7300lc.c
4 * - PA7300LC-specific functions
6 * Copyright (C) 2000 Philipp Rumpf */
8 #include <linux/sched.h>
9 #include <linux/sched/debug.h>
10 #include <linux/smp.h>
11 #include <linux/kernel.h>
12 #include <asm/io.h>
13 #include <asm/ptrace.h>
14 #include <asm/machdep.h>
16 /* CPU register indices */
18 #define MIOC_STATUS 0xf040
19 #define MIOC_CONTROL 0xf080
20 #define MDERRADD 0xf0e0
21 #define DMAERR 0xf0e8
22 #define DIOERR 0xf0ec
23 #define HIDMAMEM 0xf0f4
25 /* this returns the HPA of the CPU it was called on */
26 static u32 cpu_hpa(void)
28 return 0xfffb0000;
31 static void pa7300lc_lpmc(int code, struct pt_regs *regs)
33 u32 hpa;
34 printk(KERN_WARNING "LPMC on CPU %d\n", smp_processor_id());
36 show_regs(regs);
38 hpa = cpu_hpa();
39 printk(KERN_WARNING
40 "MIOC_CONTROL %08x\n" "MIOC_STATUS %08x\n"
41 "MDERRADD %08x\n" "DMAERR %08x\n"
42 "DIOERR %08x\n" "HIDMAMEM %08x\n",
43 gsc_readl(hpa+MIOC_CONTROL), gsc_readl(hpa+MIOC_STATUS),
44 gsc_readl(hpa+MDERRADD), gsc_readl(hpa+DMAERR),
45 gsc_readl(hpa+DIOERR), gsc_readl(hpa+HIDMAMEM));
48 void pa7300lc_init(void)
50 cpu_lpmc = pa7300lc_lpmc;