s390/zcrypt: Fix AP queue handling if queue is full
[deliverable/linux.git] / drivers / s390 / crypto / ap_bus.c
index 61f768518a34b0e963cd6b569610045a3f65188b..24ec282e15d8ae436e7dab130a4696708e34be9e 100644 (file)
@@ -599,8 +599,10 @@ static enum ap_wait ap_sm_read(struct ap_device *ap_dev)
        status = ap_sm_recv(ap_dev);
        switch (status.response_code) {
        case AP_RESPONSE_NORMAL:
-               if (ap_dev->queue_count > 0)
+               if (ap_dev->queue_count > 0) {
+                       ap_dev->state = AP_STATE_WORKING;
                        return AP_WAIT_AGAIN;
+               }
                ap_dev->state = AP_STATE_IDLE;
                return AP_WAIT_NONE;
        case AP_RESPONSE_NO_PENDING_REPLY:
This page took 0.023859 seconds and 5 git commands to generate.