qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Laurent Vivier <laurent@vivier.eu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>, qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, Sarah Harris <S.E.Harris@kent.ac.uk>,
	Michael Rolnik <mrolnik@gmail.com>
Subject: Re: [PATCH] target/avr/cpu: Use device_class_set_parent_realize()
Date: Sun, 14 Feb 2021 00:33:05 +0100	[thread overview]
Message-ID: <fcdf4265-0c39-6d19-1ebf-3515d073f39a@vivier.eu> (raw)
In-Reply-To: <20210201080348.438095-1-f4bug@amsat.org>

Le 01/02/2021 à 09:03, Philippe Mathieu-Daudé a écrit :
> Change generated automatically using the Coccinelle
> patch included in commit bf853881690 ("qdev: use
> device_class_set_parent_realize/unrealize/reset()")
> 
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
>  target/avr/cpu.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/target/avr/cpu.c b/target/avr/cpu.c
> index 6f3d5a9e4a7..e60036e41ef 100644
> --- a/target/avr/cpu.c
> +++ b/target/avr/cpu.c
> @@ -190,9 +190,7 @@ static void avr_cpu_class_init(ObjectClass *oc, void *data)
>      CPUClass *cc = CPU_CLASS(oc);
>      AVRCPUClass *mcc = AVR_CPU_CLASS(oc);
>  
> -    mcc->parent_realize = dc->realize;
> -    dc->realize = avr_cpu_realizefn;
> -
> +    device_class_set_parent_realize(dc, avr_cpu_realizefn, &mcc->parent_realize);
>      device_class_set_parent_reset(dc, avr_cpu_reset, &mcc->parent_reset);
>  
>      cc->class_by_name = avr_cpu_class_by_name;
> 


Applied to my trivial-patches branch.

Thanks,
Laurent


      parent reply	other threads:[~2021-02-13 23:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-01  8:03 [PATCH] target/avr/cpu: Use device_class_set_parent_realize() Philippe Mathieu-Daudé
2021-02-03  2:07 ` Richard Henderson
2021-02-13 23:33 ` Laurent Vivier [this message]

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=fcdf4265-0c39-6d19-1ebf-3515d073f39a@vivier.eu \
    --to=laurent@vivier.eu \
    --cc=S.E.Harris@kent.ac.uk \
    --cc=f4bug@amsat.org \
    --cc=mrolnik@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@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).