From: Ashijeet Acharya <ashijeetacharya@gmail.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: John Snow <jsnow@redhat.com>, QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] Dangling change state handler while hot unplugging ahci adapter
Date: Thu, 11 Aug 2016 22:10:27 +0530 [thread overview]
Message-ID: <CAC2QTZafK2MhBRYG8TpGd3m07GR6M2jFi22KeMKf4D5JYyiz9Q@mail.gmail.com> (raw)
In-Reply-To: <777265882.1234102.1470933253966.JavaMail.zimbra@redhat.com>
On Thu, Aug 11, 2016 at 10:04 PM, Paolo Bonzini <pbonzini@redhat.com> wrote:
>
>> I think we should do
>>
>> s->vmstate = qemu_add_vm_change_state_handler(ide_restart_cb, bus);
>> instead of
>> qemu_add_vm_change_state_handler(ide_restart_cb, bus);
>>
>> in ide_register_restart_cb() in hw/ide/core.c to store the returned
>> pointer to memory to avoid a possible memory leak I guess and
>> introduce a VMChangeStateEntry field in struct AHCIState to handle
>> this. Same can then further be used with
>> qemu_del_vm_change_state_handler() in ahci_unrealize() to free things
>> up.
>
> Yes, this is correct. Thanks!
>
Alright I will make these changes and include them in my patch.
Ashijeet
> Paolo
next prev parent reply other threads:[~2016-08-11 16:40 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-06 17:51 [Qemu-devel] Dangling change state handler while hot unplugging ahci adapter Ashijeet Acharya
2016-08-09 17:16 ` Ashijeet Acharya
2016-08-09 18:18 ` John Snow
2016-08-10 5:42 ` Ashijeet Acharya
2016-08-11 8:20 ` Ashijeet Acharya
2016-08-11 16:20 ` Ashijeet Acharya
2016-08-11 16:34 ` Paolo Bonzini
2016-08-11 16:40 ` Ashijeet Acharya [this message]
2016-08-11 18:45 ` [Qemu-devel] [PATCH] Fix memory leak in ide_register_restart_cb() Ashijeet Acharya
2016-08-12 9:58 ` Paolo Bonzini
2016-08-16 13:55 ` Ashijeet Acharya
2016-08-16 17:08 ` John Snow
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=CAC2QTZafK2MhBRYG8TpGd3m07GR6M2jFi22KeMKf4D5JYyiz9Q@mail.gmail.com \
--to=ashijeetacharya@gmail.com \
--cc=jsnow@redhat.com \
--cc=pbonzini@redhat.com \
--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).