From 9627923062b6a5c40964b188bb222ec8c02fd2d6 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Mon, 18 Sep 2017 21:18:17 +0200 Subject: s390/qeth: remove unused code in qdio_establish_cq() Storing the number of input buffers into 'i' has no effect, it is immediately re-assigned in the next line. Signed-off-by: Julian Wiedmann Reviewed-by: Ursula Braun Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index bae7440abc01..77032801e30b 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -4923,7 +4923,6 @@ static void qeth_qdio_establish_cq(struct qeth_card *card, if (card->options.cq == QETH_CQ_ENABLED) { int offset = QDIO_MAX_BUFFERS_PER_Q * (card->qdio.no_in_queues - 1); - i = QDIO_MAX_BUFFERS_PER_Q * (card->qdio.no_in_queues - 1); for (i = 0; i < QDIO_MAX_BUFFERS_PER_Q; ++i) { in_sbal_ptrs[offset + i] = (struct qdio_buffer *) virt_to_phys(card->qdio.c_q->bufs[i].buffer); -- cgit v1.2.3 From 7c2e9ba373264b29a35d6df06cc5fb125d189b90 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Mon, 18 Sep 2017 21:18:18 +0200 Subject: s390/qeth: don't take queue lock in send_packet_fast() Locking the output queue prior to TX is needed on OSA devices, to synchronize against a packing flush from the TX completion code (via qeth_check_outbound_queue()). But send_packet_fast() is only used for IQDs, which don't do packing. So remove the locking, and apply some easy cleanups. Signed-off-by: Julian Wiedmann Reviewed-by: Ursula Braun Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 77032801e30b..68e118f1202e 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -4040,35 +4040,23 @@ static int qeth_fill_buffer(struct qeth_qdio_out_q *queue, return flush_cnt; } -int qeth_do_send_packet_fast(struct qeth_card *card, - struct qeth_qdio_out_q *queue, struct sk_buff *skb, +int qeth_do_send_packet_fast(struct qeth_qdio_out_q *queue, struct sk_buff *skb, struct qeth_hdr *hdr, unsigned int offset, unsigned int hd_len) { - struct qeth_qdio_out_buffer *buffer; - int index; + int index = queue->next_buf_to_fill; + struct qeth_qdio_out_buffer *buffer = queue->bufs[index]; - /* spin until we get the queue ... */ - while (atomic_cmpxchg(&queue->state, QETH_OUT_Q_UNLOCKED, - QETH_OUT_Q_LOCKED) != QETH_OUT_Q_UNLOCKED); - /* ... now we've got the queue */ - index = queue->next_buf_to_fill; - buffer = queue->bufs[queue->next_buf_to_fill]; /* * check if buffer is empty to make sure that we do not 'overtake' * ourselves and try to fill a buffer that is already primed */ if (atomic_read(&buffer->state) != QETH_QDIO_BUF_EMPTY) - goto out; - queue->next_buf_to_fill = (queue->next_buf_to_fill + 1) % - QDIO_MAX_BUFFERS_PER_Q; - atomic_set(&queue->state, QETH_OUT_Q_UNLOCKED); + return -EBUSY; + queue->next_buf_to_fill = (index + 1) % QDIO_MAX_BUFFERS_PER_Q; qeth_fill_buffer(queue, buffer, skb, hdr, offset, hd_len); qeth_flush_buffers(queue, index, 1); return 0; -out: - atomic_set(&queue->state, QETH_OUT_Q_UNLOCKED); - return -EBUSY; } EXPORT_SYMBOL_GPL(qeth_do_send_packet_fast); -- cgit v1.2.3 From ce34435641456a680309d84c85b48e004ef45f41 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:13 +0200 Subject: s390/qeth: rely on kernel for feature recovery When recovering a device, qeth needs to re-run the IPA commands that enable all previously active HW features. Instead of duplicating qeth_set_features(), let netdev_update_features() recover the missing HW features from dev->wanted_features. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 40 ++++++++++++++++++--------------------- 1 file changed, 18 insertions(+), 22 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 68e118f1202e..e10e5b8d476c 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -6403,32 +6403,29 @@ static int qeth_set_ipa_tso(struct qeth_card *card, int on) return rc; } -/* try to restore device features on a device after recovery */ -int qeth_recover_features(struct net_device *dev) +#define QETH_HW_FEATURES (NETIF_F_RXCSUM | NETIF_F_IP_CSUM | NETIF_F_TSO) + +/** + * qeth_recover_features() - Restore device features after recovery + * @dev: the recovering net_device + * + * Caller must hold rtnl lock. + */ +void qeth_recover_features(struct net_device *dev) { + netdev_features_t features = dev->features; struct qeth_card *card = dev->ml_priv; - netdev_features_t recover = dev->features; - - if (recover & NETIF_F_IP_CSUM) { - if (qeth_set_ipa_csum(card, 1, IPA_OUTBOUND_CHECKSUM)) - recover ^= NETIF_F_IP_CSUM; - } - if (recover & NETIF_F_RXCSUM) { - if (qeth_set_ipa_csum(card, 1, IPA_INBOUND_CHECKSUM)) - recover ^= NETIF_F_RXCSUM; - } - if (recover & NETIF_F_TSO) { - if (qeth_set_ipa_tso(card, 1)) - recover ^= NETIF_F_TSO; - } - if (recover == dev->features) - return 0; + /* force-off any feature that needs an IPA sequence. + * netdev_update_features() will restart them. + */ + dev->features &= ~QETH_HW_FEATURES; + netdev_update_features(dev); + if (features == dev->features) + return; dev_warn(&card->gdev->dev, "Device recovery failed to restore all offload features\n"); - dev->features = recover; - return -EIO; } EXPORT_SYMBOL_GPL(qeth_recover_features); @@ -6485,8 +6482,7 @@ netdev_features_t qeth_fix_features(struct net_device *dev, /* if the card isn't up, remove features that require hw changes */ if (card->state == CARD_STATE_DOWN || card->state == CARD_STATE_RECOVER) - features = features & ~(NETIF_F_IP_CSUM | NETIF_F_RXCSUM | - NETIF_F_TSO); + features &= ~QETH_HW_FEATURES; QETH_DBF_HEX(SETUP, 2, &features, sizeof(features)); return features; } -- cgit v1.2.3 From ed2e93efc3b8d34ba36b0f7b581f3828916a1da7 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:15 +0200 Subject: s390/qeth: remove duplicated device matching With commit "s390/ccwgroup: tie a ccwgroup driver to its ccw driver", the ccwgroup core now ensures that a qeth group device only consists of ccw devices which are supported by qeth. Therefore remove qeth's internal device matching, and use .driver_info to determine the card type. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 40 ++++++++------------------------------- 1 file changed, 8 insertions(+), 32 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index e10e5b8d476c..735b03cae727 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -52,7 +52,6 @@ EXPORT_SYMBOL_GPL(qeth_core_header_cache); static struct kmem_cache *qeth_qdio_outbuf_cache; static struct device *qeth_core_root_dev; -static unsigned int known_devices[][6] = QETH_MODELLIST_ARRAY; static struct lock_class_key qdio_out_skb_queue_key; static struct mutex qeth_mod_mutex; @@ -1386,6 +1385,7 @@ static void qeth_init_qdio_info(struct qeth_card *card) QETH_DBF_TEXT(SETUP, 4, "intqdinf"); atomic_set(&card->qdio.state, QETH_QDIO_UNINITIALIZED); /* inbound */ + card->qdio.no_in_queues = 1; card->qdio.in_buf_size = QETH_IN_BUF_SIZE_DEFAULT; if (card->info.type == QETH_CARD_TYPE_IQD) card->qdio.init_pool.buf_count = QETH_IN_BUF_COUNT_HSDEFAULT; @@ -1519,34 +1519,17 @@ out: return NULL; } -static int qeth_determine_card_type(struct qeth_card *card) +static void qeth_determine_card_type(struct qeth_card *card) { - int i = 0; - QETH_DBF_TEXT(SETUP, 2, "detcdtyp"); card->qdio.do_prio_queueing = QETH_PRIOQ_DEFAULT; card->qdio.default_out_queue = QETH_DEFAULT_QUEUE; - while (known_devices[i][QETH_DEV_MODEL_IND]) { - if ((CARD_RDEV(card)->id.dev_type == - known_devices[i][QETH_DEV_TYPE_IND]) && - (CARD_RDEV(card)->id.dev_model == - known_devices[i][QETH_DEV_MODEL_IND])) { - card->info.type = known_devices[i][QETH_DEV_MODEL_IND]; - card->qdio.no_out_queues = - known_devices[i][QETH_QUEUE_NO_IND]; - card->qdio.no_in_queues = 1; - card->info.is_multicast_different = - known_devices[i][QETH_MULTICAST_IND]; - qeth_update_from_chp_desc(card); - return 0; - } - i++; - } - card->info.type = QETH_CARD_TYPE_UNKNOWN; - dev_err(&card->gdev->dev, "The adapter hardware is of an " - "unknown type\n"); - return -ENOENT; + card->info.type = CARD_RDEV(card)->id.driver_info; + card->qdio.no_out_queues = QETH_MAX_QUEUES; + if (card->info.type == QETH_CARD_TYPE_IQD) + card->info.is_multicast_different = 0x0103; + qeth_update_from_chp_desc(card); } static int qeth_clear_channel(struct qeth_channel *channel) @@ -2233,8 +2216,6 @@ static int qeth_cm_setup(struct qeth_card *card) static int qeth_get_initial_mtu_for_card(struct qeth_card *card) { switch (card->info.type) { - case QETH_CARD_TYPE_UNKNOWN: - return 1500; case QETH_CARD_TYPE_IQD: return card->info.max_mtu; case QETH_CARD_TYPE_OSD: @@ -2279,7 +2260,6 @@ static int qeth_mtu_is_valid(struct qeth_card *card, int mtu) return ((mtu >= 576) && (mtu <= card->info.max_mtu)); case QETH_CARD_TYPE_OSN: - case QETH_CARD_TYPE_UNKNOWN: default: return 1; } @@ -5724,11 +5704,7 @@ static int qeth_core_probe_device(struct ccwgroup_device *gdev) gdev->cdev[1]->handler = qeth_irq; gdev->cdev[2]->handler = qeth_irq; - rc = qeth_determine_card_type(card); - if (rc) { - QETH_DBF_TEXT_(SETUP, 2, "3err%d", rc); - goto err_card; - } + qeth_determine_card_type(card); rc = qeth_setup_card(card); if (rc) { QETH_DBF_TEXT_(SETUP, 2, "2err%d", rc); -- cgit v1.2.3 From 6e6f472d92bd4ccd88a9a12e55b484ab417c168c Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:18 +0200 Subject: s390/qeth: clean up initial MTU determination 1. Drop the support for Token Ring, 2. use the ETH_DATA_LEN macro for the default L2 MTU, 3. handle OSM via the default case (as OSM is L2-only), and 4. document why the L3 MTU is reduced. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 735b03cae727..acf16fa75c63 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -2219,18 +2219,12 @@ static int qeth_get_initial_mtu_for_card(struct qeth_card *card) case QETH_CARD_TYPE_IQD: return card->info.max_mtu; case QETH_CARD_TYPE_OSD: - switch (card->info.link_type) { - case QETH_LINK_TYPE_HSTR: - case QETH_LINK_TYPE_LANE_TR: - return 2000; - default: - return card->options.layer2 ? 1500 : 1492; - } - case QETH_CARD_TYPE_OSM: case QETH_CARD_TYPE_OSX: - return card->options.layer2 ? 1500 : 1492; + if (!card->options.layer2) + return ETH_DATA_LEN - 8; /* L3: allow for LLC + SNAP */ + /* fall through */ default: - return 1500; + return ETH_DATA_LEN; } } -- cgit v1.2.3 From b6f72f9698ab8bd79cd0b72a8d9f25dacd786563 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:21 +0200 Subject: s390/qeth: clean up page frag creation Replace the open-coded skb_add_rx_frag(), and use a fall-through to remove some duplicated code. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 31 +++++++++++-------------------- 1 file changed, 11 insertions(+), 20 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index acf16fa75c63..1cf4e066955f 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -5172,10 +5172,11 @@ EXPORT_SYMBOL_GPL(qeth_core_hardsetup_card); static int qeth_create_skb_frag(struct qeth_qdio_buffer *qethbuffer, struct qdio_buffer_element *element, - struct sk_buff **pskb, int offset, int *pfrag, - int data_len) + struct sk_buff **pskb, int offset, int data_len) { struct page *page = virt_to_page(element->addr); + unsigned int next_frag; + if (*pskb == NULL) { if (qethbuffer->rx_skb) { /* only if qeth_card.options.cq == QETH_CQ_ENABLED */ @@ -5190,28 +5191,19 @@ static int qeth_create_skb_frag(struct qeth_qdio_buffer *qethbuffer, skb_reserve(*pskb, ETH_HLEN); if (data_len <= QETH_RX_PULL_LEN) { skb_put_data(*pskb, element->addr + offset, data_len); + return 0; } else { - get_page(page); skb_put_data(*pskb, element->addr + offset, QETH_RX_PULL_LEN); - skb_fill_page_desc(*pskb, *pfrag, page, - offset + QETH_RX_PULL_LEN, - data_len - QETH_RX_PULL_LEN); - (*pskb)->data_len += data_len - QETH_RX_PULL_LEN; - (*pskb)->len += data_len - QETH_RX_PULL_LEN; - (*pskb)->truesize += data_len - QETH_RX_PULL_LEN; - (*pfrag)++; + data_len -= QETH_RX_PULL_LEN; + offset += QETH_RX_PULL_LEN; + /* fall through to add page frag for remaining data */ } - } else { - get_page(page); - skb_fill_page_desc(*pskb, *pfrag, page, offset, data_len); - (*pskb)->data_len += data_len; - (*pskb)->len += data_len; - (*pskb)->truesize += data_len; - (*pfrag)++; } - + next_frag = skb_shinfo(*pskb)->nr_frags; + get_page(page); + skb_add_rx_frag(*pskb, next_frag, page, offset, data_len, data_len); return 0; } @@ -5234,7 +5226,6 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, int data_len; int headroom = 0; int use_rx_sg = 0; - int frag = 0; /* qeth_hdr must not cross element boundaries */ if (element->length < offset + sizeof(struct qeth_hdr)) { @@ -5286,7 +5277,7 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, if (data_len) { if (use_rx_sg) { if (qeth_create_skb_frag(qethbuffer, element, - &skb, offset, &frag, data_len)) + &skb, offset, data_len)) goto no_mem; } else { skb_put_data(skb, data_ptr, data_len); -- cgit v1.2.3 From 8d68af6af6b4f76eac4f9abf584b4ea356f638c0 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:22 +0200 Subject: s390/qeth: consolidate skb allocation Move the allocation of SG skbs into the main path. This allows for a little code sharing, and handling ENOMEM from within one place. As side effect, L2 SG skbs now get the proper amount of additional headroom (read: zero) instead of the hard-coded ETH_HLEN. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 71 +++++++++++++++++---------------------- 1 file changed, 31 insertions(+), 40 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 1cf4e066955f..23b439fb5f2c 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -5170,41 +5170,27 @@ out: } EXPORT_SYMBOL_GPL(qeth_core_hardsetup_card); -static int qeth_create_skb_frag(struct qeth_qdio_buffer *qethbuffer, - struct qdio_buffer_element *element, - struct sk_buff **pskb, int offset, int data_len) +static void qeth_create_skb_frag(struct qdio_buffer_element *element, + struct sk_buff *skb, int offset, int data_len) { struct page *page = virt_to_page(element->addr); unsigned int next_frag; - if (*pskb == NULL) { - if (qethbuffer->rx_skb) { - /* only if qeth_card.options.cq == QETH_CQ_ENABLED */ - *pskb = qethbuffer->rx_skb; - qethbuffer->rx_skb = NULL; - } else { - *pskb = dev_alloc_skb(QETH_RX_PULL_LEN + ETH_HLEN); - if (!(*pskb)) - return -ENOMEM; - } + /* first fill the linear space */ + if (!skb->len) { + unsigned int linear = min(data_len, skb_tailroom(skb)); - skb_reserve(*pskb, ETH_HLEN); - if (data_len <= QETH_RX_PULL_LEN) { - skb_put_data(*pskb, element->addr + offset, data_len); - return 0; - } else { - skb_put_data(*pskb, element->addr + offset, - QETH_RX_PULL_LEN); - data_len -= QETH_RX_PULL_LEN; - offset += QETH_RX_PULL_LEN; - /* fall through to add page frag for remaining data */ - } + skb_put_data(skb, element->addr + offset, linear); + data_len -= linear; + if (!data_len) + return; + offset += linear; + /* fall through to add page frag for remaining data */ } - next_frag = skb_shinfo(*pskb)->nr_frags; + next_frag = skb_shinfo(skb)->nr_frags; get_page(page); - skb_add_rx_frag(*pskb, next_frag, page, offset, data_len, data_len); - return 0; + skb_add_rx_frag(skb, next_frag, page, offset, data_len, data_len); } static inline int qeth_is_last_sbale(struct qdio_buffer_element *sbale) @@ -5220,7 +5206,7 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, struct qdio_buffer_element *element = *__element; struct qdio_buffer *buffer = qethbuffer->buffer; int offset = *__offset; - struct sk_buff *skb = NULL; + struct sk_buff *skb; int skb_len = 0; void *data_ptr; int data_len; @@ -5261,27 +5247,32 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, if (((skb_len >= card->options.rx_sg_cb) && (!(card->info.type == QETH_CARD_TYPE_OSN)) && (!atomic_read(&card->force_alloc_skb))) || - (card->options.cq == QETH_CQ_ENABLED)) { + (card->options.cq == QETH_CQ_ENABLED)) use_rx_sg = 1; + + if (use_rx_sg && qethbuffer->rx_skb) { + /* QETH_CQ_ENABLED only: */ + skb = qethbuffer->rx_skb; + qethbuffer->rx_skb = NULL; } else { - skb = dev_alloc_skb(skb_len + headroom); - if (!skb) - goto no_mem; - if (headroom) - skb_reserve(skb, headroom); + unsigned int linear = (use_rx_sg) ? QETH_RX_PULL_LEN : skb_len; + + skb = dev_alloc_skb(linear + headroom); } + if (!skb) + goto no_mem; + if (headroom) + skb_reserve(skb, headroom); data_ptr = element->addr + offset; while (skb_len) { data_len = min(skb_len, (int)(element->length - offset)); if (data_len) { - if (use_rx_sg) { - if (qeth_create_skb_frag(qethbuffer, element, - &skb, offset, data_len)) - goto no_mem; - } else { + if (use_rx_sg) + qeth_create_skb_frag(element, skb, offset, + data_len); + else skb_put_data(skb, data_ptr, data_len); - } } skb_len -= data_len; if (skb_len) { -- cgit v1.2.3 From 864c17c3d83be6a1f6a2888566e93e114986abca Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:23 +0200 Subject: s390/qeth: try harder to get packets from RX buffer Current code bails out when two subsequent buffer elements hold insufficient data to contain a qeth_hdr packet descriptor. This seems reasonable, but it would be legal for quirky hardware to leave a few elements empty and then present packets in a subsequent element. These packets would currently be dropped. So make sure to check all buffer elements, until we hit the LAST_ENTRY indication. Signed-off-by: Julian Wiedmann Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 23b439fb5f2c..8855bc8534d2 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -5214,13 +5214,11 @@ struct sk_buff *qeth_core_get_next_skb(struct qeth_card *card, int use_rx_sg = 0; /* qeth_hdr must not cross element boundaries */ - if (element->length < offset + sizeof(struct qeth_hdr)) { + while (element->length < offset + sizeof(struct qeth_hdr)) { if (qeth_is_last_sbale(element)) return NULL; element++; offset = 0; - if (element->length < sizeof(struct qeth_hdr)) - return NULL; } *hdr = element->addr + offset; -- cgit v1.2.3 From 978759e8266d6f778fd7f8ae0d4a5e2ddb0558f7 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:24 +0200 Subject: s390/qeth: support GRO flush timer Switch to napi_complete_done(), and thus enable delayed GRO flushing. The timeout is configured via /sys/class/net//gro_flush_timeout. Default timeout is 0, so no change in behaviour. Signed-off-by: Julian Wiedmann Reviewed-by: Eric Dumazet Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 8855bc8534d2..98b7e1ce0dd1 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -5370,7 +5370,7 @@ int qeth_poll(struct napi_struct *napi, int budget) } } - napi_complete(napi); + napi_complete_done(napi, work_done); if (qdio_start_irq(card->data.ccwdev, 0)) napi_schedule(&card->napi); out: -- cgit v1.2.3 From 52c44d2975433fab645d29f1b5e6c0c7e77dd342 Mon Sep 17 00:00:00 2001 From: Julian Wiedmann Date: Wed, 18 Oct 2017 17:40:25 +0200 Subject: s390/qeth: don't dump control cmd twice A few lines down, qeth_prepare_control_data() makes further changes to the control cmd buffer, and then also writes a trace entry for it. So the first entry just pollutes the trace file with intermediate data, drop it. Signed-off-by: Julian Wiedmann Reviewed-by: Ursula Braun Signed-off-by: David S. Miller --- drivers/s390/net/qeth_core_main.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers/s390/net/qeth_core_main.c') diff --git a/drivers/s390/net/qeth_core_main.c b/drivers/s390/net/qeth_core_main.c index 98b7e1ce0dd1..457a4b4e8212 100644 --- a/drivers/s390/net/qeth_core_main.c +++ b/drivers/s390/net/qeth_core_main.c @@ -2073,7 +2073,6 @@ int qeth_send_control_data(struct qeth_card *card, int len, spin_lock_irqsave(&card->lock, flags); list_add_tail(&reply->list, &card->cmd_waiter_list); spin_unlock_irqrestore(&card->lock, flags); - QETH_DBF_HEX(CTRL, 2, iob->data, QETH_DBF_CTRL_LEN); while (atomic_cmpxchg(&card->write.irq_pending, 0, 1)) ; qeth_prepare_control_data(card, len, iob); -- cgit v1.2.3