]> git.proxmox.com Git - mirror_qemu.git/commitdiff
target/s390x: move get_per_in_range() to misc_helper.c
authorDavid Hildenbrand <david@redhat.com>
Fri, 18 Aug 2017 11:43:48 +0000 (13:43 +0200)
committerCornelia Huck <cohuck@redhat.com>
Wed, 30 Aug 2017 16:23:25 +0000 (18:23 +0200)
Only used in that file.

Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: David Hildenbrand <david@redhat.com>
Message-Id: <20170818114353.13455-14-david@redhat.com>
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
target/s390x/cpu.h
target/s390x/misc_helper.c

index 9cdce6c6bdb52bd86af619be6db066222c4b8963..55aab52f8441ba1591458fab27434bb1686498c3 100644 (file)
@@ -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);
index 34d730ba73c09bfa5d8bb81b9d5ee92524bd08c5..d5497cbcbaf9863fbf918513cef969b6c1156b0e 100644 (file)
@@ -455,6 +455,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)) {