Commit bbae0376 authored by Jens Korinth's avatar Jens Korinth
Browse files

Implement reading of status core regs for memories

parent 052a692a
Pipeline #146 passed with stage
in 3 minutes and 14 seconds
......@@ -30,6 +30,7 @@
typedef struct tapasco_status tapasco_status_t;
struct tapasco_status {
tapasco_func_id_t id[TAPASCO_MAX_INSTANCES];
size_t mem[TAPASCO_MAX_INSTANCES];
uint32_t gen_ts;
uint32_t vivado_version;
uint32_t tapasco_version;
......
......@@ -94,6 +94,15 @@ static tapasco_res_t read_tapasco_status(tapasco_status_t **status)
platform_read_ctl(h, sizeof(d), &d, PLATFORM_CTL_FLAGS_NONE);
LOG(LALL_STATUS, "slot %u has kernel with id %u", i, d);
(*status)->id[i] = d;
if ((*status)->cap0_flags & TAPASCO_CAP0_PE_LOCAL_MEM) {
platform_read_ctl(h + 4, sizeof((*status)->mem[i]),
&(*status)->mem[i],
PLATFORM_CTL_FLAGS_NONE);
if ((*status)->mem[i] > 0) {
LOG(LALL_STATUS, "slot %u has %u bytes of memory", i, d);
}
}
}
return TAPASCO_SUCCESS;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment