1 /* SPDX-License-Identifier: BSD-3-Clause 2 * 3 * Copyright(c) 2019 Intel Corporation. All rights reserved. 4 * 5 * Author: Marcin Rajwa <marcin.rajwa@linux.intel.com> 6 */ 7 8 #ifndef __SOF_DEBUG_GDB_GDB_H__ 9 #define __SOF_DEBUG_GDB_GDB_H__ 10 11 #include <arch/debug/gdb/init.h> 12 #include <arch/debug/gdb/utilities.h> 13 14 #define GDB_BUFMAX 256 15 #define GDB_NUMBER_OF_REGISTERS 64 16 #define GDB_DISABLE_LOWER_INTERRUPTS_MASK ~0x1F 17 #define GDB_REGISTER_MASK 0xFF 18 #define GDB_FIRST_BYTE_MASK 0xF0000000 19 #define GDB_VALID_MEM_START_BYTE 0xB 20 #define GDB_VALID_MEM_ADDRESS_LEN 0x8 21 #define GDB_AR_REG_RANGE 0x10 /**< identifies registers in current window */ 22 #define GDB_PC_REG_ID 0x20 /**< identifies PC register */ 23 #define GDB_AREG_RANGE 0x100 /**< identifies address registers range */ 24 #define GDB_SPEC_REG_RANGE_START 0x200 /**< identifies spec registers range */ 25 #define GDB_SPEC_REG_RANGE_END 0x300 /**< identifies spec registers range */ 26 #define GDB_REG_RANGE_END 0x400 /**< identifies spec registers range */ 27 28 void gdb_handle_exception(void); 29 void gdb_debug_info(unsigned char *str); 30 void gdb_init_debug_exception(void); 31 void gdb_init(void); 32 33 #endif /* __SOF_DEBUG_GDB_GDB_H__ */ 34