• Vincent Chen's avatar
    riscv: Use the XML target descriptions to report 3 system registers · d9657570
    Vincent Chen authored
    The $status, $badaddr, and $cause registers belong to the thread context,
    so KGDB can obtain their contents from pt_regs in each trap. However, the
    sequential number of these registers in the gdb register list is far from
    the general-purpose registers. If riscv port uses the existing method to
    report these three registers, many trivial registers with sequence numbers
    in the middle of them will also be packaged to the reply packets. To solve
    this problem, the riscv port wants to introduce the GDB target description
    mechanism to customize the reported register list. By the list, the KGDB
    can ignore the intermediate registers and just reports the general-purpose
    registers and these three system registers.
    Signed-off-by: default avatarVincent Chen <vincent.chen@sifive.com>
    Signed-off-by: default avatarPalmer Dabbelt <palmerdabbelt@google.com>
    d9657570
gdb_xml.h 5.53 KB