public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
* linux-next: manual merge of the kvm-x86 tree with the kvm-riscv tree
@ 2023-08-15  6:34 Stephen Rothwell
  0 siblings, 0 replies; 5+ messages in thread
From: Stephen Rothwell @ 2023-08-15  6:34 UTC (permalink / raw)
  To: Sean Christopherson, Anup Patel
  Cc: Aaron Lewis, Andrew Jones, Haibo Xu, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 1381 bytes --]

Hi all,

Today's linux-next merge of the kvm-x86 tree got a conflict in:

  tools/testing/selftests/kvm/include/test_util.h

between commit:

  dfaf20af7649 ("KVM: arm64: selftests: Replace str_with_index with strdup_printf")

from the kvm-riscv tree and commit:

  e5119382499c ("KVM: selftests: Add guest_snprintf() to KVM selftests")

from the kvm-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc tools/testing/selftests/kvm/include/test_util.h
index 7e0182f837b5,7a5907da1719..000000000000
--- a/tools/testing/selftests/kvm/include/test_util.h
+++ b/tools/testing/selftests/kvm/include/test_util.h
@@@ -186,6 -185,7 +185,9 @@@ static inline uint32_t atoi_non_negativ
  	return num;
  }
  
 +char *strdup_printf(const char *fmt, ...) __attribute__((format(printf, 1, 2), nonnull(1)));
 +
+ int guest_vsnprintf(char *buf, int n, const char *fmt, va_list args);
+ int guest_snprintf(char *buf, int n, const char *fmt, ...);
+ 
  #endif /* SELFTEST_KVM_TEST_UTIL_H */

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread
* linux-next: manual merge of the kvm-x86 tree with the kvm-riscv tree
@ 2026-01-29 15:00 Mark Brown
  2026-01-29 15:19 ` Mark Brown
  0 siblings, 1 reply; 5+ messages in thread
From: Mark Brown @ 2026-01-29 15:00 UTC (permalink / raw)
  To: Sean Christopherson
  Cc: Anup Patel, Linux Kernel Mailing List, Linux Next Mailing List,
	Wu Fei

[-- Attachment #1: Type: text/plain, Size: 2375 bytes --]

Hi all,

Today's linux-next merge of the kvm-x86 tree got a conflict in:

  tools/testing/selftests/kvm/lib/riscv/processor.c

between commit:

  7631f7b1ccc9e ("KVM: riscv: selftests: Add riscv vm satp modes")

from the kvm-riscv tree and commit:

  9f073ac25b4c4 ("KVM: selftests: Add "struct kvm_mmu" to track a given MMU instance")

from the kvm-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

diff --cc tools/testing/selftests/kvm/lib/riscv/processor.c
index 373cf4d1ed809,e6ec7c224fc3e..0000000000000
--- a/tools/testing/selftests/kvm/lib/riscv/processor.c
+++ b/tools/testing/selftests/kvm/lib/riscv/processor.c
@@@ -64,15 -68,15 +64,15 @@@ static uint64_t pte_index(struct kvm_v
  
  void virt_arch_pgd_alloc(struct kvm_vm *vm)
  {
 -	size_t nr_pages = page_align(vm, ptrs_per_pte(vm) * 8) / vm->page_size;
 +	size_t nr_pages = vm_page_align(vm, ptrs_per_pte(vm) * 8) / vm->page_size;
  
- 	if (vm->pgd_created)
+ 	if (vm->mmu.pgd_created)
  		return;
  
- 	vm->pgd = vm_phy_pages_alloc(vm, nr_pages,
- 				     KVM_GUEST_PAGE_TABLE_MIN_PADDR,
- 				     vm->memslots[MEM_REGION_PT]);
- 	vm->pgd_created = true;
+ 	vm->mmu.pgd = vm_phy_pages_alloc(vm, nr_pages,
+ 					 KVM_GUEST_PAGE_TABLE_MIN_PADDR,
+ 					 vm->memslots[MEM_REGION_PT]);
+ 	vm->mmu.pgd_created = true;
  }
  
  void virt_arch_pg_map(struct kvm_vm *vm, uint64_t vaddr, uint64_t paddr)
@@@ -220,14 -212,8 +221,14 @@@ void riscv_vcpu_mmu_setup(struct kvm_vc
  		TEST_FAIL("Unknown guest mode, mode: 0x%x", vm->mode);
  	}
  
 +	max_satp_mode = vcpu_get_reg(vcpu, RISCV_CONFIG_REG(satp_mode));
 +
 +	if ((satp_mode >> SATP_MODE_SHIFT) > max_satp_mode)
 +		TEST_FAIL("Unable to set satp mode 0x%lx, max mode 0x%lx\n",
 +			  satp_mode >> SATP_MODE_SHIFT, max_satp_mode);
 +
- 	satp = (vm->pgd >> PGTBL_PAGE_SIZE_SHIFT) & SATP_PPN;
+ 	satp = (vm->mmu.pgd >> PGTBL_PAGE_SIZE_SHIFT) & SATP_PPN;
 -	satp |= SATP_MODE_48;
 +	satp |= satp_mode;
  
  	vcpu_set_reg(vcpu, RISCV_GENERAL_CSR_REG(satp), satp);
  }

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread
* linux-next: manual merge of the kvm-x86 tree with the kvm-riscv tree
@ 2024-03-07  3:59 Stephen Rothwell
  0 siblings, 0 replies; 5+ messages in thread
From: Stephen Rothwell @ 2024-03-07  3:59 UTC (permalink / raw)
  To: Sean Christopherson, Anup Patel
  Cc: Haibo Xu, Linux Kernel Mailing List, Linux Next Mailing List,
	Peter Gonda

[-- Attachment #1: Type: text/plain, Size: 1303 bytes --]

Hi all,

Today's linux-next merge of the kvm-x86 tree got a conflict in:

  tools/testing/selftests/kvm/include/kvm_util_base.h

between commit:

  1e979288c9b5 ("KVM: riscv: selftests: Add guest helper to get vcpu id")

from the kvm-riscv tree and commit:

  be1bd4c5394f ("KVM: selftests: Allow tagging protected memory in guest page tables")

from the kvm-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc tools/testing/selftests/kvm/include/kvm_util_base.h
index 39c2499df341,194963e05341..000000000000
--- a/tools/testing/selftests/kvm/include/kvm_util_base.h
+++ b/tools/testing/selftests/kvm/include/kvm_util_base.h
@@@ -1081,6 -1128,6 +1128,8 @@@ void kvm_selftest_arch_init(void)
  
  void kvm_arch_vm_post_create(struct kvm_vm *vm);
  
 +uint32_t guest_get_vcpuid(void);
 +
+ bool vm_is_gpa_protected(struct kvm_vm *vm, vm_paddr_t paddr);
+ 
  #endif /* SELFTEST_KVM_UTIL_BASE_H */

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread
* linux-next: manual merge of the kvm-x86 tree with the kvm-riscv tree
@ 2023-08-15  6:32 Stephen Rothwell
  0 siblings, 0 replies; 5+ messages in thread
From: Stephen Rothwell @ 2023-08-15  6:32 UTC (permalink / raw)
  To: Sean Christopherson, Anup Patel
  Cc: Aaron Lewis, Andrew Jones, Haibo Xu, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 2386 bytes --]

Hi all,

Today's linux-next merge of the kvm-x86 tree got a conflict in:

  tools/testing/selftests/kvm/Makefile

between commits:

  17da79e009c3 ("KVM: arm64: selftests: Split get-reg-list test code")
  477069398ed6 ("KVM: riscv: selftests: Add get-reg-list test")

from the kvm-riscv tree and commit:

  5d1d46f9d56f ("KVM: selftests: Add a selftest for guest prints and formatted asserts")

from the kvm-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc tools/testing/selftests/kvm/Makefile
index 8852c37fbc2d,77026907968f..000000000000
--- a/tools/testing/selftests/kvm/Makefile
+++ b/tools/testing/selftests/kvm/Makefile
@@@ -151,7 -154,7 +153,8 @@@ TEST_GEN_PROGS_aarch64 += access_tracki
  TEST_GEN_PROGS_aarch64 += demand_paging_test
  TEST_GEN_PROGS_aarch64 += dirty_log_test
  TEST_GEN_PROGS_aarch64 += dirty_log_perf_test
 +TEST_GEN_PROGS_aarch64 += get-reg-list
+ TEST_GEN_PROGS_aarch64 += guest_print_test
  TEST_GEN_PROGS_aarch64 += kvm_create_max_vcpus
  TEST_GEN_PROGS_aarch64 += kvm_page_table_test
  TEST_GEN_PROGS_aarch64 += memslot_modification_stress_test
@@@ -166,9 -169,9 +169,10 @@@ TEST_GEN_PROGS_s390x += s390x/reset
  TEST_GEN_PROGS_s390x += s390x/sync_regs_test
  TEST_GEN_PROGS_s390x += s390x/tprot
  TEST_GEN_PROGS_s390x += s390x/cmma_test
 +TEST_GEN_PROGS_s390x += s390x/debug_test
  TEST_GEN_PROGS_s390x += demand_paging_test
  TEST_GEN_PROGS_s390x += dirty_log_test
+ TEST_GEN_PROGS_s390x += guest_print_test
  TEST_GEN_PROGS_s390x += kvm_create_max_vcpus
  TEST_GEN_PROGS_s390x += kvm_page_table_test
  TEST_GEN_PROGS_s390x += rseq_test
@@@ -177,7 -180,7 +181,8 @@@ TEST_GEN_PROGS_s390x += kvm_binary_stat
  
  TEST_GEN_PROGS_riscv += demand_paging_test
  TEST_GEN_PROGS_riscv += dirty_log_test
 +TEST_GEN_PROGS_riscv += get-reg-list
+ TEST_GEN_PROGS_riscv += guest_print_test
  TEST_GEN_PROGS_riscv += kvm_create_max_vcpus
  TEST_GEN_PROGS_riscv += kvm_page_table_test
  TEST_GEN_PROGS_riscv += set_memory_region_test

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

end of thread, other threads:[~2026-01-29 15:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-15  6:34 linux-next: manual merge of the kvm-x86 tree with the kvm-riscv tree Stephen Rothwell
  -- strict thread matches above, loose matches on Subject: below --
2026-01-29 15:00 Mark Brown
2026-01-29 15:19 ` Mark Brown
2024-03-07  3:59 Stephen Rothwell
2023-08-15  6:32 Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox