From: Frank Blaschka Date: Tue, 1 Apr 2008 08:26:59 +0000 (+0200) Subject: qeth: core code should alloc headroom for LLC protocol X-Git-Tag: v2.6.26-rc1~1138^2~8^2~13 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=b403e685b7c57f7912bae36987433e72c616f418;p=linux-2.6-omap-h63xx.git qeth: core code should alloc headroom for LLC protocol Allocate headroom for TR_HLEN but using only ETH_HLEN causes rx performance degradation. Allocate ETH_HLEN for ethernet and TR_HLEN for token ring (layer 3 mode). Signed-off-by: Frank Blaschka Signed-off-by: Jeff Garzik --- diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 5cfe0ef7719..055f5c3e7b5 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -4002,7 +4002,11 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, } } else { skb_len = (*hdr)->hdr.l3.length; - headroom = max((int)ETH_HLEN, (int)TR_HLEN); + if ((card->info.link_type == QETH_LINK_TYPE_LANE_TR) || + (card->info.link_type == QETH_LINK_TYPE_HSTR)) + headroom = TR_HLEN; + else + headroom = ETH_HLEN; } if (!skb_len)