1. 08 9月, 2017 24 次提交
  2. 07 9月, 2017 16 次提交
    • P
      Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20170907' into staging · ef475b5d
      Peter Maydell 提交于
      target-arm:
       * cleanups converting to DEFINE_PROP_LINK
       * allwinner-a10: mark as not user-creatable
       * initial patches working towards ARMv8M support
       * implement generating aborts on memory transaction failures
       * make BXJ behave correctly (ie not UNDEF) on ARMv6-and-later
      
      # gpg: Signature made Thu 07 Sep 2017 14:26:07 BST
      # gpg:                using RSA key 0x3C2525ED14360CDE
      # gpg: Good signature from "Peter Maydell <peter.maydell@linaro.org>"
      # gpg:                 aka "Peter Maydell <pmaydell@gmail.com>"
      # gpg:                 aka "Peter Maydell <pmaydell@chiark.greenend.org.uk>"
      # Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83  15CF 3C25 25ED 1436 0CDE
      
      * remotes/pmaydell/tags/pull-target-arm-20170907: (31 commits)
        target/arm: Add Jazelle feature
        target/arm: Implement new do_transaction_failed hook
        hw/arm: Set ignore_memory_transaction_failures for most ARM boards
        boards.h: Define new flag ignore_memory_transaction_failures
        target/arm: Implement BXNS, and banked stack pointers
        target/arm: Move regime_is_secure() to target/arm/internals.h
        target/arm: Make CFSR register banked for v8M
        target/arm: Make MMFAR banked for v8M
        target/arm: Make CCR register banked for v8M
        target/arm: Make MPU_CTRL register banked for v8M
        target/arm: Make MPU_RNR register banked for v8M
        target/arm: Make MPU_RBAR, MPU_RLAR banked for v8M
        target/arm: Make MPU_MAIR0, MPU_MAIR1 registers banked for v8M
        target/arm: Make VTOR register banked for v8M
        nvic: Add NS alias SCS region
        target/arm: Make CONTROL register banked for v8M
        target/arm: Make FAULTMASK register banked for v8M
        target/arm: Make PRIMASK register banked for v8M
        target/arm: Make BASEPRI register banked for v8M
        target/arm: Add MMU indexes for secure v8M
        ...
      
      # Conflicts:
      #	target/arm/translate.c
      ef475b5d
    • P
      Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20170906a' into staging · 7794b34e
      Peter Maydell 提交于
      migration pull 2017-09-06
      
      # gpg: Signature made Wed 06 Sep 2017 19:39:23 BST
      # gpg:                using RSA key 0x0516331EBC5BFDE7
      # gpg: Good signature from "Dr. David Alan Gilbert (RH2) <dgilbert@redhat.com>"
      # gpg: WARNING: This key is not certified with sufficiently trusted signatures!
      # gpg:          It is not certain that the signature belongs to the owner.
      # Primary key fingerprint: 45F5 C71B 4A0C B7FB 977A  9FA9 0516 331E BC5B FDE7
      
      * remotes/dgilbert/tags/pull-migration-20170906a:
        migration: dump str in migrate_set_state trace
        snapshot/tests: Try loadvm twice
        migration: Reset rather than destroy main_thread_load_event
        runstate/migrate: Two more transitions
        host-utils: Simplify pow2ceil()
        host-utils: Proactively fix pow2floor(), switch to unsigned
        xbzrle: Drop unused cache_resize()
        migration: Report when bdrv_inactivate_all fails
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      7794b34e
    • P
      Merge remote-tracking branch 'remotes/rth/tags/pull-tgt-20170906' into staging · 7e375e04
      Peter Maydell 提交于
      tcg generic translate loop v15
      
      # gpg: Signature made Wed 06 Sep 2017 17:02:31 BST
      # gpg:                using RSA key 0x64DF38E8AF7E215F
      # gpg: Good signature from "Richard Henderson <richard.henderson@linaro.org>"
      # gpg: WARNING: This key is not certified with sufficiently trusted signatures!
      # gpg:          It is not certain that the signature belongs to the owner.
      # Primary key fingerprint: 7A48 1E78 868B 4DB6 A85A  05C0 64DF 38E8 AF7E 215F
      
      * remotes/rth/tags/pull-tgt-20170906: (32 commits)
        target/arm: Perform per-insn cross-page check only for Thumb
        target/arm: Split out thumb_tr_translate_insn
        target/arm: Move ss check to init_disas_context
        target/arm: [a64] Move page and ss checks to init_disas_context
        target/arm: [tcg] Port to generic translation framework
        target/arm: [tcg,a64] Port to disas_log
        target/arm: [tcg] Port to disas_log
        target/arm: [tcg,a64] Port to tb_stop
        target/arm: [tcg] Port to tb_stop
        target/arm: [tcg,a64] Port to translate_insn
        target/arm: [tcg] Port to translate_insn
        target/arm: [tcg,a64] Port to breakpoint_check
        target/arm: [tcg,a64] Port to insn_start
        target/arm: [tcg] Port to insn_start
        target/arm: [tcg] Port to tb_start
        target/arm: [tcg,a64] Port to init_disas_context
        target/arm: [tcg] Port to init_disas_context
        target/arm: [tcg] Port to DisasContextBase
        target/i386: [tcg] Port to generic translation framework
        target/i386: [tcg] Port to disas_log
        ...
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      7e375e04
    • P
      target/arm: Add Jazelle feature · c99a55d3
      Portia Stephens 提交于
      This adds a feature bit indicating support of the (trivial) Jazelle
      implementation if ARM_FEATURE_V6 is set or if the processor is arm926
      or arm1026.  This fixes the issue that any BXJ instruction will
      result in an illegal_op.  BXJ instructions will now check if the
      architecture supports ARM_FEATURE_JAZELLE.
      Signed-off-by: NPortia Stephens <portia.stephens@xilinx.com>
      Reviewed-by: NAlistair Francis <alistair.francis@xilinx.com>
      Message-id: 20170905211232.11092-1-portia.stephens@xilinx.com
      [PMM: edited commit message and comment text a bit]
      Reviewed-by: NPeter Maydell <peter.maydell@linaro.org>
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      c99a55d3
    • P
      target/arm: Implement new do_transaction_failed hook · c79c0a31
      Peter Maydell 提交于
      Implement the new do_transaction_failed hook for ARM, which should
      cause the CPU to take a prefetch abort or data abort.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Reviewed-by: NEdgar E. Iglesias <edgar.iglesias@xilinx.com>
      Message-id: 1504626814-23124-4-git-send-email-peter.maydell@linaro.org
      c79c0a31
    • P
      hw/arm: Set ignore_memory_transaction_failures for most ARM boards · 4672cbd7
      Peter Maydell 提交于
      Set the MachineClass flag ignore_memory_transaction_failures
      for almost all ARM boards. This means they retain the legacy
      behaviour that accesses to unimplemented addresses will RAZ/WI
      rather than aborting, when a subsequent commit adds support
      for external aborts.
      
      The exceptions are:
       * virt -- we know that guests won't try to prod devices
         that we don't describe in the device tree or ACPI tables
       * mps2 -- this board was written to use unimplemented-device
         for all the ranges with devices we don't yet handle
      
      New boards should not set the flag, but instead be written
      like the mps2.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NAlistair Francis <alistair.francis@xilinx.com>
      Message-id: 1504626814-23124-3-git-send-email-peter.maydell@linaro.org
      For the Xilinx boards:
      Reviewed-by: NEdgar E. Iglesias <edgar.iglesias@xilinx.com>
      4672cbd7
    • P
      boards.h: Define new flag ignore_memory_transaction_failures · ed860129
      Peter Maydell 提交于
      Define a new MachineClass field ignore_memory_transaction_failures.
      If this is flag is true then the CPU will ignore memory transaction
      failures which should cause the CPU to take an exception due to an
      access to an unassigned physical address; the transaction will
      instead return zero (for a read) or be ignored (for a write).  This
      should be set only by legacy board models which rely on the old
      RAZ/WI behaviour for handling devices that QEMU does not yet model.
      New board models should instead use "unimplemented-device" for all
      memory ranges where the guest will attempt to probe for a device that
      QEMU doesn't implement and a stub device is required.
      
      We need this for ARM boards, where we're about to implement support for
      generating external aborts on memory transaction failures. Too many
      of our legacy board models rely on the RAZ/WI behaviour and we
      would break currently working guests when their "probe for device"
      code provoked an external abort rather than a RAZ.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Reviewed-by: NAlistair Francis <alistair.francis@xilinx.com>
      Message-id: 1504626814-23124-2-git-send-email-peter.maydell@linaro.org
      ed860129
    • P
      target/arm: Implement BXNS, and banked stack pointers · fb602cb7
      Peter Maydell 提交于
      Implement the BXNS v8M instruction, which is like BX but will do a
      jump-and-switch-to-NonSecure if the branch target address has bit 0
      clear.
      
      This is the first piece of code which implements "switch to the
      other security state", so the commit also includes the code to
      switch the stack pointers around, which is the only complicated
      part of switching security state.
      
      BLXNS is more complicated than just "BXNS but set the link register",
      so we leave it for a separate commit.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-21-git-send-email-peter.maydell@linaro.org
      fb602cb7
    • P
      target/arm: Move regime_is_secure() to target/arm/internals.h · 61fcd69b
      Peter Maydell 提交于
      Move the regime_is_secure() utility function to internals.h;
      we are going to want to call it from translate.c.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-20-git-send-email-peter.maydell@linaro.org
      61fcd69b
    • P
      target/arm: Make CFSR register banked for v8M · 334e8dad
      Peter Maydell 提交于
      Make the CFSR register banked if v8M security extensions are enabled.
      
      Not all the bits in this register are banked: the BFSR
      bits [15:8] are shared between S and NS, and we store them
      in the NS copy of the register.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-19-git-send-email-peter.maydell@linaro.org
      334e8dad
    • P
      target/arm: Make MMFAR banked for v8M · c51a5cfc
      Peter Maydell 提交于
      Make the MMFAR register banked if v8M security extensions are
      enabled.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-18-git-send-email-peter.maydell@linaro.org
      c51a5cfc
    • P
      target/arm: Make CCR register banked for v8M · 9d40cd8a
      Peter Maydell 提交于
      Make the CCR register banked if v8M security extensions are enabled.
      
      This is slightly more complicated than the other "add banking"
      patches because there is one bit in the register which is not
      banked. We keep the live data in the NS copy of the register,
      and adjust it on register reads and writes. (Since we don't
      currently implement the behaviour that the bit controls, there
      is nowhere else that needs to care.)
      
      This patch includes the enforcement of the bits which are newly
      RES1 in ARMv8M.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1503414539-28762-17-git-send-email-peter.maydell@linaro.org
      9d40cd8a
    • P
      target/arm: Make MPU_CTRL register banked for v8M · ecf5e8ea
      Peter Maydell 提交于
      Make the MPU_CTRL register banked if v8M security extensions are
      enabled.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-16-git-send-email-peter.maydell@linaro.org
      ecf5e8ea
    • P
      target/arm: Make MPU_RNR register banked for v8M · 1bc04a88
      Peter Maydell 提交于
      Make the MPU_RNR register banked if v8M security extensions are
      enabled.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-15-git-send-email-peter.maydell@linaro.org
      1bc04a88
    • P
      target/arm: Make MPU_RBAR, MPU_RLAR banked for v8M · 62c58ee0
      Peter Maydell 提交于
      Make the MPU registers MPU_MAIR0 and MPU_MAIR1 banked if v8M security
      extensions are enabled.
      
      We can freely add more items to vmstate_m_security without
      breaking migration compatibility, because no CPU currently
      has the ARM_FEATURE_M_SECURITY bit enabled and so this
      subsection is not yet used by anything.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-14-git-send-email-peter.maydell@linaro.org
      62c58ee0
    • P
      target/arm: Make MPU_MAIR0, MPU_MAIR1 registers banked for v8M · 4125e6fe
      Peter Maydell 提交于
      Make the MPU registers MPU_MAIR0 and MPU_MAIR1 banked if v8M security
      extensions are enabled.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <richard.henderson@linaro.org>
      Message-id: 1503414539-28762-13-git-send-email-peter.maydell@linaro.org
      4125e6fe