qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <richard.henderson@linaro.org>
To: Ilya Leoshkevich <iii@linux.ibm.com>,
	Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org, Peter Maydell <peter.maydell@linaro.org>
Subject: Re: [PATCH RFC 1/1] tcg: Always pass the full write size to notdirty_write()
Date: Tue, 8 Aug 2023 07:23:18 -0700	[thread overview]
Message-ID: <edb568b4-017f-3a75-dd07-7556438779f8@linaro.org> (raw)
In-Reply-To: <309ee7ed61a0185c687ae184692198b3c2989970.camel@linux.ibm.com>

On 8/8/23 02:59, Ilya Leoshkevich wrote:
> On Mon, 2023-08-07 at 11:21 -0700, Richard Henderson wrote:
>> IIRC there are some uses of probe_access_* that set size == 0.
>> Should we adjust addr+size to cover the whole page for that case?
>> That seems to be the intent, anyway.
> 
> There is a comment that says we shouldn't do watchpoint/smc detection
> in this case:
> 
>      /* Per the interface, size == 0 merely faults the access. */
>      if (size == 0) {
>          return NULL;
>      }
> 
> Come to think of it, qemu-user works this way too: SMC is detected on
> the actual access, not the probe:
> 
>      helper_vstl()
>        cpu_stq_be_data_ra()
>          ...
>             stq_he_p()
>               <signal handler called>
>                 host_signal_handler()
>                   handle_sigsegv_accerr_write()
>                     page_unprotect()
>                       tb_invalidate_phys_page_unwind()
>                     cpu_loop_exit_noexc()
> 
> So all this is probably fine, I now think it's better to leave the code
> as is, especially given that I cannot reproduce the original problem
> anymore.

Ok then.


r~


      reply	other threads:[~2023-08-08 14:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-07 13:56 [PATCH RFC 0/1] tcg: Always pass the full write size to notdirty_write() Ilya Leoshkevich
2023-08-07 13:56 ` [PATCH RFC 1/1] " Ilya Leoshkevich
2023-08-07 18:21   ` Richard Henderson
2023-08-08  9:59     ` Ilya Leoshkevich
2023-08-08 14:23       ` Richard Henderson [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=edb568b4-017f-3a75-dd07-7556438779f8@linaro.org \
    --to=richard.henderson@linaro.org \
    --cc=iii@linux.ibm.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.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).