From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl0-f67.google.com (mail-pl0-f67.google.com [209.85.160.67]) by dpdk.org (Postfix) with ESMTP id D6BC91B010 for ; Tue, 2 Jan 2018 21:53:14 +0100 (CET) Received: by mail-pl0-f67.google.com with SMTP id b12so29366389plm.3 for ; Tue, 02 Jan 2018 12:53:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=06HeBKkAqB7HiZirgCzLRztXBP55BcwYiWYkObkJC5I=; b=W1k2651ZNqzttI08LqYJgSiYUgHZQNTFmVLgK0JWcA4IWMvM7Diqa/r/msjm57A4i6 VdKwj+WRS06SqQYqGmCGKGOE0O/XbM6cx+ucp1UvIuPtDN/4vMImxR+oN6qT7uC8p0oJ ffzAv6ehl+/Ko6LTFWLcrW5PjExjFYgZCyz002+OSU2g1mALqT27Pi7bBkeVaruBR4+E wJzekiGPNFKkPRWFdoJUKLvnqwTSCPUubyoPA1kD4GKVgag8/uLhByN8p11ucIbNjOXP Un9xCqOzrqd+WomMNPr9SJ0Sfug3HUFHssmVZ6eEF+pZxOAawgSsCp4ME0bUIodw/M4M rZBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=06HeBKkAqB7HiZirgCzLRztXBP55BcwYiWYkObkJC5I=; b=iWXKrqD4mYXNph6x4r7R++AcIWoz639R7pK1w1RTWOhqtqzaxmCge6GHsPjcKASGBP IH2o0vL7EWDF98bErcdPfgPzvxZ45qFP5oYqDH3ZoFMmhR8O1kTgu1CemJj9UD8yjRbx bw6UxUE9TKWthpQDJTGQ+AQ/aaAC5bu88hiVUILgyfVFGKWwNgevySKn74KkcRKvhFd5 WvwGF2HfpA/+74WF0VFfojVG4ZBoexzjB5BevcA4fIzAs6/XByZzs5slHPTtkJJBMElb VOg5RVyeeOfSkQaWyvkO1wuSgQFfcCznDlK0Pk10HrdRorauvsAxmHUPEzo+7xaRvKPN 2MvA== X-Gm-Message-State: AKGB3mIEBushDVlony6FWxrHuKexsxg8skqnoDLrPKr4ghR7v3DONkCb b8sv2PLn4w8sBX6cslGoqbxCXw== X-Google-Smtp-Source: ACJfBosdAwwC5i8CqwXVlr8v8VJLKHqI2QRcrRAxYACri0d9UpEB9QtYS6WEIef/S5t5Kce/Juzqhg== X-Received: by 10.159.207.135 with SMTP id z7mr46941852plo.307.1514926393906; Tue, 02 Jan 2018 12:53:13 -0800 (PST) Received: from xeon-e3.lan (204-195-18-133.wavecable.com. [204.195.18.133]) by smtp.gmail.com with ESMTPSA id p1sm26223005pgr.53.2018.01.02.12.53.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 Jan 2018 12:53:13 -0800 (PST) From: Stephen Hemminger To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com, yskoh@mellanox.com Cc: dev@dpdk.org, Stephen Hemminger Date: Tue, 2 Jan 2018 12:53:09 -0800 Message-Id: <20180102205310.3586-2-stephen@networkplumber.org> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20180102205310.3586-1-stephen@networkplumber.org> References: <20180102205310.3586-1-stephen@networkplumber.org> Subject: [dpdk-dev] [PATCH 1/2] mlx5: don't pass unused argument to sub-functions X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Jan 2018 20:53:15 -0000 Since wait_to_complete is unused, don't pass it to helper functions. Use the standard RTE macro to indicate this is an unused parameter. Signed-off-by: Stephen Hemminger --- drivers/net/mlx5/mlx5_ethdev.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/drivers/net/mlx5/mlx5_ethdev.c b/drivers/net/mlx5/mlx5_ethdev.c index a3cef6891d03..388507f109f7 100644 --- a/drivers/net/mlx5/mlx5_ethdev.c +++ b/drivers/net/mlx5/mlx5_ethdev.c @@ -755,11 +755,9 @@ mlx5_dev_supported_ptypes_get(struct rte_eth_dev *dev) * * @param dev * Pointer to Ethernet device structure. - * @param wait_to_complete - * Wait for request completion (ignored). */ static int -mlx5_link_update_unlocked_gset(struct rte_eth_dev *dev, int wait_to_complete) +mlx5_link_update_unlocked_gset(struct rte_eth_dev *dev) { struct priv *priv = mlx5_get_priv(dev); struct ethtool_cmd edata = { @@ -771,7 +769,6 @@ mlx5_link_update_unlocked_gset(struct rte_eth_dev *dev, int wait_to_complete) /* priv_lock() is not taken to allow concurrent calls. */ - (void)wait_to_complete; if (priv_ifreq(priv, SIOCGIFFLAGS, &ifr)) { WARN("ioctl(SIOCGIFFLAGS) failed: %s", strerror(errno)); return -1; @@ -821,11 +818,9 @@ mlx5_link_update_unlocked_gset(struct rte_eth_dev *dev, int wait_to_complete) * * @param dev * Pointer to Ethernet device structure. - * @param wait_to_complete - * Wait for request completion (ignored). */ static int -mlx5_link_update_unlocked_gs(struct rte_eth_dev *dev, int wait_to_complete) +mlx5_link_update_unlocked_gs(struct rte_eth_dev *dev) { struct priv *priv = mlx5_get_priv(dev); struct ethtool_link_settings gcmd = { .cmd = ETHTOOL_GLINKSETTINGS }; @@ -833,7 +828,6 @@ mlx5_link_update_unlocked_gs(struct rte_eth_dev *dev, int wait_to_complete) struct rte_eth_link dev_link; uint64_t sc; - (void)wait_to_complete; if (priv_ifreq(priv, SIOCGIFFLAGS, &ifr)) { WARN("ioctl(SIOCGIFFLAGS) failed: %s", strerror(errno)); return -1; @@ -921,7 +915,7 @@ mlx5_link_update_unlocked_gs(struct rte_eth_dev *dev, int wait_to_complete) * Wait for request completion (ignored). */ int -mlx5_link_update(struct rte_eth_dev *dev, int wait_to_complete) +mlx5_link_update(struct rte_eth_dev *dev, int wait_to_complete __rte_unused) { struct utsname utsname; int ver[3]; @@ -930,8 +924,8 @@ mlx5_link_update(struct rte_eth_dev *dev, int wait_to_complete) sscanf(utsname.release, "%d.%d.%d", &ver[0], &ver[1], &ver[2]) != 3 || KERNEL_VERSION(ver[0], ver[1], ver[2]) < KERNEL_VERSION(4, 9, 0)) - return mlx5_link_update_unlocked_gset(dev, wait_to_complete); - return mlx5_link_update_unlocked_gs(dev, wait_to_complete); + return mlx5_link_update_unlocked_gset(dev); + return mlx5_link_update_unlocked_gs(dev); } /** -- 2.15.1