]> git.kernelconcepts.de Git - karo-tx-linux.git/blob - arch/parisc/kernel/pa7300lc.c
Merge branch 'work.uaccess-unaligned' of git://git.kernel.org/pub/scm/linux/kernel...
[karo-tx-linux.git] / arch / parisc / kernel / pa7300lc.c
1 /*
2  *   linux/arch/parisc/kernel/pa7300lc.c
3  *      - PA7300LC-specific functions   
4  *
5  *   Copyright (C) 2000 Philipp Rumpf */
6
7 #include <linux/sched.h>
8 #include <linux/sched/debug.h>
9 #include <linux/smp.h>
10 #include <linux/kernel.h>
11 #include <asm/io.h>
12 #include <asm/ptrace.h>
13 #include <asm/machdep.h>
14
15 /* CPU register indices */
16
17 #define MIOC_STATUS     0xf040
18 #define MIOC_CONTROL    0xf080
19 #define MDERRADD        0xf0e0
20 #define DMAERR          0xf0e8
21 #define DIOERR          0xf0ec
22 #define HIDMAMEM        0xf0f4
23
24 /* this returns the HPA of the CPU it was called on */
25 static u32 cpu_hpa(void)
26 {
27         return 0xfffb0000;
28 }
29
30 static void pa7300lc_lpmc(int code, struct pt_regs *regs)
31 {
32         u32 hpa;
33         printk(KERN_WARNING "LPMC on CPU %d\n", smp_processor_id());
34
35         show_regs(regs);
36
37         hpa = cpu_hpa();
38         printk(KERN_WARNING
39                 "MIOC_CONTROL %08x\n" "MIOC_STATUS  %08x\n"
40                 "MDERRADD     %08x\n" "DMAERR       %08x\n"
41                 "DIOERR       %08x\n" "HIDMAMEM     %08x\n",
42                 gsc_readl(hpa+MIOC_CONTROL), gsc_readl(hpa+MIOC_STATUS),
43                 gsc_readl(hpa+MDERRADD), gsc_readl(hpa+DMAERR),
44                 gsc_readl(hpa+DIOERR), gsc_readl(hpa+HIDMAMEM));
45 }
46
47 void pa7300lc_init(void)
48 {
49         cpu_lpmc = pa7300lc_lpmc;
50 }