QETH_DBF_TEXT_(trace, 2, "%s", CARD_DDEV_ID(queue->card)); 
qeth_flush_buffers(struct qeth_qdio_out_q *queue, int under_int,		   int index, int count){	struct qeth_qdio_out_buffer *buf;	int rc;	int i;	QETH_DBF_TEXT(trace, 6, "flushbuf");	for (i = index; i < index + count; ++i) {		buf = &queue->bufs[i % QDIO_MAX_BUFFERS_PER_Q];		buf->buffer->element[buf->next_element_to_fill - 1].flags |=				SBAL_FLAGS_LAST_ENTRY;		if (queue->card->info.type == QETH_CARD_TYPE_IQD)			continue;		if (!queue->do_pack){			if ((atomic_read(&queue->used_buffers) >=		    		(QETH_HIGH_WATERMARK_PACK -				 QETH_WATERMARK_PACK_FUZZ)) &&		    	    !atomic_read(&queue->set_pci_flags_count)){				/* it's likely that we'll go to packing				 * mode soon */				atomic_inc(&queue->set_pci_flags_count);				buf->buffer->element[0].flags |= 0x40;			}		} else {			if (!atomic_read(&queue->set_pci_flags_count)){				/*				 * there's no outstanding PCI any more, so we				 * have to request a PCI to be sure the the PCI				 * will wake at some time in the future then we				 * can flush packed buffers that might still be				 * hanging around, which can happen if no				 * further send was requested by the stack				 */				atomic_inc(&queue->set_pci_flags_count);				buf->buffer->element[0].flags |= 0x40;			}		}	}	queue->card->dev->trans_start = jiffies;#ifdef CONFIG_QETH_PERF_STATS	queue->card->perf_stats.outbound_do_qdio_cnt++;	queue->card->perf_stats.outbound_do_qdio_start_time = qeth_get_micros();#endif	if (under_int)		rc = do_QDIO(CARD_DDEV(queue->card),			     QDIO_FLAG_SYNC_OUTPUT | QDIO_FLAG_UNDER_INTERRUPT,			     queue->queue_no, index, count, NULL);	else		rc = do_QDIO(CARD_DDEV(queue->card), QDIO_FLAG_SYNC_OUTPUT,			     queue->queue_no, index, count, NULL);#ifdef CONFIG_QETH_PERF_STATS	queue->card->perf_stats.outbound_do_qdio_time += qeth_get_micros() -		queue->card->perf_stats.outbound_do_qdio_start_time;#endif	if (rc){		QETH_DBF_SPRINTF(trace, 0, "qeth_flush_buffers: do_QDIO "				 "returned error (%i) on device %s.",				 rc, CARD_DDEV_ID(queue->card));		QETH_DBF_TEXT(trace, 2, "flushbuf");		QETH_DBF_TEXT_(trace, 2, " err%d", rc);		queue->card->stats.tx_errors += count;		/* this must not happen under normal circumstances. if it		 * happens something is really wrong -> recover */		qeth_schedule_recovery(queue->card);		return;	}	atomic_add(count, &queue->used_buffers);#ifdef CONFIG_QETH_PERF_STATS	queue->card->perf_stats.bufs_sent += count;#endif}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/f3d242e8f2bf12cb45eb35b7d2e69483d1209b13/qeth_main.c/buggy/drivers/s390/net/qeth_main.c