qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-arm@nongnu.org, qemu-devel@nongnu.org,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>
Subject: Re: [PATCH v2 1/7] target/microblaze: Use 'obj' in DEVICE() casts in mb_cpu_initfn()
Date: Tue, 29 Apr 2025 17:59:49 +0200	[thread overview]
Message-ID: <aBD3dXFuQCDSgSBF@zapote> (raw)
In-Reply-To: <20250429132200.605611-2-peter.maydell@linaro.org>

On Tue, Apr 29, 2025 at 02:21:54PM +0100, Peter Maydell wrote:
> We're about to make a change that removes the only other use
> of the 'cpu' local variable in mb_cpu_initfn(); since the
> DEVICE() casts work fine with the Object*, use that instead,
> so that we can remove the local variable when we make the
> following change.
>

Reviewed-by: Edgar E. Iglesias <edgar.iglesias@amd.com>


> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
>  target/microblaze/cpu.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/target/microblaze/cpu.c b/target/microblaze/cpu.c
> index 00a2730de4d..d92a43191bd 100644
> --- a/target/microblaze/cpu.c
> +++ b/target/microblaze/cpu.c
> @@ -333,11 +333,11 @@ static void mb_cpu_initfn(Object *obj)
>  
>  #ifndef CONFIG_USER_ONLY
>      /* Inbound IRQ and FIR lines */
> -    qdev_init_gpio_in(DEVICE(cpu), microblaze_cpu_set_irq, 2);
> -    qdev_init_gpio_in_named(DEVICE(cpu), mb_cpu_ns_axi_dp, "ns_axi_dp", 1);
> -    qdev_init_gpio_in_named(DEVICE(cpu), mb_cpu_ns_axi_ip, "ns_axi_ip", 1);
> -    qdev_init_gpio_in_named(DEVICE(cpu), mb_cpu_ns_axi_dc, "ns_axi_dc", 1);
> -    qdev_init_gpio_in_named(DEVICE(cpu), mb_cpu_ns_axi_ic, "ns_axi_ic", 1);
> +    qdev_init_gpio_in(DEVICE(obj), microblaze_cpu_set_irq, 2);
> +    qdev_init_gpio_in_named(DEVICE(obj), mb_cpu_ns_axi_dp, "ns_axi_dp", 1);
> +    qdev_init_gpio_in_named(DEVICE(obj), mb_cpu_ns_axi_ip, "ns_axi_ip", 1);
> +    qdev_init_gpio_in_named(DEVICE(obj), mb_cpu_ns_axi_dc, "ns_axi_dc", 1);
> +    qdev_init_gpio_in_named(DEVICE(obj), mb_cpu_ns_axi_ic, "ns_axi_ic", 1);
>  #endif
>  
>      /* Restricted 'endianness' property is equivalent of 'little-endian' */
> -- 
> 2.43.0
> 


  parent reply	other threads:[~2025-04-29 16:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-29 13:21 [PATCH v2 0/7] target/arm: Remove TYPE_AARCH64_CPU class Peter Maydell
2025-04-29 13:21 ` [PATCH v2 1/7] target/microblaze: Use 'obj' in DEVICE() casts in mb_cpu_initfn() Peter Maydell
2025-04-29 14:59   ` Philippe Mathieu-Daudé
2025-04-29 15:59   ` Edgar E. Iglesias [this message]
2025-04-30 17:19   ` Richard Henderson
2025-04-29 13:21 ` [PATCH v2 2/7] target/microblaze: Delay gdb_register_coprocessor() to realize Peter Maydell
2025-04-29 16:00   ` Edgar E. Iglesias
2025-04-30 17:19   ` Richard Henderson
2025-05-01 19:40   ` Philippe Mathieu-Daudé
2025-04-29 13:21 ` [PATCH v2 3/7] hw/core/cpu-common: Don't init gdbstub until cpu_exec_realizefn() Peter Maydell
2025-04-29 16:03   ` Edgar E. Iglesias
2025-04-30 17:19   ` Richard Henderson
2025-05-01 13:09   ` Alex Bennée
2025-05-01 19:39   ` Philippe Mathieu-Daudé
2025-04-29 13:21 ` [PATCH v2 4/7] target/arm: Present AArch64 gdbstub based on ARM_FEATURE_AARCH64 Peter Maydell
2025-04-30 17:19   ` Richard Henderson
2025-04-29 13:21 ` [PATCH v2 5/7] target/arm: Move aarch64 CPU property code to TYPE_ARM_CPU Peter Maydell
2025-04-30 17:21   ` Richard Henderson
2025-04-29 13:21 ` [PATCH v2 6/7] target/arm/kvm: don't check TYPE_AARCH64_CPU Peter Maydell
2025-04-30 17:21   ` Richard Henderson
2025-04-29 13:22 ` [PATCH v2 7/7] target/arm: Remove TYPE_AARCH64_CPU Peter Maydell
2025-04-30 17:21   ` Richard Henderson

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=aBD3dXFuQCDSgSBF@zapote \
    --to=edgar.iglesias@gmail.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@linaro.org \
    --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).