qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH for-6.2 19/25] hw/arm/msf2: Use Clock input to MSF2_SOC inste


From: Alexandre IOOSS
Subject: Re: [PATCH for-6.2 19/25] hw/arm/msf2: Use Clock input to MSF2_SOC instead of m3clk property
Date: Sat, 14 Aug 2021 12:47:43 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0


On 8/14/21 12:11 PM, Peter Maydell wrote:
On Sat, 14 Aug 2021 at 10:20, Alexandre IOOSS <erdnaxe@crans.org> wrote:


On 8/12/21 11:33 AM, Peter Maydell wrote:
Instead of passing the MSF2 SoC an integer property specifying the
CPU clock rate, pass it a Clock instead.  This lets us wire that
clock up to the armv7m object.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

@@ -72,7 +74,10 @@ static void emcraft_sf2_s2s010_init(MachineState *machine)
        * in Libero. CPU clock is divided by APB0 and APB1 divisors for
        * peripherals. Emcraft's SoM kit comes with these settings by default.
        */
-    qdev_prop_set_uint32(dev, "m3clk", 142 * 1000000);
+    /* This clock doesn't need migration because it is fixed-frequency */
+    m3clk = clock_new(OBJECT(machine), "m3clk");
+    clock_set_hz(m3clk, 142 * 1000000);

Maybe something could be added in the commit message to say that M3_CLK
is changed from 100MHz to 142MHz.

I'm not sure what you mean here? This commit doesn't change the frequency:
we previously set the m3clk property to "142 * 1000000" and now we set the
clock's hz setting to the same thing.

My bad, I did not realize the board was already setting the frequency to 142MHz.

Thanks,
-- Alexandre

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


reply via email to

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