aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/cio/qdio_thinint.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/s390/cio/qdio_thinint.c')
-rw-r--r--drivers/s390/cio/qdio_thinint.c57
1 files changed, 0 insertions, 57 deletions
diff --git a/drivers/s390/cio/qdio_thinint.c b/drivers/s390/cio/qdio_thinint.c
index c655d011a78d..e122f780f5ee 100644
--- a/drivers/s390/cio/qdio_thinint.c
+++ b/drivers/s390/cio/qdio_thinint.c
@@ -126,68 +126,11 @@ void tiqdio_remove_input_queues(struct qdio_irq *irq_ptr)
126 } 126 }
127} 127}
128 128
129static inline int tiqdio_inbound_q_done(struct qdio_q *q)
130{
131 unsigned char state = 0;
132
133 if (!atomic_read(&q->nr_buf_used))
134 return 1;
135
136 qdio_siga_sync_q(q);
137 get_buf_state(q, q->first_to_check, &state, 0);
138
139 if (state == SLSB_P_INPUT_PRIMED)
140 /* more work coming */
141 return 0;
142 return 1;
143}
144
145static inline int shared_ind(struct qdio_irq *irq_ptr) 129static inline int shared_ind(struct qdio_irq *irq_ptr)
146{ 130{
147 return irq_ptr->dsci == &q_indicators[TIQDIO_SHARED_IND].ind; 131 return irq_ptr->dsci == &q_indicators[TIQDIO_SHARED_IND].ind;
148} 132}
149 133
150static void __tiqdio_inbound_processing(struct qdio_q *q)
151{
152 qdio_perf_stat_inc(&perf_stats.thinint_inbound);
153 qdio_sync_after_thinint(q);
154
155 /*
156 * Maybe we have work on our outbound queues... at least
157 * we have to check the PCI capable queues.
158 */
159 qdio_check_outbound_after_thinint(q);
160
161 if (!qdio_inbound_q_moved(q))
162 return;
163
164 qdio_kick_handler(q);
165
166 if (!tiqdio_inbound_q_done(q)) {
167 qdio_perf_stat_inc(&perf_stats.thinint_inbound_loop);
168 if (likely(q->irq_ptr->state != QDIO_IRQ_STATE_STOPPED))
169 tasklet_schedule(&q->tasklet);
170 }
171
172 qdio_stop_polling(q);
173 /*
174 * We need to check again to not lose initiative after
175 * resetting the ACK state.
176 */
177 if (!tiqdio_inbound_q_done(q)) {
178 qdio_perf_stat_inc(&perf_stats.thinint_inbound_loop2);
179 if (likely(q->irq_ptr->state != QDIO_IRQ_STATE_STOPPED))
180 tasklet_schedule(&q->tasklet);
181 }
182}
183
184void tiqdio_inbound_processing(unsigned long data)
185{
186 struct qdio_q *q = (struct qdio_q *)data;
187
188 __tiqdio_inbound_processing(q);
189}
190
191/* check for work on all inbound thinint queues */ 134/* check for work on all inbound thinint queues */
192static void tiqdio_tasklet_fn(unsigned long data) 135static void tiqdio_tasklet_fn(unsigned long data)
193{ 136{