Skip to content

Commit 4ec2707

Browse files
mcaylandvivier
authored andcommitted
macfb: add trace events for reading and writing the control registers
Signed-off-by: Mark Cave-Ayland <[email protected]> Reviewed-by: Philippe Mathieu-Daudé <[email protected]> Reviewed-by: Laurent Vivier <[email protected]> Message-Id: <[email protected]> Signed-off-by: Laurent Vivier <[email protected]>
1 parent 3b10b56 commit 4ec2707

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

hw/display/macfb.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
#include "qapi/error.h"
2121
#include "hw/qdev-properties.h"
2222
#include "migration/vmstate.h"
23+
#include "trace.h"
2324

2425
#define VIDEO_BASE 0x00001000
2526
#define DAFB_BASE 0x00800000
@@ -289,7 +290,10 @@ static uint64_t macfb_ctrl_read(void *opaque,
289290
hwaddr addr,
290291
unsigned int size)
291292
{
292-
return 0;
293+
uint64_t val = 0;
294+
295+
trace_macfb_ctrl_read(addr, val, size);
296+
return val;
293297
}
294298

295299
static void macfb_ctrl_write(void *opaque,
@@ -311,6 +315,8 @@ static void macfb_ctrl_write(void *opaque,
311315
}
312316
break;
313317
}
318+
319+
trace_macfb_ctrl_write(addr, val, size);
314320
}
315321

316322
static const MemoryRegionOps macfb_ctrl_ops = {

hw/display/trace-events

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,3 +167,7 @@ sm501_disp_ctrl_read(uint32_t addr, uint32_t val) "addr=0x%x, val=0x%x"
167167
sm501_disp_ctrl_write(uint32_t addr, uint32_t val) "addr=0x%x, val=0x%x"
168168
sm501_2d_engine_read(uint32_t addr, uint32_t val) "addr=0x%x, val=0x%x"
169169
sm501_2d_engine_write(uint32_t addr, uint32_t val) "addr=0x%x, val=0x%x"
170+
171+
# macfb.c
172+
macfb_ctrl_read(uint64_t addr, uint64_t value, unsigned int size) "addr 0x%"PRIx64 " value 0x%"PRIx64 " size %u"
173+
macfb_ctrl_write(uint64_t addr, uint64_t value, unsigned int size) "addr 0x%"PRIx64 " value 0x%"PRIx64 " size %u"

0 commit comments

Comments
 (0)