• F
    target-arm: add banked register accessors · ea30a4b8
    Fabian Aggeler 提交于
    If EL3 is in AArch32 state certain cp registers are banked (secure and
    non-secure instance). When reading or writing to coprocessor registers
    the following macros can be used.
    
    - A32_BANKED macros are used for choosing the banked register based on provided
      input security argument.  This macro is used to choose the bank during
      translation of MRC/MCR instructions that are dependent on something other
      than the current secure state.
    - A32_BANKED_CURRENT macros are used for choosing the banked register based on
      current secure state.  This is NOT to be used for choosing the bank used
      during translation as it breaks monitor mode.
    
    If EL3 is operating in AArch64 state coprocessor registers are not
    banked anymore. The macros use the non-secure instance (_ns) in this
    case, which is architecturally mapped to the AArch64 EL register.
    Signed-off-by: NSergey Fedorov <s.fedorov@samsung.com>
    Signed-off-by: NFabian Aggeler <aggelerf@ethz.ch>
    Signed-off-by: NGreg Bellows <greg.bellows@linaro.org>
    Reviewed-by: NPeter Maydell <peter.maydell@linaro.org>
    Message-id: 1416242878-876-4-git-send-email-greg.bellows@linaro.org
    Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
    ea30a4b8
cpu.h 59.0 KB