Re: Call for GSoC/Outreachy internship project ideas

2024-01-30 Thread Palmer Dabbelt
On Mon, 15 Jan 2024 08:32:59 PST (-0800), stefa...@gmail.com wrote: Dear QEMU and KVM communities, QEMU will apply for the Google Summer of Code and Outreachy internship programs again this year. Regular contributors can submit project ideas that they'd like to mentor by replying to this email be

Re: Call for GSoC/Outreachy internship project ideas

2024-01-30 Thread Palmer Dabbelt
On Tue, 30 Jan 2024 12:28:27 PST (-0800), stefa...@gmail.com wrote: On Tue, 30 Jan 2024 at 14:40, Palmer Dabbelt wrote: On Mon, 15 Jan 2024 08:32:59 PST (-0800), stefa...@gmail.com wrote: > Dear QEMU and KVM communities, > QEMU will apply for the Google Summer of Code and Outreachy inte

Re: Call for GSoC/Outreachy internship project ideas

2024-01-30 Thread Palmer Dabbelt
On Tue, 30 Jan 2024 17:26:11 PST (-0800), alistai...@gmail.com wrote: On Wed, Jan 31, 2024 at 10:30 AM Palmer Dabbelt wrote: On Tue, 30 Jan 2024 12:28:27 PST (-0800), stefa...@gmail.com wrote: > On Tue, 30 Jan 2024 at 14:40, Palmer Dabbelt wrote: >> >> On Mon, 15 Jan 2024 08:3

Re: Call for GSoC/Outreachy internship project ideas

2024-01-31 Thread Palmer Dabbelt
On Wed, 31 Jan 2024 06:39:25 PST (-0800), stefa...@gmail.com wrote: On Tue, 30 Jan 2024 at 14:40, Palmer Dabbelt wrote: On Mon, 15 Jan 2024 08:32:59 PST (-0800), stefa...@gmail.com wrote: I'm not 100% sure this is a sane GSoC idea, as it's a bit open ended and might have some tr

[PATCH] RISC-V: Report the QEMU vendor/arch IDs on virtual CPUs

2024-01-31 Thread Palmer Dabbelt
s that's how the ISA handles open source implementations). Link: https://github.com/riscv/riscv-isa-manual/pull/1213 Signed-off-by: Palmer Dabbelt --- target/riscv/cpu.c | 16 target/riscv/cpu_vendorid.h | 3 +++ 2 files changed, 19 insertions(+) diff --git a/target/r

Re: Call for GSoC/Outreachy internship project ideas

2024-02-01 Thread Palmer Dabbelt
On Thu, 01 Feb 2024 09:39:22 PST (-0800), alex.ben...@linaro.org wrote: Palmer Dabbelt writes: On Tue, 30 Jan 2024 12:28:27 PST (-0800), stefa...@gmail.com wrote: On Tue, 30 Jan 2024 at 14:40, Palmer Dabbelt wrote: On Mon, 15 Jan 2024 08:32:59 PST (-0800), stefa...@gmail.com wrote: > D

Re: Call for GSoC/Outreachy internship project ideas

2024-02-01 Thread Palmer Dabbelt
On Thu, 01 Feb 2024 10:57:00 PST (-0800), alex.ben...@linaro.org wrote: Palmer Dabbelt writes: On Thu, 01 Feb 2024 09:39:22 PST (-0800), alex.ben...@linaro.org wrote: Palmer Dabbelt writes: On Tue, 30 Jan 2024 12:28:27 PST (-0800), stefa...@gmail.com wrote: On Tue, 30 Jan 2024 at 14:40

Re: [Qemu-devel] [PATCH 2/2] target/riscv: Add checks for several RVC reserved operands

2019-05-01 Thread Palmer Dabbelt
On Thu, 25 Apr 2019 10:32:43 PDT (-0700), richard.hender...@linaro.org wrote: On 4/25/19 10:26 AM, Richard Henderson wrote: { + illegal 011 0 - 0 01 # c.addi16sp, RES nzimm=0 addi011 . 00010 . 01 @c_addi16sp lui 011 . . . 01 @c_lu

Re: [Qemu-devel] [PATCH 1/2] fixup! target/riscv: Name the argument sets for all of insn32 formats

2019-05-01 Thread Palmer Dabbelt
On Thu, 25 Apr 2019 10:26:35 PDT (-0700), richard.hender...@linaro.org wrote: --- target/riscv/translate.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/target/riscv/translate.c b/target/riscv/translate.c index d1f599a92d..009c146e8f 100644 --- a/target/riscv

Re: [Qemu-devel] [PATCH for 4.1] target/riscv: More accurate handling of `sip` CSR

2019-05-07 Thread Palmer Dabbelt
On Mon, 06 May 2019 08:52:43 PDT (-0700), finte...@gmail.com wrote: According to the spec, "All bits besides SSIP, USIP, and UEIP in the sip register are read-only." Further, if an interrupt is not delegated to mode x, then "the corresponding bits in xip [...] should appear to be hardwired to zer

Re: [Qemu-devel] [PATCH] target/riscv: More accurate handling of `sip` CSR

2019-05-07 Thread Palmer Dabbelt
, ret_value, new_value, + write_mask & env->mideleg & sip_writable_mask); +*ret_value &= env->mideleg; +return ret; } /* Supervisor Protection and Translation */ Reviewed-by: Palmer Dabbelt Thanks!

Re: [Qemu-devel] [PATCH] target/riscv: Only flush TLB if SATP.ASID changes

2019-05-08 Thread Palmer Dabbelt
On Wed, 08 May 2019 10:38:35 PDT (-0700), jonat...@fintelia.io wrote: There is an analogous change for ARM here: https://patchwork.kernel.org/patch/10649857 Signed-off-by: Jonathan Behrens --- target/riscv/csr.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/target/risc

Re: [Qemu-devel] [PULL 4/9] linux-user/nios2 linux-user/riscv: Clean up header guards

2019-05-13 Thread Palmer Dabbelt
get_ipc_perm { abi_int __key; /* Key. */ -- 2.17.2 Reviewed-by: Palmer Dabbelt I'm assuming this is going in through someone else's tree, so I'm not going to pick it up into mine.

Re: [Qemu-devel] RISC-V: Include ROM in QEMU

2019-06-07 Thread Palmer Dabbelt
On Thu, 06 Jun 2019 16:22:47 PDT (-0700), alistai...@gmail.com wrote: Hello, As a test of the waters, how would the QEMU community feel about including the RISC-V OpenSBI project as a ROM submodule? The idea would be to have OpenSBI (similar to ATF for ARM and a BIOS for x86) included by defaul

Re: [Qemu-devel] Fwd: [j...@sing.id.au: atomic failures on qemu-system-riscv64]

2019-06-07 Thread Palmer Dabbelt
On Thu, 06 Jun 2019 19:50:57 PDT (-0700), richard.hender...@linaro.org wrote: Also, unless I'm misunderstanding something our implementation of LR/SC is pretty broken. We're just using a CAS to check if the value changed, which suffers from the ABA problem that LR/SC is there to fix in the f

Re: [Qemu-devel] [PATCH v1 2/4] disas/riscv: Disassemble reserved compressed encodings as illegal

2019-06-14 Thread Palmer Dabbelt
On Fri, 17 May 2019 15:11:01 PDT (-0700), Alistair Francis wrote: From: Michael Clark Due to the design of the disassembler, the immediate is not known during decoding of the opcode; so to handle compressed encodings with reserved immediate values (non-zero), we need to add an additional check

Re: [Qemu-devel] [PATCH v1 3/4] disas/riscv: Fix `rdinstreth` constraint

2019-06-14 Thread Palmer Dabbelt
On Fri, 17 May 2019 15:11:04 PDT (-0700), Alistair Francis wrote: From: Michael Clark The constraint for `rdinstreth` was comparing the csr number to 0xc80, which is `cycleh` instead. Fix this. Author: Wladimir J. van der Laan I'm not sure what this tag is supposed to mean. If this is the

Re: [Qemu-devel] [PATCH v1 4/4] target/riscv: Implement riscv_cpu_unassigned_access

2019-06-14 Thread Palmer Dabbelt
} + +env->badaddr = addr; +riscv_raise_exception(&cpu->env, cs->exception_index, GETPC()); +} + void riscv_cpu_do_unaligned_access(CPUState *cs, vaddr addr, MMUAccessType access_type, int mmu_idx, uintptr_t retaddr) Reviewed-by: Palmer Dabbelt

Re: [Qemu-devel] [PATCH v1 0/4] Miscellaneous patches from the RISC-V fork

2019-06-14 Thread Palmer Dabbelt
On Fri, 17 May 2019 15:10:56 PDT (-0700), Alistair Francis wrote: This should be the last series bringing the patches from the RISC-V fork into mainline QEMU. Dayeol Lee (1): target/riscv: Fix PMP range boundary address bug Michael Clark (3): disas/riscv: Disassemble reserved compressed enc

Re: [Qemu-devel] [PATCH for 4.1 v3] target/riscv: Expose time CSRs when allowed by [m|s]counteren

2019-06-14 Thread Palmer Dabbelt
On Tue, 28 May 2019 11:30:20 PDT (-0700), jonat...@fintelia.io wrote: Currently mcounteren.TM acts as though it is hardwired to zero, even though QEMU allows it to be set. This change resolves the issue by allowing reads to the time and timeh control registers when running in a privileged mode

Re: [Qemu-devel] [PULL 01/29] SiFive RISC-V GPIO Device

2019-06-14 Thread Palmer Dabbelt
On Thu, 30 May 2019 03:57:12 PDT (-0700), Peter Maydell wrote: On Sun, 26 May 2019 at 02:10, Palmer Dabbelt wrote: From: Fabien Chouteau QEMU model of the GPIO device on the SiFive E300 series SOCs. The pins are not used by a board definition yet, however this implementation can already be

[Qemu-devel] [PATCH] RISC-V: Fix a memory leak when realizing a sifive_e

2019-06-14 Thread Palmer Dabbelt
ch in SiFiveESoCState, so instead we just include them within the struct. Thanks to Peter for pointing out the bug and suggesting the fix! Fixes: 30efbf330a45 ("SiFive RISC-V GPIO Device") Signed-off-by: Palmer Dabbelt --- hw/riscv/sifive_e.c | 12 +--- include/hw/riscv/

Re: [Qemu-devel] [PATCH] RISC-V: Fix a memory leak when realizing a sifive_e

2019-06-16 Thread Palmer Dabbelt
On Fri, 14 Jun 2019 05:25:50 PDT (-0700), phi...@redhat.com wrote: On 6/14/19 2:08 PM, Palmer Dabbelt wrote: Coverity pointed out a memory leak in riscv_sifive_e_soc_realize(), where a pair of recently added MemoryRegion instances would not be freed if there were errors elsewhere in the

Re: [Qemu-devel] [PATCH] riscv/Kconfig: enable PCI_DEVICES

2019-03-12 Thread Palmer Dabbelt
On Mon, 11 Mar 2019 06:52:33 PDT (-0700), pbonz...@redhat.com wrote: On 11/03/19 13:46, Thomas Huth wrote: On 11/03/2019 10.12, David Abdurachmanov wrote: Re-enable PCI_DEVICES for RISC-V. The patch is based on other /Kconfig. Signed-off-by: David Abdurachmanov Fixes: 82a230d5a303 ("riscv-sof

[Qemu-devel] [PULL 25/29] target/riscv: Remove shift and slt insn manual decoding

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.inc.c | 93 + target/riscv/translate.c| 59 +--- 2

[Qemu-devel] [PULL 28/29] target/riscv: Remove gen_system()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann with all 16 bit insns moved to decodetree no path is falling back to gen_system(), so we can remove it. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/translate.c | 34

[Qemu-devel] [PULL 21/29] target/riscv: Remove manual decoding from gen_load()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann With decodetree we don't need to convert RISC-V opcodes into to MemOps as the old gen_load() did. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.

[Qemu-devel] [PULL 29/29] target/riscv: Remove decode_RV32_64G()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann decodetree handles all instructions now so the fallback is not necessary anymore. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/translate.c | 21 + 1

[Qemu-devel] [PULL 27/29] target/riscv: Rename trans_arith to gen_arith

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.inc.c | 18 +- target/riscv/insn_trans/trans_rvm.inc.c | 14 +++--- target/riscv/translate.c

[Qemu-devel] [PULL 26/29] target/riscv: Remove manual decoding of RV32/64M insn

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvm.inc.c | 55 ++-- target/riscv/translate.c| 320 ++-- 2 files changed

[Qemu-devel] [PULL 18/29] target/riscv: Convert quadrant 2 of RVXC insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn16.decode | 31 target/riscv/insn_trans/trans_rvc.inc.c | 101 target/riscv

[Qemu-devel] [PULL 24/29] target/riscv: make ADD/SUB/OR/XOR/AND insn use arg lists

2019-03-12 Thread Palmer Dabbelt
Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 3 +- target/riscv/insn_trans/trans_rvi.inc.c | 21 + target/riscv/translate.c| 40 +++-- 3 files changed, 34

[Qemu-devel] [PULL 12/29] target/riscv: Convert RV64F insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32-64.decode | 6 +++ target/riscv/insn_trans/trans_rvf.inc.c | 60

[Qemu-devel] [PULL 23/29] target/riscv: Move gen_arith_imm() decoding into trans_* functions

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann gen_arith_imm() does a lot of decoding manually, which was hard to read in case of the shift instructions and is not necessary anymore with decodetree. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer

[Qemu-devel] [PULL 22/29] target/riscv: Remove manual decoding from gen_store()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann With decodetree we don't need to convert RISC-V opcodes into to MemOps as the old gen_store() did. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.

[Qemu-devel] [PULL 19/29] target/riscv: Remove gen_jalr()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann trans_jalr() is the only caller, so move the code into trans_jalr(). Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.inc.c

[Qemu-devel] [PULL 17/29] target/riscv: Convert quadrant 1 of RVXC insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn16.decode | 43 +++ target/riscv/insn_trans/trans_rvc.inc.c | 151 target/riscv

[Qemu-devel] [PULL 14/29] target/riscv: Convert RV64D insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32-64.decode | 8 + target/riscv/insn_trans/trans_rvd.inc.c | 82 target/riscv

[Qemu-devel] [PULL 20/29] target/riscv: Remove manual decoding from gen_branch()

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann We now utilizes argument-sets of decodetree such that no manual decoding is necessary. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn_trans/trans_rvi.inc.c | 46

[Qemu-devel] [PULL 06/29] target/riscv: Convert RVXI fence insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 2 ++ target/riscv/insn_trans/trans_rvi.inc.c | 19

[Qemu-devel] [PULL 13/29] target/riscv: Convert RV32D insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 28 ++ target/riscv/insn_trans/trans_rvd.inc.c | 360

[Qemu-devel] [PULL 16/29] target/riscv: Convert quadrant 0 of RVXC insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/Makefile.objs | 9 ++- target/riscv/insn16.decode | 55 ++ target/riscv/insn_trans

[Qemu-devel] [PULL 11/29] target/riscv: Convert RV32F insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 35 +++ target/riscv/insn_trans/trans_rvf.inc.c | 379

[Qemu-devel] [PULL 04/29] target/riscv: Convert RV64I load/store insns to decodetree

2019-03-12 Thread Palmer Dabbelt
: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/Makefile.objs | 8 +--- target/riscv/insn32-64.decode | 25 + target/riscv/insn_trans/trans_rvi.inc.c | 20 target/riscv/translate.c| 7 --- 4

[Qemu-devel] [PULL 08/29] target/riscv: Convert RVXM insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32-64.decode | 7 ++ target/riscv/insn32.decode | 10 +++ target/riscv

[Qemu-devel] [PULL 10/29] target/riscv: Convert RV64A insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32-64.decode | 13 +++ target/riscv/insn_trans/trans_rva.inc.c | 58

[Qemu-devel] [PULL 15/29] target/riscv: Convert RV priv insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode| 15 +++ .../riscv/insn_trans/trans_privileged.inc.c | 110

[Qemu-devel] [PULL] target/riscv: Convert to decodetree

2019-03-12 Thread Palmer Dabbelt
The following changes since commit 377b155bde451d5ac545fbdcdfbf6ca17a4228f5: Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2019-03-11 18:26:37 +) are available in the Git repository at: git://github.com/palmer-dabbelt/qemu.git tags/riscv-for-

[Qemu-devel] [PULL 07/29] target/riscv: Convert RVXI csr insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 8 +++ target/riscv/insn_trans/trans_rvi.inc.c | 79

[Qemu-devel] [PULL 05/29] target/riscv: Convert RVXI arithmetic insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann we cannot remove the call to gen_arith() in decode_RV32_64G() since it is used to translate multiply instructions. Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt

[Qemu-devel] [PULL 01/29] target/riscv: Activate decodetree and implemnt LUI & AUIPC

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann for now only LUI & AUIPC are decoded and translated. If decodetree fails, we fall back to the old decoder. Reviewed-by: Richard Henderson Acked-by: Alistair Francis Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dab

[Qemu-devel] [PULL 09/29] target/riscv: Convert RV32A insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 17 +++ target/riscv/insn_trans/trans_rva.inc.c | 160

[Qemu-devel] [PULL 03/29] target/riscv: Convert RV32I load/store insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 10 ++ target/riscv/insn_trans/trans_rvi.inc.c | 48

[Qemu-devel] [PULL 02/29] target/riscv: Convert RVXI branch insns to decodetree

2019-03-12 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Palmer Dabbelt Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt Signed-off-by: Palmer Dabbelt --- target/riscv/insn32.decode | 19 ++ target/riscv/insn_trans

Re: [Qemu-devel] Maintainers, please tell us how to boot your machines!

2019-03-13 Thread Palmer Dabbelt
On Tue, 12 Mar 2019 10:36:05 PDT (-0700), arm...@redhat.com wrote: Machines with no maintainer, but at least one supporter: [...] = hw/riscv/sifive_e.c = Palmer Dabbelt (supporter:RISC-V) Alistair Francis (supporter:RISC-V) Sagar Karandikar (supporter:RISC-V) Bastian

[Qemu-devel] [PULL 23/29] target/riscv: Move gen_arith_imm() decoding into trans_* functions

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann gen_arith_imm() does a lot of decoding manually, which was hard to read in case of the shift instructions and is not necessary anymore with decodetree. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.

[Qemu-devel] [PULL 29/29] target/riscv: Remove decode_RV32_64G()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann decodetree handles all instructions now so the fallback is not necessary anymore. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/translate.c | 21 + 1 file changed, 1 insertion(+), 20 de

[Qemu-devel] [PULL 24/29] target/riscv: make ADD/SUB/OR/XOR/AND insn use arg lists

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann manual decoding in gen_arith() is not necessary with decodetree. For now the function is called trans_arith as the original gen_arith still exists. The former will be renamed to gen_arith as soon as the old gen_arith can be removed. Reviewed-by: Richard Henderson Signed

[Qemu-devel] [PULL 22/29] target/riscv: Remove manual decoding from gen_store()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann With decodetree we don't need to convert RISC-V opcodes into to MemOps as the old gen_store() did. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvi.inc.c | 27 + t

[Qemu-devel] [PULL 20/29] target/riscv: Remove manual decoding from gen_branch()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann We now utilizes argument-sets of decodetree such that no manual decoding is necessary. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvi.inc.c | 46 +--- target/riscv/t

[Qemu-devel] [PULL 26/29] target/riscv: Remove manual decoding of RV32/64M insn

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvm.inc.c | 55 ++-- target/riscv/translate.c| 320 ++-- 2 files changed, 164 insertions(+), 211 deletions

[Qemu-devel] [PULL 18/29] target/riscv: Convert quadrant 2 of RVXC insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn16.decode | 31 target/riscv/insn_trans/trans_rvc.inc.c | 101 target/riscv/translate.c| 83

[Qemu-devel] [PULL 28/29] target/riscv: Remove gen_system()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann with all 16 bit insns moved to decodetree no path is falling back to gen_system(), so we can remove it. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/translate.c | 34 -- 1

[Qemu-devel] [PULL 13/29] target/riscv: Convert RV32D insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 28 ++ target/riscv/insn_trans/trans_rvd.inc.c | 360 target/riscv/translate.

[Qemu-devel] [PULL 25/29] target/riscv: Remove shift and slt insn manual decoding

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvi.inc.c | 93 + target/riscv/translate.c| 59 +--- 2 files changed, 81 insertions(+), 71

[Qemu-devel] [PULL 27/29] target/riscv: Rename trans_arith to gen_arith

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann --- target/riscv/insn_trans/trans_rvi.inc.c | 18 +- target/riscv/insn_trans/trans_rvm.inc.c | 14 +++--- target/riscv/translate.c| 4 ++-- 3 files changed, 18 ins

[Qemu-devel] [PULL 16/29] target/riscv: Convert quadrant 0 of RVXC insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/Makefile.objs | 9 ++- target/riscv/insn16.decode | 55 ++ target/riscv/insn_trans/trans_rvc.inc.c | 75 +

[Qemu-devel] [PULL 21/29] target/riscv: Remove manual decoding from gen_load()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann With decodetree we don't need to convert RISC-V opcodes into to MemOps as the old gen_load() did. Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvi.inc.c | 35 +++-- ta

[Qemu-devel] [PULL 11/29] target/riscv: Convert RV32F insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 35 +++ target/riscv/insn_trans/trans_rvf.inc.c | 379 target/riscv/translate

[Qemu-devel] [PULL 14/29] target/riscv: Convert RV64D insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32-64.decode | 8 + target/riscv/insn_trans/trans_rvd.inc.c | 82 target/riscv/translate.c| 60

[Qemu-devel] [PULL 19/29] target/riscv: Remove gen_jalr()

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann trans_jalr() is the only caller, so move the code into trans_jalr(). Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn_trans/trans_rvi.inc.c | 28 +- target/ris

[Qemu-devel] [PULL 12/29] target/riscv: Convert RV64F insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32-64.decode | 6 +++ target/riscv/insn_trans/trans_rvf.inc.c | 60 + 2 files changed, 66 ins

[Qemu-devel] [PULL 15/29] target/riscv: Convert RV priv insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode| 15 +++ .../riscv/insn_trans/trans_privileged.inc.c | 110 ++ target/riscv/tra

[Qemu-devel] [PULL 08/29] target/riscv: Convert RVXM insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32-64.decode | 7 ++ target/riscv/insn32.decode | 10 +++ target/riscv/insn_trans/trans_rvm.inc.c | 11

[Qemu-devel] [PULL 10/29] target/riscv: Convert RV64A insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32-64.decode | 13 +++ target/riscv/insn_trans/trans_rva.inc.c | 58 ++ target/riscv/translate.c

[Qemu-devel] [PULL 07/29] target/riscv: Convert RVXI csr insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 8 +++ target/riscv/insn_trans/trans_rvi.inc.c | 79 + target/riscv/translate.

[Qemu-devel] [PULL 09/29] target/riscv: Convert RV32A insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 17 +++ target/riscv/insn_trans/trans_rva.inc.c | 160 target/riscv/translate

[Qemu-devel] [PULL 06/29] target/riscv: Convert RVXI fence insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 2 ++ target/riscv/insn_trans/trans_rvi.inc.c | 19 +++ target/riscv/translate.c

[Qemu-devel] [PULL 01/29] target/riscv: Activate decodetree and implemnt LUI & AUIPC

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann for now only LUI & AUIPC are decoded and translated. If decodetree fails, we fall back to the old decoder. Reviewed-by: Richard Henderson Acked-by: Alistair Francis Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/Makefile.objs

[Qemu-devel] [PULL 05/29] target/riscv: Convert RVXI arithmetic insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann we cannot remove the call to gen_arith() in decode_RV32_64G() since it is used to translate multiply instructions. Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32-64.decode

[Qemu-devel] [PULL 04/29] target/riscv: Convert RV64I load/store insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann this splits the 64-bit only instructions into its own decode file such that we generate the decoder for these instructions only for the RISC-V 64 bit target. Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Pee

[Qemu-devel] [PULL 02/29] target/riscv: Convert RVXI branch insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Palmer Dabbelt Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 19 ++ target/riscv/insn_trans/trans_rvi.inc.c | 49

[Qemu-devel] [PULL 03/29] target/riscv: Convert RV32I load/store insns to decodetree

2019-03-13 Thread Palmer Dabbelt
From: Bastian Koppelmann Acked-by: Alistair Francis Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt --- target/riscv/insn32.decode | 10 ++ target/riscv/insn_trans/trans_rvi.inc.c | 48 + 2 files changed, 58

[Qemu-devel] [PULL] target/riscv: Convert to decodetree

2019-03-13 Thread Palmer Dabbelt
staging (2019-03-12 21:06:26 +) are available in the Git repository at: git://github.com/palmer-dabbelt/qemu.git tags/riscv-for-master-4.0-sf4 for you to fetch changes up to 25e6ca30c668783cd72ff97080ff44e141b99f9b: target/riscv: Remove decode_RV32_64G() (2019-

Re: [Qemu-devel] [PATCH 0/2] kconfig: add fine-grained dependencies for MSI

2019-03-14 Thread Palmer Dabbelt
On Thu, 14 Mar 2019 10:30:20 PDT (-0700), alistai...@gmail.com wrote: On Thu, Mar 14, 2019 at 10:09 AM Michael S. Tsirkin wrote: On Thu, Mar 14, 2019 at 03:30:30PM +0100, Paolo Bonzini wrote: > RISC-V targets did not include PCIe ports before the Kconfig transition, > and grew them afterwards,

Re: [Qemu-devel] [PULL 17/29] target/riscv: Convert quadrant 1 of RVXC insns to decodetree

2019-03-14 Thread Palmer Dabbelt
On Thu, 14 Mar 2019 13:28:37 PDT (-0700), alistai...@gmail.com wrote: On Wed, Mar 13, 2019 at 7:53 AM Palmer Dabbelt wrote: From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer Adelt This commit is the first bad commit in

Re: [Qemu-devel] [PULL 17/29] target/riscv: Convert quadrant 1 of RVXC insns to decodetree

2019-03-14 Thread Palmer Dabbelt
On Thu, 14 Mar 2019 21:57:37 PDT (-0700), alistai...@gmail.com wrote: On Thu, Mar 14, 2019 at 8:59 PM Palmer Dabbelt wrote: On Thu, 14 Mar 2019 13:28:37 PDT (-0700), alistai...@gmail.com wrote: > On Wed, Mar 13, 2019 at 7:53 AM Palmer Dabbelt wrote: >> >> From: Bas

Re: [Qemu-devel] [PULL 17/29] target/riscv: Convert quadrant 1 of RVXC insns to decodetree

2019-03-15 Thread Palmer Dabbelt
On Fri, 15 Mar 2019 02:06:07 PDT (-0700), Bastian Koppelmann wrote: Hi Alistair On 3/14/19 9:28 PM, Alistair Francis wrote: On Wed, Mar 13, 2019 at 7:53 AM Palmer Dabbelt wrote: From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann Signed-off-by: Peer

Re: [PATCH] linux-user/riscv: Propagate fault address

2019-10-14 Thread Palmer Dabbelt
STORE: cs->exception_index = RISCV_EXCP_STORE_PAGE_FAULT; break; +default: +g_assert_not_reached(); } +env->badaddr = address; cpu_loop_exit_restore(cs, retaddr); #endif } Reviewed-by: Palmer Dabbelt I fixed up your Author tag and added this to for-master. Thanks!

Re: [PATCH v1 22/28] target/riscv: Allow specifying MMU stage

2019-10-16 Thread Palmer Dabbelt
On Mon, 07 Oct 2019 11:05:33 PDT (-0700), alistai...@gmail.com wrote: On Thu, Oct 3, 2019 at 8:53 AM Palmer Dabbelt wrote: On Fri, 23 Aug 2019 16:38:47 PDT (-0700), Alistair Francis wrote: > Signed-off-by: Alistair Francis > --- > target/riscv/cpu_help

Re: [PATCH v1 1/1] target/riscv: Remove atomic accesses to MIP CSR

2019-10-18 Thread Palmer Dabbelt
On Tue, 08 Oct 2019 15:04:18 PDT (-0700), Alistair Francis wrote: Instead of relying on atomics to access the MIP register let's update our helper function to instead just lock the IO mutex thread before writing. This follows the same concept as used in PPC for handling interrupts Signed-off-by:

Re: [PATCH v5 31/55] target/riscv: fetch code with translator_ld

2019-10-18 Thread Palmer Dabbelt
On Mon, 14 Oct 2019 10:59:07 PDT (-0700), alistai...@gmail.com wrote: On Mon, Oct 14, 2019 at 4:20 AM Alex Bennée wrote: From: "Emilio G. Cota" Signed-off-by: Emilio G. Cota Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Reviewed-by: Alistair Francis and Acked-

Re: [PATCH v4 0/3] target/riscv: Expose "priv" register for GDB

2019-10-18 Thread Palmer Dabbelt
On Mon, 14 Oct 2019 08:45:26 PDT (-0700), jonat...@fintelia.io wrote: This series adds a new "priv" virtual register that reports the current privilege mode. This is helpful for debugging purposes because that information is not actually available in any of the real CSRs. The third patch in thi

Re: [PATCH v3 1/2] hw: timer: Add Goldfish RTC device

2019-10-18 Thread Palmer Dabbelt
On Tue, 15 Oct 2019 01:35:31 PDT (-0700), Anup Patel wrote: This patch adds model for Google Goldfish virtual platform RTC device. We will be adding Goldfish RTC device to the QEMU RISC-V virt machine for providing real date-time to Guest Linux. The corresponding Linux driver for Goldfish RTC de

Re: [PATCH v3 2/2] riscv: virt: Use Goldfish RTC device

2019-10-18 Thread Palmer Dabbelt
UART0_IRQ = 10, +RTC_IRQ = 11, VIRTIO_IRQ = 1, /* 1 to 8 */ VIRTIO_COUNT = 8, PCIE_IRQ = 0x20, /* 32 to 35 */ This is a wacky enum, but it's already there. I'm going to assume this patch will get merged and then fix it later. -- 2.17.1 Reviewed-by: Palmer Dabbelt

Re: [PATCH] target/riscv: PMP violation due to wrong size parameter

2019-10-18 Thread Palmer Dabbelt
On Tue, 15 Oct 2019 10:04:32 PDT (-0700), day...@berkeley.edu wrote: Hi, Could this patch go through? If not please let me know so that I can fix. Thank you! Sorry, I dropped this one. It's in the patch queue now. We should also check for size==0 in pmp_hart_has_privs(), as that won't work.

Re: [PATCH v2 1/1] riscv/boot: Fix possible memory leak

2019-10-18 Thread Palmer Dabbelt
On Thu, 17 Oct 2019 05:08:39 PDT (-0700), Peter Maydell wrote: Ping? It would be nice to see this patch get into master to silence the coverity errors. Sorry, it looks like I dropped this. It's in my queue, I hope to submit a PR soon. thanks -- PMM On Thu, 3 Oct 2019 at 18:05, Alistair F

Re: [PATCH] target/riscv: PMP violation due to wrong size parameter

2019-10-23 Thread Palmer Dabbelt
On Tue, 22 Oct 2019 14:21:29 PDT (-0700), day...@berkeley.edu wrote: riscv_cpu_tlb_fill() uses the `size` parameter to check PMP violation using pmp_hart_has_privs(). However, if the size is unknown (=0), the ending address will be `addr - 1` as it is `addr + size - 1` in `pmp_hart_has_privs()`.

Re: [PATCH v2 25/35] target/riscv: Only set TB flags with FP status if enabled

2020-02-13 Thread Palmer Dabbelt
(env, 0); +if (riscv_cpu_fp_enabled(env)) { +*flags |= env->mstatus & MSTATUS_FS; +} #endif } Reviewed-by: Palmer Dabbelt

Re: [PATCH v2 26/35] target/riscv: Disable guest FP support based on virtual status

2020-02-13 Thread Palmer Dabbelt
riscv_cpu_fp_enabled(CPURISCVState *env) { if (env->mstatus & MSTATUS_FS) { +if (riscv_cpu_virt_enabled(env) && !(env->mstatus_hs & MSTATUS_FS)) { +return false; +} return true; } Reviewed-by: Palmer Dabbelt

  1   2   3   4   5   6   7   8   9   10   >