diff options
author | Julian Wiedmann <jwi@linux.vnet.ibm.com> | 2017-10-23 09:40:16 +0200 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2017-12-05 07:51:08 +0100 |
commit | 0b926ac304a9b315f0ce8ce2ae5373b5a0478b68 (patch) | |
tree | da3641c7c26c4cee5f043cf338a1b4175d422d91 /drivers/s390 | |
parent | edfb8d8fcb94a75b2e61c63549d4a5f6474ad3d2 (diff) |
s390/qdio: consider ERROR buffers for inbound-full condition
In the unlikely case that an ERROR buffer (presented by the HW)
consumed the last available slot on the input queue, increment the
corresponding statistics counter.
Signed-off-by: Julian Wiedmann <jwi@linux.vnet.ibm.com>
Reviewed-by: Benjamin Block <bblock@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/cio/qdio_main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/s390/cio/qdio_main.c b/drivers/s390/cio/qdio_main.c index 59b4a3370cd5..d681e6b56add 100644 --- a/drivers/s390/cio/qdio_main.c +++ b/drivers/s390/cio/qdio_main.c @@ -536,7 +536,8 @@ static int get_inbound_buffer_frontier(struct qdio_q *q) case SLSB_P_INPUT_ERROR: process_buffer_error(q, count); q->first_to_check = add_buf(q->first_to_check, count); - atomic_sub(count, &q->nr_buf_used); + if (atomic_sub_return(count, &q->nr_buf_used) == 0) + qperf_inc(q, inbound_queue_full); if (q->irq_ptr->perf_stat_enabled) account_sbals_error(q, count); break; |