Changeset 95c4776 in mainline for kernel/arch/sparc64/src
- Timestamp:
- 2010-02-21T19:02:16Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- af56e9b
- Parents:
- c2efbb4
- Location:
- kernel/arch/sparc64/src
- Files:
-
- 4 added
- 2 edited
- 2 moved
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/sparc64/src/cpu/sun4v/cpu.c
rc2efbb4 r95c4776 41 41 #include <arch/sun4v/md.h> 42 42 #include <arch/sun4v/hypercall.h> 43 #include <arch/trap/sun4v/interrupt.h> 43 44 44 45 //#include <arch/trap/sun4v/interrupt.h> … … 74 75 75 76 tick_init(); 76 //MH - uncomment later 77 //sun4v_ipi_init();77 78 sun4v_ipi_init(); 78 79 } 79 80 -
kernel/arch/sparc64/src/smp/sun4u/ipi.c
rc2efbb4 r95c4776 99 99 status = asi_u64_read(ASI_INTR_DISPATCH_STATUS, 0); 100 100 if (status & INTR_DISPATCH_STATUS_BUSY) 101 panic("Interrupt Dispatch Status busy bit set .");101 panic("Interrupt Dispatch Status busy bit set\n"); 102 102 103 103 ASSERT(!(pstate_read() & PSTATE_IE_BIT)); … … 152 152 break; 153 153 default: 154 panic("Unknown IPI (%d). ", ipi);154 panic("Unknown IPI (%d).\n", ipi); 155 155 break; 156 156 } -
kernel/arch/sparc64/src/smp/sun4u/smp.c
rc2efbb4 r95c4776 36 36 #include <genarch/ofw/ofw_tree.h> 37 37 #include <cpu.h> 38 #include <arch/ cpu_family.h>38 #include <arch/sun4u/cpu_family.h> 39 39 #include <arch/cpu.h> 40 40 #include <arch.h> … … 45 45 #include <synch/waitq.h> 46 46 #include <print.h> 47 #include <arch/ cpu_node.h>47 #include <arch/sun4u/cpu_node.h> 48 48 49 49 /** … … 62 62 { 63 63 ofw_tree_node_t *node; 64 size_t cnt = 0;64 count_t cnt = 0; 65 65 66 66 if (is_us() || is_us_iii()) { -
kernel/arch/sparc64/src/trap/interrupt.c
rc2efbb4 r95c4776 1 1 /* 2 2 * Copyright (c) 2005 Jakub Jermar 3 * Copyright (c) 2009 Pavel Rimsky 3 4 * All rights reserved. 4 5 * … … 34 35 35 36 #include <arch/interrupt.h> 37 #include <arch/trap/interrupt.h> 36 38 #include <arch/sparc64.h> 37 #include <arch/trap/interrupt.h>38 39 #include <interrupt.h> 39 40 #include <ddi/irq.h> … … 60 61 exc_register(n - 1, name, f); 61 62 } 62 63 /** Process hardware interrupt.64 *65 * @param n Ignored.66 * @param istate Ignored.67 */68 void interrupt(int n, istate_t *istate)69 {70 uint64_t status;71 uint64_t intrcv;72 uint64_t data0;73 status = asi_u64_read(ASI_INTR_DISPATCH_STATUS, 0);74 if (status & (!INTR_DISPATCH_STATUS_BUSY))75 panic("Interrupt Dispatch Status busy bit not set.");76 77 intrcv = asi_u64_read(ASI_INTR_RECEIVE, 0);78 #if defined (US)79 data0 = asi_u64_read(ASI_INTR_R, ASI_UDB_INTR_R_DATA_0);80 #elif defined (US3)81 data0 = asi_u64_read(ASI_INTR_R, VA_INTR_R_DATA_0);82 #endif83 84 irq_t *irq = irq_dispatch_and_lock(data0);85 if (irq) {86 /*87 * The IRQ handler was found.88 */89 irq->handler(irq);90 /*91 * See if there is a clear-interrupt-routine and call it.92 */93 if (irq->cir) {94 irq->cir(irq->cir_arg, irq->inr);95 }96 spinlock_unlock(&irq->lock);97 } else if (data0 > config.base) {98 /*99 * This is a cross-call.100 * data0 contains address of the kernel function.101 * We call the function only after we verify102 * it is one of the supported ones.103 */104 #ifdef CONFIG_SMP105 if (data0 == (uintptr_t) tlb_shootdown_ipi_recv) {106 tlb_shootdown_ipi_recv();107 }108 #endif109 } else {110 /*111 * Spurious interrupt.112 */113 #ifdef CONFIG_DEBUG114 printf("cpu%u: spurious interrupt (intrcv=%#" PRIx64115 ", data0=%#" PRIx64 ")\n", CPU->id, intrcv, data0);116 #endif117 }118 119 membar();120 asi_u64_write(ASI_INTR_RECEIVE, 0, 0);121 }122 123 63 /** @} 124 64 */
Note:
See TracChangeset
for help on using the changeset viewer.