An error occurred fetching the project authors.
  1. 15 Dec, 2021 1 commit
  2. 17 Oct, 2021 1 commit
  3. 05 Oct, 2021 1 commit
  4. 06 Sep, 2021 1 commit
  5. 20 Aug, 2021 1 commit
  6. 11 Aug, 2021 1 commit
  7. 02 Aug, 2021 4 commits
  8. 14 Jul, 2021 1 commit
  9. 01 Jul, 2021 1 commit
  10. 29 Jun, 2021 1 commit
  11. 22 Jun, 2021 1 commit
  12. 18 Jun, 2021 2 commits
  13. 01 Jun, 2021 2 commits
  14. 15 May, 2021 1 commit
  15. 17 Apr, 2021 2 commits
  16. 07 Apr, 2021 3 commits
  17. 19 Mar, 2021 4 commits
  18. 12 Mar, 2021 1 commit
  19. 25 Jan, 2021 1 commit
  20. 02 Dec, 2020 1 commit
    • Yanan Wang's avatar
      KVM: arm64: Add usage of stage 2 fault lookup level in user_mem_abort() · 7d894834
      Yanan Wang authored
      If we get a FSC_PERM fault, just using (logging_active && writable) to
      determine calling kvm_pgtable_stage2_map(). There will be two more cases
      we should consider.
      
      (1) After logging_active is configged back to false from true. When we
      get a FSC_PERM fault with write_fault and adjustment of hugepage is needed,
      we should merge tables back to a block entry. This case is ignored by still
      calling kvm_pgtable_stage2_relax_perms(), which will lead to an endless
      loop and guest panic due to soft lockup.
      
      (2) We use (FSC_PERM && logging_active && writable) to determine
      collapsing a block entry into a table by calling kvm_pgtable_stage2_map().
      But sometimes we may only need to relax permissions when trying to write
      to a page other than a block.
      In this condition,using kvm_pgtable_stage2_relax_perms() will be fine.
      
      The ISS filed bit[1:0] in ESR_EL2 regesiter indicates the stage2 lookup
      level at which a D-abort or I-abort occurred. By comparing granule of
      the fault lookup level with vma_pagesize, we can strictly distinguish
      conditions of calling kvm_pgtable_stage2_relax_perms() or
      kvm_pgtable_stage2_map(), and the above two cases will be well considered.
      Suggested-by: default avatarKeqian Zhu <zhukeqian1@huawei.com>
      Signed-off-by: default avatarYanan Wang <wangyanan55@huawei.com>
      Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
      Acked-by: default avatarWill Deacon <will@kernel.org>
      Link: https://lore.kernel.org/r/20201201201034.116760-4-wangyanan55@huawei.com
      7d894834
  21. 10 Nov, 2020 2 commits
  22. 06 Nov, 2020 1 commit
  23. 29 Oct, 2020 2 commits
  24. 02 Oct, 2020 1 commit
  25. 18 Sep, 2020 3 commits
    • Marc Zyngier's avatar
      KVM: arm64: Assume write fault on S1PTW permission fault on instruction fetch · c4ad98e4
      Marc Zyngier authored
      KVM currently assumes that an instruction abort can never be a write.
      This is in general true, except when the abort is triggered by
      a S1PTW on instruction fetch that tries to update the S1 page tables
      (to set AF, for example).
      
      This can happen if the page tables have been paged out and brought
      back in without seeing a direct write to them (they are thus marked
      read only), and the fault handling code will make the PT executable(!)
      instead of writable. The guest gets stuck forever.
      
      In these conditions, the permission fault must be considered as
      a write so that the Stage-1 update can take place. This is essentially
      the I-side equivalent of the problem fixed by 60e21a0e ("arm64: KVM:
      Take S1 walks into account when determining S2 write faults").
      
      Update kvm_is_write_fault() to return true on IABT+S1PTW, and introduce
      kvm_vcpu_trap_is_exec_fault() that only return true when no faulting
      on a S1 fault. Additionally, kvm_vcpu_dabt_iss1tw() is renamed to
      kvm_vcpu_abt_iss1tw(), as the above makes it plain that it isn't
      specific to data abort.
      Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
      Reviewed-by: default avatarWill Deacon <will@kernel.org>
      Cc: stable@vger.kernel.org
      Link: https://lore.kernel.org/r/20200915104218.1284701-2-maz@kernel.org
      c4ad98e4
    • Xiaofei Tan's avatar
      KVM: arm64: Fix doc warnings in mmu code · c9c0279c
      Xiaofei Tan authored
      Fix following warnings caused by mismatch bewteen function parameters
      and comments.
      arch/arm64/kvm/mmu.c:128: warning: Function parameter or member 'mmu' not described in '__unmap_stage2_range'
      arch/arm64/kvm/mmu.c:128: warning: Function parameter or member 'may_block' not described in '__unmap_stage2_range'
      arch/arm64/kvm/mmu.c:128: warning: Excess function parameter 'kvm' description in '__unmap_stage2_range'
      arch/arm64/kvm/mmu.c:499: warning: Function parameter or member 'writable' not described in 'kvm_phys_addr_ioremap'
      arch/arm64/kvm/mmu.c:538: warning: Function parameter or member 'mmu' not described in 'stage2_wp_range'
      arch/arm64/kvm/mmu.c:538: warning: Excess function parameter 'kvm' description in 'stage2_wp_range'
      Signed-off-by: default avatarXiaofei Tan <tanxiaofei@huawei.com>
      Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
      Acked-by: default avatarWill Deacon <will@kernel.org>
      Link: https://lore.kernel.org/r/1600307269-50957-1-git-send-email-tanxiaofei@huawei.com
      c9c0279c
    • Alexandru Elisei's avatar
      KVM: arm64: Do not flush memslot if FWB is supported · ada329e6
      Alexandru Elisei authored
      As a result of a KVM_SET_USER_MEMORY_REGION ioctl, KVM flushes the
      dcache for the memslot being changed to ensure a consistent view of memory
      between the host and the guest: the host runs with caches enabled, and
      it is possible for the data written by the hypervisor to still be in the
      caches, but the guest is running with stage 1 disabled, meaning data
      accesses are to Device-nGnRnE memory, bypassing the caches entirely.
      
      Flushing the dcache is not necessary when KVM enables FWB, because it
      forces the guest to uses cacheable memory accesses.
      
      The current behaviour does not change, as the dcache flush helpers execute
      the cache operation only if FWB is not enabled, but walking the stage 2
      table is avoided.
      Signed-off-by: default avatarAlexandru Elisei <alexandru.elisei@arm.com>
      Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
      Link: https://lore.kernel.org/r/20200915170442.131635-1-alexandru.elisei@arm.com
      ada329e6