| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * kgdb support for ARC |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright (C) 2012 Synopsys, Inc. (www.synopsys.com) |
|---|
| 5 | | - * |
|---|
| 6 | | - * This program is free software; you can redistribute it and/or modify |
|---|
| 7 | | - * it under the terms of the GNU General Public License version 2 as |
|---|
| 8 | | - * published by the Free Software Foundation. |
|---|
| 9 | 6 | */ |
|---|
| 10 | 7 | |
|---|
| 11 | 8 | #include <linux/kgdb.h> |
|---|
| .. | .. |
|---|
| 192 | 189 | instruction_pointer(regs) = ip; |
|---|
| 193 | 190 | } |
|---|
| 194 | 191 | |
|---|
| 195 | | -static void kgdb_call_nmi_hook(void *ignored) |
|---|
| 192 | +void kgdb_call_nmi_hook(void *ignored) |
|---|
| 196 | 193 | { |
|---|
| 194 | + /* Default implementation passes get_irq_regs() but we don't */ |
|---|
| 197 | 195 | kgdb_nmicallback(raw_smp_processor_id(), NULL); |
|---|
| 198 | 196 | } |
|---|
| 199 | 197 | |
|---|
| 200 | | -void kgdb_roundup_cpus(unsigned long flags) |
|---|
| 201 | | -{ |
|---|
| 202 | | - local_irq_enable(); |
|---|
| 203 | | - smp_call_function(kgdb_call_nmi_hook, NULL, 0); |
|---|
| 204 | | - local_irq_disable(); |
|---|
| 205 | | -} |
|---|
| 206 | | - |
|---|
| 207 | | -struct kgdb_arch arch_kgdb_ops = { |
|---|
| 198 | +const struct kgdb_arch arch_kgdb_ops = { |
|---|
| 208 | 199 | /* breakpoint instruction: TRAP_S 0x3 */ |
|---|
| 209 | 200 | #ifdef CONFIG_CPU_BIG_ENDIAN |
|---|
| 210 | 201 | .gdb_bpt_instr = {0x78, 0x7e}, |
|---|