From: David Hildenbrand <david@redhat.com>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: Pankaj Gupta <pankaj.gupta.linux@gmail.com>,
Eduardo Habkost <ehabkost@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
qemu-devel@nongnu.org,
"Dr . David Alan Gilbert" <dgilbert@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>,
Igor Mammedov <imammedo@redhat.com>,
Marek Kedzierski <mkedzier@redhat.com>
Subject: Re: [PATCH v1 3/3] util/oslib-posix: Support concurrent os_mem_prealloc() invocation
Date: Tue, 20 Jul 2021 16:35:59 +0200 [thread overview]
Message-ID: <6da6fe82-d3b6-1996-32e2-71848c4f9157@redhat.com> (raw)
In-Reply-To: <YPbeX8XASYP4eZTk@redhat.com>
>>>
>>> Of course with the madvise impl we're bypassing the SIGBUS
>>> dance entirely. This is good for people with new kernels,
>>> but is this SIGBUS stuff safe for older kernels ?
>>
>> It remains broken with old kernels I guess. There isn't too much that we can
>> do: disabling prealloc=on once the VM is running breaks existing use cases.
>
> Ok, while refactoring this, could you add a scary warning next to the
> sigaction calls mentioning that this code is not likely to play well
> with qemu's other handling of sigbus, as a reminder to future reviewers.
Sure thing!
>
>> Fortunately, running into that race seems to be rare, at least I never hear
>> reports.
>
> The failure mode is likely to be silent or easily mis-interpreted
>
> Is there any value in emitting a one-time per process warning message
> on stderr if we take the old codepath post-startup ?
Will look into emitting a warning when running this code while the VM is
already running. (hope it won't be too ugly to have vm state checks in
util/oslib-posix).
--
Thanks,
David / dhildenb
next prev parent reply other threads:[~2021-07-20 14:37 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-14 11:23 [PATCH v1 0/3] util/oslib-posix: Support MADV_POPULATE_WRITE for os_mem_prealloc() David Hildenbrand
2021-07-14 11:23 ` [PATCH v1 1/3] " David Hildenbrand
2021-07-20 14:08 ` Daniel P. Berrangé
2021-07-20 14:34 ` David Hildenbrand
2021-07-14 11:23 ` [PATCH v1 2/3] util/oslib-posix: Introduce and use MemsetContext for touch_all_pages() David Hildenbrand
2021-07-20 14:27 ` Daniel P. Berrangé
2021-07-14 11:23 ` [PATCH v1 3/3] util/oslib-posix: Support concurrent os_mem_prealloc() invocation David Hildenbrand
2021-07-20 14:22 ` Daniel P. Berrangé
2021-07-20 14:27 ` David Hildenbrand
2021-07-20 14:31 ` Daniel P. Berrangé
2021-07-20 14:35 ` David Hildenbrand [this message]
2021-07-20 13:55 ` [PATCH v1 0/3] util/oslib-posix: Support MADV_POPULATE_WRITE for os_mem_prealloc() Pankaj Gupta
2021-07-20 13:58 ` Pankaj Gupta
2021-07-20 14:45 ` Daniel P. Berrangé
2021-07-21 8:23 ` David Hildenbrand
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=6da6fe82-d3b6-1996-32e2-71848c4f9157@redhat.com \
--to=david@redhat.com \
--cc=berrange@redhat.com \
--cc=dgilbert@redhat.com \
--cc=ehabkost@redhat.com \
--cc=imammedo@redhat.com \
--cc=mkedzier@redhat.com \
--cc=mst@redhat.com \
--cc=pankaj.gupta.linux@gmail.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).