Hi,
I'm working on a ATSAMA5D2 platform and I have problems in debugging code that runs in secure monitor CPU mode. Stepping in the code I received the following message on JLinkGDBServer console:
…
ERROR: _RegNumber2RegIndex: Illegal CPU Mode
Reading all registers
WARNING: Register with index 74 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 75 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 76 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 77 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 78 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 79 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 80 could not be read. Reason: CPSR indicates a non-valid CPU mode.
…
Since gdb should be unaware of the CPU mode, I think that the issue is related to JLinkGDBServer.
For your info, below I report the startup message:
Display All
I have also tried the v6.22a, but the results were the same.
Can you help with it?
Kind regards,
Isidoro
I'm working on a ATSAMA5D2 platform and I have problems in debugging code that runs in secure monitor CPU mode. Stepping in the code I received the following message on JLinkGDBServer console:
…
ERROR: _RegNumber2RegIndex: Illegal CPU Mode
Reading all registers
WARNING: Register with index 74 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 75 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 76 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 77 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 78 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 79 could not be read. Reason: CPSR indicates a non-valid CPU mode.
WARNING: Register with index 80 could not be read. Reason: CPSR indicates a non-valid CPU mode.
…
Since gdb should be unaware of the CPU mode, I think that the issue is related to JLinkGDBServer.
For your info, below I report the startup message:
Source Code
- SEGGER J-Link GDB Server V6.16c Command Line Version
- JLinkARM.dll V6.16c (DLL compiled Jun 16 2017 18:16:10)
- -----GDB Server start settings-----
- GDBInit file: none
- GDB Server Listening port: 2331
- SWO raw output listening port: 2332
- Terminal I/O port: 2333
- Accept remote connection: yes
- Generate logfile: off
- Verify download: off
- Init regs on start: off
- Silent mode: off
- Single run mode: off
- Target connection timeout: 0 ms
- ------J-Link related settings------
- J-Link Host interface: USB
- J-Link script: none
- J-Link settings file: none
- ------Target related settings------
- Target device: ATSAMA5D27
- Target interface: JTAG
- Target interface speed: 1000kHz
- Target endian: little
- Connecting to J-Link...
- J-Link is connected.
- Firmware: J-Link V9 compiled Jun 16 2017 16:15:10
- Hardware: V9.40
- SAM-ICE found !
- S/N: 29425334
- OEM: SAM-ICE
- Feature(s): RDI, GDB
- Checking target voltage...
- Target voltage: 3.28 V
- Listening on TCP/IP port 2331
- Connecting to target...
- J-Link found 1 JTAG device, Total IRLen = 4
- JTAG ID: 0x5BA00477 (Cortex-A5)
- Connected to target
- Waiting for GDB connection...Connected to 127.0.0.1
I have also tried the v6.22a, but the results were the same.
Can you help with it?
Kind regards,
Isidoro