ther
these instructions are trapped to HS-mode. Therefore, we can implement guest
time scaling by setting TM bit in kvm_riscv_vcpu_timer_restore() and emulating
RDTIME/RDTIMEH instruction in system_opcode_insn().
Signed-off-by: Yifei Jiang
Signed-off-by: Yipeng Yin
---
arch/riscv/include
lowing two main reasons:
- RDTIME not only be used in linux, but also in firmware and userspace.
- It is difficult to be compatible with nested virtualization.
[1] https://lore.kernel.org/patchwork/cover/1288153/
Yifei Jiang (3):
RISC-V: KVM: Change the method of calculating cycles to nanosecond
ned-off-by: Yifei Jiang
Signed-off-by: Yipeng Yin
---
arch/riscv/include/asm/kvm_vcpu_timer.h | 9 ++
arch/riscv/kvm/vcpu_timer.c | 40 +
2 files changed, 44 insertions(+), 5 deletions(-)
diff --git a/arch/riscv/include/asm/kvm_vcpu_timer.h
b/arch/riscv/i
Because we will introduce the dynamic guest frequency later, we
can't use the fixed mult and shift to calculate nanoseconds.
Signed-off-by: Yifei Jiang
Signed-off-by: Yipeng Yin
---
arch/riscv/include/asm/kvm_vcpu_timer.h | 3 ---
arch/riscv/kvm/vcpu_timer.c | 3 +--
2
The correct sip/sie 0x222 could mask wrong 0x000 by VSIP_VALID_MASK,
This patch fix it.
Signed-off-by: Yifei Jiang
Signed-off-by: Yipeng Yin
---
arch/riscv/kvm/vcpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/riscv/kvm/vcpu.c b/arch/riscv/kvm/vcpu.c
index
.
Yifei Jiang (2):
riscv/kvm: Fix use VSIP_VALID_MASK mask HIP register
target/kvm: Add interfaces needed for log dirty
arch/riscv/configs/defconfig | 1 +
arch/riscv/kvm/Kconfig | 1 +
arch/riscv/kvm/mmu.c | 43
arch/riscv/kvm/vcpu.c
Add two interfaces of log dirty for kvm_main.c, and detele the interface
kvm_vm_ioctl_get_dirty_log which is redundantly defined.
CONFIG_KVM_GENERIC_DIRTYLOG_READ_PROTECT is added in defconfig.
Signed-off-by: Yifei Jiang
Signed-off-by: Yipeng Yin
---
arch/riscv/configs/defconfig | 1 +
arch
Signed-off-by: Yifei Jiang
Signed-off-by: Mingwang Li
---
arch/riscv/kvm/Kconfig | 2 ++
arch/riscv/kvm/Makefile | 2 +-
arch/riscv/kvm/vm.c | 1 +
3 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/arch/riscv/kvm/Kconfig b/arch/riscv/kvm/Kconfig
index 2356dc52ebb3..95d85d893ab6
Signed-off-by: Yifei Jiang
Signed-off-by: Mingwang Li
---
arch/riscv/kvm/vcpu_exit.c | 38 --
1 file changed, 32 insertions(+), 6 deletions(-)
diff --git a/arch/riscv/kvm/vcpu_exit.c b/arch/riscv/kvm/vcpu_exit.c
index e97ba96cb0ae..448f11179fa8 100644
--- a
rtio:
Recv SendSend
Socket Socket Message Elapsed
Size SizeSize Time Throughput
bytes bytes bytessecs.10^6bits/sec
131072 16384 16384100.07227.02
The next step is to support irqfd on RISC-V architecture.
Yife
10 matches
Mail list logo