qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] 521ed6: target/arm: Remove workaround for sma


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] 521ed6: target/arm: Remove workaround for small SAU region...
Date: Tue, 13 Nov 2018 03:45:03 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 521ed6b4015ba39a2e39c65a94643f3e6412edc4
      
https://github.com/qemu/qemu/commit/521ed6b4015ba39a2e39c65a94643f3e6412edc4
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/helper.c

  Log Message:
  -----------
  target/arm: Remove workaround for small SAU regions

Before we supported direct execution from MMIO regions, we
implemented workarounds in commit 720424359917887c926a33d2
which let us avoid doing so, even if the SAU or MPU region
was less than page-sized.

Once we implemented execute-from-MMIO, we removed part
of those workarounds in commit d4b6275df320cee76; but
we forgot the one in get_phys_addr_pmsav8() which
suppressed use of small SAU regions in executable regions.
Remove that workaround now.

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden


  Commit: e24ad484909e7a00ca4f6332f3698facf0ba3394
      
https://github.com/qemu/qemu/commit/e24ad484909e7a00ca4f6332f3698facf0ba3394
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/helper.c

  Log Message:
  -----------
  target/arm: Remove antique TODO comment

Remove a TODO comment about implementing the vectored interrupt
controller. We have had an implementation of that for a decade;
it's in hw/intc/pl190.c.

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>


  Commit: 671f11b2043803bbb795518d411b010a785a47db
      
https://github.com/qemu/qemu/commit/671f11b2043803bbb795518d411b010a785a47db
  Author: Thomas Huth <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M MAINTAINERS

  Log Message:
  -----------
  MAINTAINERS: Add an entry for the 'collie' machine

There is no active maintainer, but since Peter is picking up
patches via address@hidden, I think we could at least use
"Odd Fixes" as status here.

Signed-off-by: Thomas Huth <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Message-id: address@hidden
[PMM: Also add myself as an M: contact]
Signed-off-by: Peter Maydell <address@hidden>


  Commit: e9ac8e84f0603f13220aa856b0ee24df64d9686c
      
https://github.com/qemu/qemu/commit/e9ac8e84f0603f13220aa856b0ee24df64d9686c
  Author: Eric Auger <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M hw/arm/sysbus-fdt.c

  Log Message:
  -----------
  hw/arm/sysbus-fdt: Only call match_fn callback if the type matches

Commit af7d64ede0b9 (hw/arm/sysbus-fdt: Allow device matching with DT
compatible value) introduced a match_fn callback which gets called
for each registered combo to check whether a sysbus device can be
dynamically instantiated. However the callback gets called even if
the device type does not match the binding combo typename field.
This causes an assert when passing "-device ramfb" to the qemu
command line as vfio_platform_match() gets called on a non
vfio-platform device.

To fix this regression, let's change the add_fdt_node() logic so
that we first check the type and if the match_fn callback is defined,
then we also call it.

Binding combos only requesting a type check do not define the
match_fn callback.

Fixes: af7d64ede0b9 (hw/arm/sysbus-fdt: Allow device matching with
DT compatible value)

Signed-off-by: Eric Auger <address@hidden>
Reported-by: Thomas Huth <address@hidden>
Reviewed-by: Alex Williamson <address@hidden>
Tested-by: Geert Uytterhoeven <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: 09a86dfa3f07904792a85990b0b41939417785cd
      
https://github.com/qemu/qemu/commit/09a86dfa3f07904792a85990b0b41939417785cd
  Author: Richard Henderson <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/helper.c

  Log Message:
  -----------
  target/arm: Fix typo in tlbi_aa64_vmalle1_write

This would cause an infinite recursion or loop.

Signed-off-by: Richard Henderson <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
Message-id: address@hidden
Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Peter Maydell <address@hidden>


  Commit: 864df2058d01d65244e5f91cdf0c4784df242ca2
      
https://github.com/qemu/qemu/commit/864df2058d01d65244e5f91cdf0c4784df242ca2
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/kvm64.c

  Log Message:
  -----------
  target/arm64: properly handle DBGVR RESS bits

This only fails with some (broken) versions of gdb but we should
treat the top bits of DBGBVR as RESS. Properly sign extend QEMU's
reference copy of dbgbvr and also update the register descriptions in
the comment.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: 9b16ec4351a6379b31898ec5871b7e5c29376c3c
      
https://github.com/qemu/qemu/commit/9b16ec4351a6379b31898ec5871b7e5c29376c3c
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/kvm64.c

  Log Message:
  -----------
  target/arm64: hold BQL when calling do_interrupt()

Fix the assertion failure when running interrupts.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: 14f9a5c0e4d2bc06cb217a84d836badfe9dc7a18
      
https://github.com/qemu/qemu/commit/14f9a5c0e4d2bc06cb217a84d836badfe9dc7a18
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/kvm64.c

  Log Message:
  -----------
  target/arm64: kvm debug set target_el when passing exception to guest

When we are debugging the guest all exceptions come our way but might
be for the guest's own debug exceptions. We use the ->do_interrupt()
infrastructure to inject the exception into the guest. However, we are
missing a full setup of the exception structure, causing an assert
later down the line.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: f251cb237188d4398edeb47234d9d32fb701516a
      
https://github.com/qemu/qemu/commit/f251cb237188d4398edeb47234d9d32fb701516a
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M tests/guest-debug/test-gdbstub.py

  Log Message:
  -----------
  tests/guest-debug: fix scoping of failcount

You should declare you are using a global version of a variable before
you attempt to modify it in a function.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: b281ba4223c302c41ff8104152bfdd44de4fe798
      
https://github.com/qemu/qemu/commit/b281ba4223c302c41ff8104152bfdd44de4fe798
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/cpu.h

  Log Message:
  -----------
  arm: use symbolic MDCR_TDE in arm_debug_target_el

We already have this symbol defined so lets use it.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: 22af90255ec2100a44cbbb7f0460ba15eed79538
      
https://github.com/qemu/qemu/commit/22af90255ec2100a44cbbb7f0460ba15eed79538
  Author: Alex Bennée <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/cpu.h

  Log Message:
  -----------
  arm: fix aa64_generate_debug_exceptions to work with EL2

The test was incomplete and incorrectly caused debug exceptions to be
generated when returning to EL2 after a failed attempt to single-step
an EL1 instruction. Fix this while cleaning up the function a little.

Signed-off-by: Alex Bennée <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Message-id: address@hidden
Signed-off-by: Peter Maydell <address@hidden>


  Commit: c624ea0fa7ffc9e2cc3e2b36c92b5c960954489f
      
https://github.com/qemu/qemu/commit/c624ea0fa7ffc9e2cc3e2b36c92b5c960954489f
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/helper.c

  Log Message:
  -----------
  Revert "target/arm: Implement HCR.VI and VF"

This reverts commit 8a0fc3a29fc2315325400c738f807d0d4ae0ab7f.

The implementation of HCR.VI and VF in that commit is not
correct -- they do not track the overall "is there a pending
VIRQ or VFIQ" status, but whether there is a pending interrupt
due to "this mechanism", ie the hypervisor having set the VI/VF
bits. The overall pending state for VIRQ and VFIQ is effectively
the logical OR of the inbound lines from the GIC with the
VI and VF bits. Commit 8a0fc3a29fc231 would result in pending
VIRQ/VFIQ possibly being lost when the hypervisor wrote to HCR.

As a preliminary to implementing the HCR.VI/VF feature properly,
revert the broken one entirely.

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
Message-id: address@hidden


  Commit: ed89f078ff3d6684ce3e538e4777a3bb4ec3e2b1
      
https://github.com/qemu/qemu/commit/ed89f078ff3d6684ce3e538e4777a3bb4ec3e2b1
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/cpu.c
    M target/arm/cpu.h
    M target/arm/machine.c

  Log Message:
  -----------
  target/arm: Track the state of our irq lines from the GIC explicitly

Currently we track the state of the four irq lines from the GIC
only via the cs->interrupt_request or KVM irq state. That means
that we assume that an interrupt is asserted if and only if the
external line is set. This assumption is incorrect for VIRQ
and VFIQ, because the HCR_EL2.{VI,VF} bits allow assertion
of VIRQ and VFIQ separately from the state of the external line.

To handle this, start tracking the state of the external lines
explicitly in a CPU state struct field, as is common practice
for devices.

The complicated part of this is dealing with inbound migration
from an older QEMU which didn't have this state. We assume in
that case that the older QEMU did not implement the HCR_EL2.{VI,VF}
bits as generating interrupts, and so the line state matches
the current state in cs->interrupt_request. (This is not quite
true between commit 8a0fc3a29fc2315325400c7 and its revert, but
that commit is broken and never made it into any released QEMU
version.)

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
Message-id: address@hidden


  Commit: 89430fc6f80a5aef1d4cbd6fc26b40c30793786c
      
https://github.com/qemu/qemu/commit/89430fc6f80a5aef1d4cbd6fc26b40c30793786c
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/cpu.c
    M target/arm/helper.c
    M target/arm/internals.h

  Log Message:
  -----------
  target/arm: Correctly implement handling of HCR_EL2.{VI, VF}

In commit 8a0fc3a29fc2315325400 we tried to implement HCR_EL2.{VI,VF},
but we got it wrong and had to revert it.

In that commit we implemented them as simply tracking whether there
is a pending virtual IRQ or virtual FIQ. This is not correct -- these
bits cause a software-generated VIRQ/VFIQ, which is distinct from
whether there is a hardware-generated VIRQ/VFIQ caused by the
external interrupt controller. So we need to track separately
the HCR_EL2 bit state and the external virq/vfiq line state, and
OR the two together to get the actual pending VIRQ/VFIQ state.

Fixes: 8a0fc3a29fc2315325400c738f807d0d4ae0ab7f
Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Message-id: address@hidden


  Commit: 593cfa2b637b92d37eef949653840dc065cdb960
      
https://github.com/qemu/qemu/commit/593cfa2b637b92d37eef949653840dc065cdb960
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/helper.c
    M target/arm/internals.h
    M target/arm/kvm32.c
    M target/arm/op_helper.c

  Log Message:
  -----------
  target/arm: Hyp mode R14 is shared with User and System

Hyp mode is an exception to the general rule that each AArch32
mode has its own r13, r14 and SPSR -- it has a banked r13 and
SPSR but shares its r14 with User and System mode. We were
incorrectly implementing it as banked, which meant that on
entry to Hyp mode r14 was 0 rather than the USR/SYS r14.

We provide a new function r14_bank_number() which is like
the existing bank_number() but provides the index into
env->banked_r14[]; bank_number() provides the index to use
for env->banked_r13[] and env->banked_cpsr[].

All the points in the code that were using bank_number()
to index into env->banked_r14[] are updated for consintency:
 * switch_mode() -- this is the only place where we fix
   an actual bug
 * aarch64_sync_32_to_64() and aarch64_sync_64_to_32():
   no behavioural change as we already special-cased Hyp R14
 * kvm32.c: no behavioural change since the guest can't ever
   be in Hyp mode, but conceptually the right thing to do
 * msr_banked()/mrs_banked(): we can never get to the case
   that accesses banked_r14[] with tgtmode == ARM_CPU_MODE_HYP,
   so no behavioural change

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Edgar E. Iglesias <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
Message-id: address@hidden


  Commit: 436c0cbbeb38dd97c02fe921a7cb253a18afdd86
      
https://github.com/qemu/qemu/commit/436c0cbbeb38dd97c02fe921a7cb253a18afdd86
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M target/arm/cpu.c

  Log Message:
  -----------
  target/arm/cpu: Give Cortex-A15 and -A7 the EL2 feature

The Cortex-A15 and Cortex-A7 both have EL2; now we've implemented
it properly we can enable the feature bit.

Signed-off-by: Peter Maydell <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Edgar E. Iglesias <address@hidden>
Message-id: address@hidden


  Commit: a8a1b163b7433fee312aa5896a7385ae328a684f
      
https://github.com/qemu/qemu/commit/a8a1b163b7433fee312aa5896a7385ae328a684f
  Author: Peter Maydell <address@hidden>
  Date:   2018-11-13 (Tue, 13 Nov 2018)

  Changed paths:
    M MAINTAINERS
    M hw/arm/sysbus-fdt.c
    M target/arm/cpu.c
    M target/arm/cpu.h
    M target/arm/helper.c
    M target/arm/internals.h
    M target/arm/kvm32.c
    M target/arm/kvm64.c
    M target/arm/machine.c
    M target/arm/op_helper.c
    M tests/guest-debug/test-gdbstub.py

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20181113' 
into staging

target/arm queue:
 * Remove no-longer-needed workaround for small SAU regions for v8M
 * Remove antique TODO comment
 * MAINTAINERS: Add an entry for the 'collie' machine
 * hw/arm/sysbus-fdt: Only call match_fn callback if the type matches
 * Fix infinite recursion in tlbi_aa64_vmalle1_write()
 * ARM KVM: fix various bugs in handling of guest debugging
 * Correctly implement handling of HCR_EL2.{VI, VF}
 * Hyp mode R14 is shared with User and System
 * Give Cortex-A15 and -A7 the EL2 feature

# gpg: Signature made Tue 13 Nov 2018 10:51:53 GMT
# gpg:                using RSA key 3C2525ED14360CDE
# gpg: Good signature from "Peter Maydell <address@hidden>"
# gpg:                 aka "Peter Maydell <address@hidden>"
# gpg:                 aka "Peter Maydell <address@hidden>"
# Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83  15CF 3C25 25ED 1436 0CDE

* remotes/pmaydell/tags/pull-target-arm-20181113:
  target/arm/cpu: Give Cortex-A15 and -A7 the EL2 feature
  target/arm: Hyp mode R14 is shared with User and System
  target/arm: Correctly implement handling of HCR_EL2.{VI, VF}
  target/arm: Track the state of our irq lines from the GIC explicitly
  Revert "target/arm: Implement HCR.VI and VF"
  arm: fix aa64_generate_debug_exceptions to work with EL2
  arm: use symbolic MDCR_TDE in arm_debug_target_el
  tests/guest-debug: fix scoping of failcount
  target/arm64: kvm debug set target_el when passing exception to guest
  target/arm64: hold BQL when calling do_interrupt()
  target/arm64: properly handle DBGVR RESS bits
  target/arm: Fix typo in tlbi_aa64_vmalle1_write
  hw/arm/sysbus-fdt: Only call match_fn callback if the type matches
  MAINTAINERS: Add an entry for the 'collie' machine
  target/arm: Remove antique TODO comment
  target/arm: Remove workaround for small SAU regions

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/6db87aae61bc...a8a1b163b743
      **NOTE:** This service has been marked for deprecation: 
https://developer.github.com/changes/2018-04-25-github-services-deprecation/

      Functionality will be removed from GitHub.com on January 31st, 2019.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]