Skip to content

target/arc + risc-v: add RTT commands #66

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: zephyr-20220611
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/target/arc.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include "target_type.h"
#include "helper/bits.h"
#include "smp.h"
#include "rtt/rtt.h"

#include "arc_jtag.h"
#include "arc_cmd.h"
Expand Down
3 changes: 3 additions & 0 deletions src/target/arc_cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1086,5 +1086,8 @@ const struct command_registration arc_monitor_command_handlers[] = {
.usage = "",
.chain = arc_core_command_handlers,
},
{
.chain = rtt_target_command_handlers,
},
COMMAND_REGISTRATION_DONE
};
4 changes: 4 additions & 0 deletions src/target/riscv/riscv.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include "rtos/rtos.h"
#include "debug_defines.h"
#include <helper/bits.h>
#include <rtt/rtt.h>

#define get_field(reg, mask) (((reg) & (mask)) / ((mask) & ~((mask) << 1)))
#define set_field(reg, mask, val) (((reg) & ~(mask)) | (((val) * ((mask) & ~((mask) << 1))) & (mask)))
Expand Down Expand Up @@ -3131,6 +3132,9 @@ const struct command_registration riscv_command_handlers[] = {
.usage = "",
.chain = semihosting_common_handlers
},
{
.chain = rtt_target_command_handlers,
},
COMMAND_REGISTRATION_DONE
};

Expand Down
Loading