summaryrefslogtreecommitdiffstats
path: root/drivers/s390/net/qeth_eddp.c
diff options
context:
space:
mode:
authorFrank Blaschka <frank.blaschka@de.ibm.com>2007-10-05 16:45:45 +0200
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 16:54:40 -0700
commit6570ebc4f57ad0761104f769576ae5652d9b8d64 (patch)
tree47c933e7ac978754504a26cd82204fc5b31c8e96 /drivers/s390/net/qeth_eddp.c
parentbc4b2b497aa61c79e3f3444237a4003a254ea565 (diff)
downloadlinux-6570ebc4f57ad0761104f769576ae5652d9b8d64.tar.gz
linux-6570ebc4f57ad0761104f769576ae5652d9b8d64.tar.bz2
linux-6570ebc4f57ad0761104f769576ae5652d9b8d64.zip
qeth: EDDP does not work on large MTUs
Fix filling the qdio buffers in EDDP mode. Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com> Signed-off-by: Ursula Braun <braunu@de.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/s390/net/qeth_eddp.c')
-rw-r--r--drivers/s390/net/qeth_eddp.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/s390/net/qeth_eddp.c b/drivers/s390/net/qeth_eddp.c
index 70108fb16906..e3c268cfbffe 100644
--- a/drivers/s390/net/qeth_eddp.c
+++ b/drivers/s390/net/qeth_eddp.c
@@ -159,13 +159,15 @@ qeth_eddp_fill_buffer(struct qeth_qdio_out_q *queue,
buffer = buf->buffer;
/* fill one skb into buffer */
for (i = 0; i < ctx->elements_per_skb; ++i){
- buffer->element[buf->next_element_to_fill].addr =
- ctx->elements[element].addr;
- buffer->element[buf->next_element_to_fill].length =
- ctx->elements[element].length;
- buffer->element[buf->next_element_to_fill].flags =
- ctx->elements[element].flags;
- buf->next_element_to_fill++;
+ if (ctx->elements[element].length != 0) {
+ buffer->element[buf->next_element_to_fill].
+ addr = ctx->elements[element].addr;
+ buffer->element[buf->next_element_to_fill].
+ length = ctx->elements[element].length;
+ buffer->element[buf->next_element_to_fill].
+ flags = ctx->elements[element].flags;
+ buf->next_element_to_fill++;
+ }
element++;
elements--;
}