| .. | .. |
|---|
| 16 | 16 | |
|---|
| 17 | 17 | #include <asm/ptrace.h> |
|---|
| 18 | 18 | #include <asm/sn/addrs.h> |
|---|
| 19 | +#include <asm/sn/agent.h> |
|---|
| 19 | 20 | #include <asm/sn/arch.h> |
|---|
| 20 | | -#include <asm/sn/sn0/hub.h> |
|---|
| 21 | 21 | #include <asm/tlbdebug.h> |
|---|
| 22 | 22 | #include <asm/traps.h> |
|---|
| 23 | 23 | #include <linux/uaccess.h> |
|---|
| .. | .. |
|---|
| 30 | 30 | { "WERR", "Uncached Partial Write", "PWERR", "Write Timeout", |
|---|
| 31 | 31 | NULL, NULL, NULL, NULL } |
|---|
| 32 | 32 | }; |
|---|
| 33 | | - int wrb = errst1 & PI_ERR_ST1_WRBRRB_MASK; |
|---|
| 33 | + union pi_err_stat0 st0; |
|---|
| 34 | + union pi_err_stat1 st1; |
|---|
| 34 | 35 | |
|---|
| 35 | | - if (!(errst0 & PI_ERR_ST0_VALID_MASK)) { |
|---|
| 36 | | - printk("Hub does not contain valid error information\n"); |
|---|
| 36 | + st0.pi_stat0_word = errst0; |
|---|
| 37 | + st1.pi_stat1_word = errst1; |
|---|
| 38 | + |
|---|
| 39 | + if (!st0.pi_stat0_fmt.s0_valid) { |
|---|
| 40 | + pr_info("Hub does not contain valid error information\n"); |
|---|
| 37 | 41 | return; |
|---|
| 38 | 42 | } |
|---|
| 39 | 43 | |
|---|
| 40 | | - |
|---|
| 41 | | - printk("Hub has valid error information:\n"); |
|---|
| 42 | | - if (errst0 & PI_ERR_ST0_OVERRUN_MASK) |
|---|
| 43 | | - printk("Overrun is set. Error stack may contain additional " |
|---|
| 44 | + pr_info("Hub has valid error information:\n"); |
|---|
| 45 | + if (st0.pi_stat0_fmt.s0_ovr_run) |
|---|
| 46 | + pr_info("Overrun is set. Error stack may contain additional " |
|---|
| 44 | 47 | "information.\n"); |
|---|
| 45 | | - printk("Hub error address is %08lx\n", |
|---|
| 46 | | - (errst0 & PI_ERR_ST0_ADDR_MASK) >> (PI_ERR_ST0_ADDR_SHFT - 3)); |
|---|
| 47 | | - printk("Incoming message command 0x%lx\n", |
|---|
| 48 | | - (errst0 & PI_ERR_ST0_CMD_MASK) >> PI_ERR_ST0_CMD_SHFT); |
|---|
| 49 | | - printk("Supplemental field of incoming message is 0x%lx\n", |
|---|
| 50 | | - (errst0 & PI_ERR_ST0_SUPPL_MASK) >> PI_ERR_ST0_SUPPL_SHFT); |
|---|
| 51 | | - printk("T5 Rn (for RRB only) is 0x%lx\n", |
|---|
| 52 | | - (errst0 & PI_ERR_ST0_REQNUM_MASK) >> PI_ERR_ST0_REQNUM_SHFT); |
|---|
| 53 | | - printk("Error type is %s\n", err_type[wrb] |
|---|
| 54 | | - [(errst0 & PI_ERR_ST0_TYPE_MASK) >> PI_ERR_ST0_TYPE_SHFT] |
|---|
| 55 | | - ? : "invalid"); |
|---|
| 48 | + pr_info("Hub error address is %08lx\n", |
|---|
| 49 | + (unsigned long)st0.pi_stat0_fmt.s0_addr); |
|---|
| 50 | + pr_info("Incoming message command 0x%lx\n", |
|---|
| 51 | + (unsigned long)st0.pi_stat0_fmt.s0_cmd); |
|---|
| 52 | + pr_info("Supplemental field of incoming message is 0x%lx\n", |
|---|
| 53 | + (unsigned long)st0.pi_stat0_fmt.s0_supl); |
|---|
| 54 | + pr_info("T5 Rn (for RRB only) is 0x%lx\n", |
|---|
| 55 | + (unsigned long)st0.pi_stat0_fmt.s0_t5_req); |
|---|
| 56 | + pr_info("Error type is %s\n", err_type[st1.pi_stat1_fmt.s1_rw_rb] |
|---|
| 57 | + [st0.pi_stat0_fmt.s0_err_type] ? : "invalid"); |
|---|
| 56 | 58 | } |
|---|
| 57 | 59 | |
|---|
| 58 | 60 | int ip27_be_handler(struct pt_regs *regs, int is_fixup) |
|---|
| .. | .. |
|---|
| 74 | 76 | show_regs(regs); |
|---|
| 75 | 77 | dump_tlb_all(); |
|---|
| 76 | 78 | while(1); |
|---|
| 77 | | - force_sig(SIGBUS, current); |
|---|
| 79 | + force_sig(SIGBUS); |
|---|
| 78 | 80 | } |
|---|
| 79 | 81 | |
|---|
| 80 | 82 | void __init ip27_be_init(void) |
|---|