]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/suse-2.6.27.39/patches.arch/s390-17-perf-05-qdio_extract_all_primed_SBALs_at_once.patch
Fix oinkmaster patch.
[ipfire-2.x.git] / src / patches / suse-2.6.27.39 / patches.arch / s390-17-perf-05-qdio_extract_all_primed_SBALs_at_once.patch
CommitLineData
82094b55
AF
1From: Gerald Schaefer <geraldsc@de.ibm.com>
2Subject: [PATCH] qdio: extract all primed SBALs at once
3References: bnc#532063,LTC#55526
4
5From: Jan Glauber <jang@linux.vnet.ibm.com>
6
7For devices without QIOASSIST primed SBALS were extracted in a loop.
8Remove the loop since get_buf_states can already return more than
9one primed SBAL.
10
11Signed-off-by: Jan Glauber <jang@linux.vnet.ibm.com>
12
13Acked-by: John Jolly <jjolly@suse.de>
14
15---
16 drivers/s390/cio/qdio_main.c | 34 ++++++----------------------------
17 1 file changed, 6 insertions(+), 28 deletions(-)
18
19Index: linux-sles11/drivers/s390/cio/qdio_main.c
20===================================================================
21--- linux-sles11.orig/drivers/s390/cio/qdio_main.c
22+++ linux-sles11/drivers/s390/cio/qdio_main.c
23@@ -467,19 +467,13 @@ static int get_inbound_buffer_frontier(s
24 count = min(atomic_read(&q->nr_buf_used), QDIO_MAX_BUFFERS_MASK);
25 stop = add_buf(q->first_to_check, count);
26
27- /*
28- * No siga sync here, as a PCI or we after a thin interrupt
29- * will sync the queues.
30- */
31-
32- /* need to set count to 1 for non-qebsm */
33- if (!is_qebsm(q))
34- count = 1;
35-
36-check_next:
37 if (q->first_to_check == stop)
38 goto out;
39
40+ /*
41+ * No siga sync here, as a PCI or we after a thin interrupt
42+ * already sync'ed the queues.
43+ */
44 count = get_buf_states(q, q->first_to_check, &state, count, 1);
45 if (!count)
46 goto out;
47@@ -487,14 +481,9 @@ check_next:
48 switch (state) {
49 case SLSB_P_INPUT_PRIMED:
50 inbound_primed(q, count);
51- /*
52- * No siga-sync needed for non-qebsm here, as the inbound queue
53- * will be synced on the next siga-r, resp.
54- * tiqdio_is_inbound_q_done will do the siga-sync.
55- */
56 q->first_to_check = add_buf(q->first_to_check, count);
57 atomic_sub(count, &q->nr_buf_used);
58- goto check_next;
59+ break;
60 case SLSB_P_INPUT_ERROR:
61 announce_buffer_error(q, count);
62 /* process the buffer, the upper layer will take care of it */
63@@ -653,11 +642,6 @@ static int get_outbound_buffer_frontier(
64 count = min(atomic_read(&q->nr_buf_used), QDIO_MAX_BUFFERS_MASK);
65 stop = add_buf(q->first_to_check, count);
66
67- /* need to set count to 1 for non-qebsm */
68- if (!is_qebsm(q))
69- count = 1;
70-
71-check_next:
72 if (q->first_to_check == stop)
73 return q->first_to_check;
74
75@@ -672,13 +656,7 @@ check_next:
76
77 atomic_sub(count, &q->nr_buf_used);
78 q->first_to_check = add_buf(q->first_to_check, count);
79- /*
80- * We fetch all buffer states at once. get_buf_states may
81- * return count < stop. For QEBSM we do not loop.
82- */
83- if (is_qebsm(q))
84- break;
85- goto check_next;
86+ break;
87 case SLSB_P_OUTPUT_ERROR:
88 announce_buffer_error(q, count);
89 /* process the buffer, the upper layer will take care of it */