From: Peter Maydell <peter.maydell@linaro.org>
To: Damien Hedde <damien.hedde@greensocs.com>
Cc: "Edgar E . Iglesias" <edgar.iglesias@xilinx.com>,
"Daniel P. Berrange" <berrange@redhat.com>,
"Eduardo Habkost" <ehabkost@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Alistair Francis" <alistair@alistair23.me>,
"Mark Burton" <mark.burton@greensocs.com>,
"QEMU Developers" <qemu-devel@nongnu.org>,
qemu-arm <qemu-arm@nongnu.org>,
"Alistair Francis" <alistair.francis@wdc.com>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Edgar E. Iglesias" <edgar.iglesias@gmail.com>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>
Subject: Re: [PATCH v9 1/9] hw/core/clock: introduce clock object
Date: Fri, 17 Apr 2020 15:39:29 +0100 [thread overview]
Message-ID: <CAFEAcA8bA_WoNsT8GEO8ivpmywUPr68XWPHSEK5rXw5LS9Hk8A@mail.gmail.com> (raw)
In-Reply-To: <20200406135251.157596-2-damien.hedde@greensocs.com>
On Mon, 6 Apr 2020 at 14:53, Damien Hedde <damien.hedde@greensocs.com> wrote:
>
> This object may be used to represent a clock inside a clock tree.
>
> A clock may be connected to another clock so that it receives update,
> through a callback, whenever the source/parent clock is updated.
> --- a/hw/core/trace-events
> +++ b/hw/core/trace-events
> @@ -27,3 +27,10 @@ resettable_phase_exit_begin(void *obj, const char *objtype, unsigned count, int
> resettable_phase_exit_exec(void *obj, const char *objtype, int has_method) "obj=%p(%s) method=%d"
> resettable_phase_exit_end(void *obj, const char *objtype, unsigned count) "obj=%p(%s) count=%d"
> resettable_transitional_function(void *obj, const char *objtype) "obj=%p(%s)"
> +
> +# clock.c
> +clock_set_source(const char *clk, const char *src) "'%s', src='%s'"
> +clock_disconnect(const char *clk) "'%s'"
> +clock_set(const char *clk, unsigned long long old, unsigned long long new) "'%s', ns=%llu->%llu"
> +clock_propagate(const char *clk) "'%s'"
> +clock_update(const char *clk, const char *src, unsigned long long val, int cb) "'%s', src='%s', ns=%llu, cb=%d"
"unsigned long long" isn't a valid type to use in a trace event,
it seems: a build with --enable-trace-backends=dtrace will
produce the following warning:
Warning: /usr/bin/dtrace:hw/core/trace-dtrace.dtrace:54: syntax error near:
probe clock_disconnect
Warning: Proceeding as if --no-pyparsing was given.
Using fixed-width types is preferable anyway; squashing in
this fixes it:
diff --git a/hw/core/trace-events b/hw/core/trace-events
index 39301621ce8..1ac60ede6b7 100644
--- a/hw/core/trace-events
+++ b/hw/core/trace-events
@@ -31,6 +31,6 @@ resettable_transitional_function(void *obj, const
char *objtype) "obj=%p(%s)"
# clock.c
clock_set_source(const char *clk, const char *src) "'%s', src='%s'"
clock_disconnect(const char *clk) "'%s'"
-clock_set(const char *clk, unsigned long long old, unsigned long long
new) "'%s', ns=%llu->%llu"
+clock_set(const char *clk, uint64_t old, uint64_t new) "'%s',
ns=%"PRIu64"->%"PRIu64
clock_propagate(const char *clk) "'%s'"
-clock_update(const char *clk, const char *src, unsigned long long
val, int cb) "'%s', src='%s', ns=%llu, cb=%d"
+clock_update(const char *clk, const char *src, uint64_t val, int cb)
"'%s', src='%s', ns=%"PRIu64", cb=%d"
thanks
-- PMM
next prev parent reply other threads:[~2020-04-17 14:40 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-06 13:52 [PATCH v9 0/9] Clock framework API Damien Hedde
2020-04-06 13:52 ` [PATCH v9 1/9] hw/core/clock: introduce clock object Damien Hedde
2020-04-17 14:39 ` Peter Maydell [this message]
2020-04-06 13:52 ` [PATCH v9 2/9] hw/core/clock-vmstate: define a vmstate entry for clock state Damien Hedde
2020-04-06 13:52 ` [PATCH v9 3/9] qdev: add clock input&output support to devices Damien Hedde
2020-04-06 13:52 ` [PATCH v9 4/9] qdev-clock: introduce an init array to ease the device construction Damien Hedde
2020-04-06 13:52 ` [PATCH v9 5/9] docs/clocks: add device's clock documentation Damien Hedde
2020-04-07 5:07 ` Markus Armbruster
2020-04-08 10:06 ` Damien Hedde
2020-04-14 7:15 ` Markus Armbruster
2020-04-17 15:52 ` Peter Maydell
2020-04-17 16:52 ` Damien Hedde
2020-04-06 13:52 ` [PATCH v9 6/9] hw/misc/zynq_slcr: add clock generation for uarts Damien Hedde
2020-04-06 13:52 ` [PATCH v9 7/9] hw/char/cadence_uart: add clock support Damien Hedde
2020-04-06 13:52 ` [PATCH v9 8/9] hw/arm/xilinx_zynq: connect uart clocks to slcr Damien Hedde
2020-04-06 13:52 ` [PATCH v9 9/9] qdev-monitor: print the device's clock with info qtree Damien Hedde
2020-04-17 17:45 ` [PATCH v9 0/9] Clock framework API Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAFEAcA8bA_WoNsT8GEO8ivpmywUPr68XWPHSEK5rXw5LS9Hk8A@mail.gmail.com \
--to=peter.maydell@linaro.org \
--cc=alistair.francis@wdc.com \
--cc=alistair@alistair23.me \
--cc=berrange@redhat.com \
--cc=damien.hedde@greensocs.com \
--cc=edgar.iglesias@gmail.com \
--cc=edgar.iglesias@xilinx.com \
--cc=ehabkost@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=mark.burton@greensocs.com \
--cc=pbonzini@redhat.com \
--cc=philmd@redhat.com \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).