qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/3] hw/rtc/ds1338: Trace send and receive operations


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH 1/3] hw/rtc/ds1338: Trace send and receive operations
Date: Mon, 13 May 2024 13:26:55 +0200
User-agent: Mozilla Thunderbird

On 13/5/24 12:11, Bernhard Beschow wrote:
Signed-off-by: Bernhard Beschow <shentey@gmail.com>
---
  hw/rtc/ds1338.c     | 6 ++++++
  hw/rtc/trace-events | 4 ++++
  2 files changed, 10 insertions(+)


@@ -134,6 +138,8 @@ static int ds1338_send(I2CSlave *i2c, uint8_t data)
  {
      DS1338State *s = DS1338(i2c);
+ trace_ds1338_send(s->ptr, data);


--- a/hw/rtc/trace-events
+++ b/hw/rtc/trace-events
@@ -22,6 +22,10 @@ pl031_set_alarm(uint32_t ticks) "alarm set for %u ticks"
  aspeed_rtc_read(uint64_t addr, uint64_t value) "addr 0x%02" PRIx64 " value 
0x%08" PRIx64
  aspeed_rtc_write(uint64_t addr, uint64_t value) "addr 0x%02" PRIx64 " value 
0x%08" PRIx64
+# ds1338.c
+ds1338_recv(uint32_t addr, uint8_t value) "[0x%" PRIx32 "] -> 0x%02" PRIx8
+ds1338_send(uint32_t addr, uint8_t value) "[0x%" PRIx32 "] <- 0x%02" PRIx8

DS1338State::ptr is signed, although being an offset, odd. Using
unsigned in traces seems better anyway,

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]