qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance
@ 2018-03-07 13:02 Paolo Bonzini
  2018-03-07 13:23 ` Cornelia Huck
  2018-03-07 13:29 ` Thomas Huth
  0 siblings, 2 replies; 4+ messages in thread
From: Paolo Bonzini @ 2018-03-07 13:02 UTC (permalink / raw)
  To: qemu-devel; +Cc: thuth, cohuck, intermediadc

Fixes: 11e732a5ed46903f997985bed4c3767ca28a7eb6
Reported-by: Cornelia Huck <cohuck@redhat.com>
Reported-by: luigi burdo <intermediadc@hotmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 exec.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/exec.c b/exec.c
index 604f03c535..a9181e6417 100644
--- a/exec.c
+++ b/exec.c
@@ -3393,7 +3393,6 @@ static bool flatview_access_valid(FlatView *fv, hwaddr addr, int len,
         if (!memory_access_is_direct(mr, is_write)) {
             l = memory_access_size(mr, l, addr);
             if (!memory_region_access_valid(mr, xlat, l, is_write)) {
-                rcu_read_unlock();
                 return false;
             }
         }
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance
  2018-03-07 13:02 [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance Paolo Bonzini
@ 2018-03-07 13:23 ` Cornelia Huck
  2018-03-07 13:29 ` Thomas Huth
  1 sibling, 0 replies; 4+ messages in thread
From: Cornelia Huck @ 2018-03-07 13:23 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: qemu-devel, thuth, intermediadc

On Wed,  7 Mar 2018 14:02:38 +0100
Paolo Bonzini <pbonzini@redhat.com> wrote:

> Fixes: 11e732a5ed46903f997985bed4c3767ca28a7eb6
> Reported-by: Cornelia Huck <cohuck@redhat.com>
> Reported-by: luigi burdo <intermediadc@hotmail.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  exec.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/exec.c b/exec.c
> index 604f03c535..a9181e6417 100644
> --- a/exec.c
> +++ b/exec.c
> @@ -3393,7 +3393,6 @@ static bool flatview_access_valid(FlatView *fv, hwaddr addr, int len,
>          if (!memory_access_is_direct(mr, is_write)) {
>              l = memory_access_size(mr, l, addr);
>              if (!memory_region_access_valid(mr, xlat, l, is_write)) {
> -                rcu_read_unlock();
>                  return false;
>              }
>          }

Thanks, that fixes master for me.

Tested-by: Cornelia Huck <cohuck@redhat.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance
  2018-03-07 13:02 [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance Paolo Bonzini
  2018-03-07 13:23 ` Cornelia Huck
@ 2018-03-07 13:29 ` Thomas Huth
  2018-03-09 16:42   ` Peter Maydell
  1 sibling, 1 reply; 4+ messages in thread
From: Thomas Huth @ 2018-03-07 13:29 UTC (permalink / raw)
  To: Paolo Bonzini, qemu-devel; +Cc: cohuck, intermediadc

On 07.03.2018 14:02, Paolo Bonzini wrote:
> Fixes: 11e732a5ed46903f997985bed4c3767ca28a7eb6
> Reported-by: Cornelia Huck <cohuck@redhat.com>
> Reported-by: luigi burdo <intermediadc@hotmail.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  exec.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/exec.c b/exec.c
> index 604f03c535..a9181e6417 100644
> --- a/exec.c
> +++ b/exec.c
> @@ -3393,7 +3393,6 @@ static bool flatview_access_valid(FlatView *fv, hwaddr addr, int len,
>          if (!memory_access_is_direct(mr, is_write)) {
>              l = memory_access_size(mr, l, addr);
>              if (!memory_region_access_valid(mr, xlat, l, is_write)) {
> -                rcu_read_unlock();
>                  return false;
>              }
>          }
> 

Thanks, this seems to fix the problem with the sam640ex and 40p machines.

Tested-by: Thomas Huth <thuth@redhat.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance
  2018-03-07 13:29 ` Thomas Huth
@ 2018-03-09 16:42   ` Peter Maydell
  0 siblings, 0 replies; 4+ messages in thread
From: Peter Maydell @ 2018-03-09 16:42 UTC (permalink / raw)
  To: Thomas Huth; +Cc: Paolo Bonzini, QEMU Developers, luigi burdo, Cornelia Huck

On 7 March 2018 at 13:29, Thomas Huth <thuth@redhat.com> wrote:
> On 07.03.2018 14:02, Paolo Bonzini wrote:
>> Fixes: 11e732a5ed46903f997985bed4c3767ca28a7eb6
>> Reported-by: Cornelia Huck <cohuck@redhat.com>
>> Reported-by: luigi burdo <intermediadc@hotmail.com>
>> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
>> ---
>>  exec.c | 1 -
>>  1 file changed, 1 deletion(-)
>>
>> diff --git a/exec.c b/exec.c
>> index 604f03c535..a9181e6417 100644
>> --- a/exec.c
>> +++ b/exec.c
>> @@ -3393,7 +3393,6 @@ static bool flatview_access_valid(FlatView *fv, hwaddr addr, int len,
>>          if (!memory_access_is_direct(mr, is_write)) {
>>              l = memory_access_size(mr, l, addr);
>>              if (!memory_region_access_valid(mr, xlat, l, is_write)) {
>> -                rcu_read_unlock();
>>                  return false;
>>              }
>>          }
>>
>
> Thanks, this seems to fix the problem with the sam640ex and 40p machines.
>
> Tested-by: Thomas Huth <thuth@redhat.com>

Thanks, applied to master since I ran into this too.

-- PMM

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-03-09 16:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-07 13:02 [Qemu-devel] [PATCH] memory: fix flatview_access_valid RCU read lock/unlock imbalance Paolo Bonzini
2018-03-07 13:23 ` Cornelia Huck
2018-03-07 13:29 ` Thomas Huth
2018-03-09 16:42   ` Peter Maydell

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).