qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3 6/7] s390x/kvm: handle AP instruction interce


From: Tony Krowiak
Subject: Re: [Qemu-devel] [PATCH v3 6/7] s390x/kvm: handle AP instruction interception
Date: Mon, 2 Apr 2018 12:39:29 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0

On 03/26/2018 08:01 AM, Halil Pasic wrote:

On 03/26/2018 11:03 AM, Pierre Morel wrote:
+int ap_device_handle_pqap(S390CPU *cpu)
+{
+    CPUS390XState *env = &cpu->env;
+    int fc = 4 & (env->regs[0] >> 24);
+
+    /*
+     * The Query Configuration Information (QCI) function (fc == 4) does not
+     * set a response code in reg 1, so check for that along with the
+     * AP feature.
+     */
+    if ((fc != 4) && s390_has_feat(S390_FEAT_AP)) {
+        env->regs[1] = 0x10000;
+
+        return 0;
+    }
This would imply an operation exception in case fc==4, which sounds very
wrong.
Yes, operation exception is a wrong response under the condition
(fc == 4) && s390_has_feat(S390_FEAT_AP).
See my response to Pierre:
Message ID: <address@hidden>

@David:
FYI Tony is likely to respond after Wednesday as he is on vacation right
now.

It depends but I think that the S390_FEAT_AP_QUERY_CONFIG_INFO must be tested
to know what to answer.
If the feature is there, QCI must be answered correctly.

there are also some error situations to handle in all three functions.

I agree.

Regards,
Halil





reply via email to

[Prev in Thread] Current Thread [Next in Thread]