From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B576BA0093 for ; Thu, 28 May 2020 19:06:08 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 638E51D8EF; Thu, 28 May 2020 19:06:08 +0200 (CEST) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id 1774F1D9BB for ; Thu, 28 May 2020 19:06:06 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590685566; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=MunCUnTWdkLph+4Fs3DwyAqTZ2jEeBwFZ+kXijr4UtQ=; b=T3JFazY6wqMzBFXbxvWcwuD+c7HMeWop5YHCBzXsPtii81BrsmJKW56BRE5uhp68wTY6hz h3Mn7gkO8n7LuUQ5eA42NWCGgc35xeHQjUaP8C3LATa3jjJiRH8gpI8YTdAbFgeFqekXJD Gc0Q9NW3o/MAytk57P6mmU8eVS6pTsA= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-325-rngm-9KyOaCCWMdi7Tcp3Q-1; Thu, 28 May 2020 13:06:02 -0400 X-MC-Unique: rngm-9KyOaCCWMdi7Tcp3Q-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 3860110AEC41; Thu, 28 May 2020 17:05:18 +0000 (UTC) Received: from rh.redhat.com (unknown [10.33.36.235]) by smtp.corp.redhat.com (Postfix) with ESMTP id 53A0D5D9CD; Thu, 28 May 2020 17:05:17 +0000 (UTC) From: Kevin Traynor To: stable@dpdk.org, ferruh.yigit@intel.com Cc: Kevin Traynor Date: Thu, 28 May 2020 18:05:10 +0100 Message-Id: <20200528170510.9937-1-ktraynor@redhat.com> In-Reply-To: <20200528165751.9367-1-ktraynor@redhat.com> References: <20200528165751.9367-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] [PATCH 18.11 v2] kni: fix ethtool build with kernel 5.6 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" With the following Linux commit a new parameter 'txqueue' has been added to 'ndo_tx_timeout' ndo: commit 0290bd291cc0 ("netdev: pass the stuck queue to the timeout handler") A check on Linux kernel version is already done in commit 6ff755242707 ("kni: fix build with Linux 5.6") and HAVE_TX_TIMEOUT_TXQUEUE is used to indicate if the extra parameter is required. Update igb ethtool to use the define. Signed-off-by: Kevin Traynor --- v2: add the word 'commit' on the same line as the referenced commits because checkpatch says I should --- kernel/linux/kni/ethtool/igb/igb_main.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/kernel/linux/kni/ethtool/igb/igb_main.c b/kernel/linux/kni/ethtool/igb/igb_main.c index cb1b536775..5a07d007a2 100644 --- a/kernel/linux/kni/ethtool/igb/igb_main.c +++ b/kernel/linux/kni/ethtool/igb/igb_main.c @@ -37,4 +37,5 @@ #include +#include "compat.h" #include "igb.h" #include "igb_vmdq.h" @@ -155,5 +156,9 @@ static bool igb_clean_tx_irq(struct igb_q_vector *); static bool igb_clean_rx_irq(struct igb_q_vector *, int); static int igb_ioctl(struct net_device *, struct ifreq *, int cmd); +#ifdef HAVE_TX_TIMEOUT_TXQUEUE +static void igb_tx_timeout(struct net_device *, unsigned int); +#else static void igb_tx_timeout(struct net_device *); +#endif /* HAVE_TX_TIMEOUT_TXQUEUE */ static void igb_reset_task(struct work_struct *); #ifdef HAVE_VLAN_RX_REGISTER @@ -5624,5 +5629,9 @@ static netdev_tx_t igb_xmit_frame(struct sk_buff *skb, * @netdev: network interface device structure **/ +#ifdef HAVE_TX_TIMEOUT_TXQUEUE +static void igb_tx_timeout(struct net_device *netdev, unsigned int txqueue) +#else static void igb_tx_timeout(struct net_device *netdev) +#endif { struct igb_adapter *adapter = netdev_priv(netdev); -- 2.21.3