99746de6 | 07-Oct-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Implement TCGCPUOps.tlb_fill_align
Convert hppa_cpu_tlb_fill to hppa_cpu_tlb_fill_align so that we can recognize alignment exceptions in the correct priority order.
Resolves: https://b
target/hppa: Implement TCGCPUOps.tlb_fill_align
Convert hppa_cpu_tlb_fill to hppa_cpu_tlb_fill_align so that we can recognize alignment exceptions in the correct priority order.
Resolves: https://bugzilla.kernel.org/show_bug.cgi?id=219339 Tested-by: Helge Deller <deller@gmx.de> Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
5d29587b | 05-Oct-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Handle alignment faults in hppa_get_physical_address
In Chapter 5, Interruptions, the group 3 exceptions lists "Unaligned data reference trap" has higher priority than "Data memory brea
target/hppa: Handle alignment faults in hppa_get_physical_address
In Chapter 5, Interruptions, the group 3 exceptions lists "Unaligned data reference trap" has higher priority than "Data memory break trap".
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
d73d4a5d | 05-Oct-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Fix priority of T, D, and B page faults
Drop the 'else' so that ret is overridden with the highest priority fault.
Fixes: d8bc1381250 ("target/hppa: Implement PSW_X") Reviewed-by: Helg
target/hppa: Fix priority of T, D, and B page faults
Drop the 'else' so that ret is overridden with the highest priority fault.
Fixes: d8bc1381250 ("target/hppa: Implement PSW_X") Reviewed-by: Helge Deller <deller@gmx.de> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
32142b80 | 05-Oct-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Perform access rights before protection id check
In Chapter 5, Interruptions, the group 3 exceptions lists "Data memory access rights trap" in priority order ahead of "Data memory prote
target/hppa: Perform access rights before protection id check
In Chapter 5, Interruptions, the group 3 exceptions lists "Data memory access rights trap" in priority order ahead of "Data memory protection ID trap".
Swap these checks in hppa_get_physical_address.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
d33d3adb | 03-Sep-2024 |
Helge Deller <deller@gmx.de> |
target/hppa: Fix random 32-bit linux-user crashes
The linux-user hppa target crashes randomly for me since commit 081a0ed188d8 ("target/hppa: Do not mask in copy_iaoq_entry").
That commit dropped t
target/hppa: Fix random 32-bit linux-user crashes
The linux-user hppa target crashes randomly for me since commit 081a0ed188d8 ("target/hppa: Do not mask in copy_iaoq_entry").
That commit dropped the masking of the IAOQ addresses while copying them from other registers and instead keeps them with all 64 bits up until the full gva is formed with the help of hppa_form_gva_psw().
So, when running in linux-user mode on an emulated 64-bit CPU, we need to mask to a 32-bit address space at the very end in hppa_form_gva_psw() if the PSW-W flag isn't set (which is the case for linux-user on hppa).
Fixes: 081a0ed188d8 ("target/hppa: Do not mask in copy_iaoq_entry") Cc: qemu-stable@nongnu.org # v9.1+ Signed-off-by: Helge Deller <deller@gmx.de> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
6dd9b145 | 13-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Implement CF_PCREL
Now that the groundwork has been laid, enabling CF_PCREL within the translator proper is a simple matter of updating copy_iaoq_entry and install_iaq_entries.
We also
target/hppa: Implement CF_PCREL
Now that the groundwork has been laid, enabling CF_PCREL within the translator proper is a simple matter of updating copy_iaoq_entry and install_iaq_entries.
We also need to modify the unwind info, since we no longer have absolute addresses to install.
As expected, this reduces the runtime overhead of compilation when running a Linux kernel with address space randomization enabled.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
804cd52d | 13-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Adjust priv for B,GATE at runtime
Do not compile in the priv change based on the first translation; look up the PTE at execution time. This is required for CF_PCREL, where a page may b
target/hppa: Adjust priv for B,GATE at runtime
Do not compile in the priv change based on the first translation; look up the PTE at execution time. This is required for CF_PCREL, where a page may be mapped multiple times with different attributes.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
190d7fa5 | 13-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Drop tlb_entry return from hppa_get_physical_address
The return-by-reference is never used.
Reviewed-by: Helge Deller <deller@gmx.de> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro
target/hppa: Drop tlb_entry return from hppa_get_physical_address
The return-by-reference is never used.
Reviewed-by: Helge Deller <deller@gmx.de> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
d8bc1381 | 16-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Implement PSW_X
Use PAGE_WRITE_INV to temporarily enable write permission on for a given page, driven by PSW_X being set.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richa
target/hppa: Implement PSW_X
Use PAGE_WRITE_INV to temporarily enable write permission on for a given page, driven by PSW_X being set.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
5ae8adbb | 16-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Implement PSW_B
PSW_B causes B,GATE to trap as an illegal instruction, removing our previous sequential execution test that was merely an approximation.
Reviewed-by: Helge Deller <dell
target/hppa: Implement PSW_B
PSW_B causes B,GATE to trap as an illegal instruction, removing our previous sequential execution test that was merely an approximation.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
d27fe7c3 | 16-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Manage PSW_X and PSW_B in translator
PSW_X is cleared after every instruction, and only set by RFI. PSW_B is cleared after every non-branch, or branch not taken, and only set by taken b
target/hppa: Manage PSW_X and PSW_B in translator
PSW_X is cleared after every instruction, and only set by RFI. PSW_B is cleared after every non-branch, or branch not taken, and only set by taken branches. We can clear both bits with a single store, at most once per TB. Taken branches set PSW_B, at most once per TB.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
ebc9401a | 16-Apr-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Split PSW X and B into their own field
Generally, both of these bits are cleared at the end of each instruction. By separating these, we will be able to clear both with a single insn,
target/hppa: Split PSW X and B into their own field
Generally, both of these bits are cleared at the end of each instruction. By separating these, we will be able to clear both with a single insn, instead of 2 or 3.
Reviewed-by: Helge Deller <deller@gmx.de> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
d2e22fde | 28-Mar-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Improve hppa_cpu_dump_state
Print both raw IAQ_Front and IAQ_Back as well as the GVAs. Print control registers in system mode. Print floating point registers if CPU_DUMP_FPU.
Reviewed-
target/hppa: Improve hppa_cpu_dump_state
Print both raw IAQ_Front and IAQ_Back as well as the GVAs. Print control registers in system mode. Print floating point registers if CPU_DUMP_FPU.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
081a0ed1 | 27-Mar-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Do not mask in copy_iaoq_entry
As with loads and stores, code offsets are kept intact until the full gva is formed. In qemu, this is in cpu_get_tb_cpu_state.
Reviewed-by: Helge Deller
target/hppa: Do not mask in copy_iaoq_entry
As with loads and stores, code offsets are kept intact until the full gva is formed. In qemu, this is in cpu_get_tb_cpu_state.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
9dfcd243 | 27-Mar-2024 |
Richard Henderson <richard.henderson@linaro.org> |
target/hppa: Store full iaoq_f and page offset of iaoq_b in TB
In preparation for CF_PCREL. store the iaoq_f in 3 parts: high bits in cs_base, middle bits in pc, and low bits in priv. For iaoq_b, se
target/hppa: Store full iaoq_f and page offset of iaoq_b in TB
In preparation for CF_PCREL. store the iaoq_f in 3 parts: high bits in cs_base, middle bits in pc, and low bits in priv. For iaoq_b, set a bit for either of space or page differing, else the page offset.
Install iaq entries before goto_tb. The change to not record the full direct branch difference in TB means that we have to store at least iaoq_b before goto_tb. But since a later change to enable CF_PCREL will require both iaoq_f and iaoq_b to be updated before goto_tb, go ahead and update both fields now.
Reviewed-by: Helge Deller <deller@gmx.de> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|