[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v3 for-2.11 13/18] target/s390x: move get_per_in_ran
From: |
David Hildenbrand |
Subject: |
[Qemu-devel] [PATCH v3 for-2.11 13/18] target/s390x: move get_per_in_range() to misc_helper.c |
Date: |
Fri, 18 Aug 2017 13:43:48 +0200 |
Only used in that file.
Reviewed-by: Thomas Huth <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Signed-off-by: David Hildenbrand <address@hidden>
---
target/s390x/cpu.h | 11 -----------
target/s390x/misc_helper.c | 11 +++++++++++
2 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/target/s390x/cpu.h b/target/s390x/cpu.h
index 9cdce6c..55aab52 100644
--- a/target/s390x/cpu.h
+++ b/target/s390x/cpu.h
@@ -438,17 +438,6 @@ static inline uint8_t get_per_atmid(CPUS390XState *env)
((env->psw.mask & PSW_ASC_ACCREG)? (1 << 2) : 0);
}
-/* Check if an address is within the PER starting address and the PER
- ending address. The address range might loop. */
-static inline bool get_per_in_range(CPUS390XState *env, uint64_t addr)
-{
- if (env->cregs[10] <= env->cregs[11]) {
- return env->cregs[10] <= addr && addr <= env->cregs[11];
- } else {
- return env->cregs[10] <= addr || addr <= env->cregs[11];
- }
-}
-
S390CPU *cpu_s390x_init(const char *cpu_model);
S390CPU *s390x_new_cpu(const char *cpu_model, int64_t id, Error **errp);
S390CPU *cpu_s390x_create(const char *cpu_model, Error **errp);
diff --git a/target/s390x/misc_helper.c b/target/s390x/misc_helper.c
index d23ffcd..ab0c53d 100644
--- a/target/s390x/misc_helper.c
+++ b/target/s390x/misc_helper.c
@@ -451,6 +451,17 @@ void HELPER(per_check_exception)(CPUS390XState *env)
}
}
+/* Check if an address is within the PER starting address and the PER
+ ending address. The address range might loop. */
+static inline bool get_per_in_range(CPUS390XState *env, uint64_t addr)
+{
+ if (env->cregs[10] <= env->cregs[11]) {
+ return env->cregs[10] <= addr && addr <= env->cregs[11];
+ } else {
+ return env->cregs[10] <= addr || addr <= env->cregs[11];
+ }
+}
+
void HELPER(per_branch)(CPUS390XState *env, uint64_t from, uint64_t to)
{
if ((env->cregs[9] & PER_CR9_EVENT_BRANCH)) {
--
2.9.4
[Qemu-devel] [PATCH v3 for-2.11 09/18] target/s390x: move cc_name() to helper.c, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 10/18] target/s390x: move cpu_mmu_idx_to_asc() to excp_helper.c, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 12/18] target/s390x: move s390_do_cpu_reset() to diag.c, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 11/18] target/s390x: move psw_key_valid() to mem_helper.c, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 13/18] target/s390x: move get_per_in_range() to misc_helper.c,
David Hildenbrand <=
[Qemu-devel] [PATCH v3 for-2.11 14/18] target/s390x: introduce internal.h, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 16/18] s390x: avoid calling kvm_ functions outside of target/s390x/, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 15/18] target/s390x: move a couple of functions to cpu.c, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 17/18] s390x/kvm: move KVM declarations and stubs to separate files, David Hildenbrand, 2017/08/18
[Qemu-devel] [PATCH v3 for-2.11 18/18] target/s390x: cleanup cpu.h, David Hildenbrand, 2017/08/18
Re: [Qemu-devel] [PATCH v3 for-2.11 00/18] target/s390x: cleanup cpu.h, David Hildenbrand, 2017/08/18
Re: [Qemu-devel] [PATCH v3 for-2.11 00/18] target/s390x: cleanup cpu.h, Cornelia Huck, 2017/08/24