Skip to content

Commit

Permalink
rtt: correct enum type naming
Browse files Browse the repository at this point in the history
  • Loading branch information
perigoso authored and dragonmux committed Jan 4, 2023
1 parent 0bfcb32 commit 9891514
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/rtt.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ typedef enum rtt_retval {
RTT_OK,
RTT_IDLE,
RTT_ERR
} rtt_retval;
} rtt_retval_e;

#ifdef RTT_IDENT
#define Q(x) #x
Expand Down Expand Up @@ -220,7 +220,7 @@ static void find_rtt(target_s *const cur_target)
*/

/* poll if host has new data for target */
static rtt_retval read_rtt(target_s *const cur_target, const uint32_t i)
static rtt_retval_e read_rtt(target_s *const cur_target, const uint32_t i)
{
uint32_t head_addr = 0;
uint32_t next_head;
Expand Down Expand Up @@ -286,7 +286,7 @@ int rtt_aligned_mem_read(target_s *t, void *dest, target_addr_t src, size_t len)
}

/* poll if target has new data for host */
static rtt_retval print_rtt(target_s *const cur_target, const uint32_t i)
static rtt_retval_e print_rtt(target_s *const cur_target, const uint32_t i)
{
uint32_t tail_addr;

Expand Down Expand Up @@ -392,7 +392,7 @@ void poll_rtt(target_s *const cur_target)
rtt_err = true;
} else {
for (uint32_t i = 0; i < rtt_num_up_chan + rtt_num_down_chan; i++) {
rtt_retval v;
rtt_retval_e v;
if (rtt_channel_enabled[i]) {
if (i < rtt_num_up_chan)
v = print_rtt(cur_target, i); /* rtt from target to host */
Expand Down

0 comments on commit 9891514

Please sign in to comment.