From patchwork Fri Apr 7 17:44:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 23336 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id BB3A7CF80; Fri, 7 Apr 2017 19:45:09 +0200 (CEST) Received: from mail-it0-f48.google.com (mail-it0-f48.google.com [209.85.214.48]) by dpdk.org (Postfix) with ESMTP id B0EB96A71 for ; Fri, 7 Apr 2017 19:45:04 +0200 (CEST) Received: by mail-it0-f48.google.com with SMTP id y18so123691990itc.0 for ; Fri, 07 Apr 2017 10:45:04 -0700 (PDT) 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=Y2iXYSS3LwXlrbcTWqvoUhOo1c0cSo8wtY15CUkZ8p8=; b=N1umJmJU+33565+3DX0vRIxNn1WiMK1VgL1vnK72KgfhJ8S8dRQvKP3uUz/dBmDJw1 yjmP3U3M29h3AonKDyhrkPBnfZ+7JUr2cZYfSbMpr/VdOV6+i2YezumW/Pc2QjkhYM5v XUGQJy54W20eAS9UL0N2kp8nsgpF1ic0Lk9ERnTyAnXdaIDJReKaZmtNbl5bMIyicdcV zrIxFZRBN/3Btbn6LvghBTi4nlqibyAwf2HcnCJ/ZUuiZGhGwlQdUlnwzxcZ14mGkZWZ nWPjv0pgme07uwHKHGwva3ZrGgsqD+Ttr9ttlU5u0G6DT2Kwkp7KBmW8oXywqJjYUaUI 79Jw== 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=Y2iXYSS3LwXlrbcTWqvoUhOo1c0cSo8wtY15CUkZ8p8=; b=CC0q3MUqfjmGBLth7lclk4GyuHrSjf8KCvI0YjfAv5pSVDXYWtHMfqi/j/CjBBpRRa C8L27jz6UnwabPgWY9SCsWLC9WKn8kNP7LIvP0OjtT+bfiU4Zoxben+FbpSwv+7JNUhW uZ0yLtREhchwey0rup2echIpRDHLJAPRbq+caONdGTJuDA4bwuDO68ymu2I8EdFdDTPH YTTHbhusBIQhwGs6mLssfKkYj1TIjyTi5pf8mCHTD/Ln/vaj+wiVwvoo8oqcExqz1Xvl +3NB4tQscP7TjQ9oT/B08DdY8dWbNy1ffh1RIALrmu75nQ11QUEHs1t+RrInK6Dr7xHX G/yA== X-Gm-Message-State: AN3rC/6XkAVjDmofBUz2B5NYUEBrEdeqKu3PGu+9B6cpnjJrqN6CFynt oUXR6B8LHRwBiQ== X-Received: by 10.36.138.65 with SMTP id v62mr631921itd.108.1491587103954; Fri, 07 Apr 2017 10:45:03 -0700 (PDT) Received: from plumbers-lap.home.lan ([66.171.166.114]) by smtp.gmail.com with ESMTPSA id s40sm4649675ite.18.2017.04.07.10.45.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 07 Apr 2017 10:45:03 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Stephen Hemminger Date: Fri, 7 Apr 2017 13:44:48 -0400 Message-Id: <20170407174457.4180-3-stephen@networkplumber.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170407174457.4180-1-stephen@networkplumber.org> References: <20170407174457.4180-1-stephen@networkplumber.org> Subject: [dpdk-dev] [PATCH 02/11] kni: remove unnecessary cast of void pointers 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Remove unnecessary casts of void * pointers to a specfic type. Signed-off-by: Stephen Hemminger Acked-by: Ferruh Yigit --- lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c | 2 +- lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c | 8 ++++---- lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c | 4 ++-- lib/librte_eal/linuxapp/kni/kni_misc.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c index d7a987d54..95e262b78 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c @@ -1126,7 +1126,7 @@ static int igb_eeprom_test(struct igb_adapter *adapter, u64 *data) static irqreturn_t igb_test_intr(int irq, void *data) { - struct igb_adapter *adapter = (struct igb_adapter *) data; + struct igb_adapter *adapter = data; struct e1000_hw *hw = &adapter->hw; adapter->test_icr |= E1000_READ_REG(hw, E1000_ICR); diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c index f4dca5a38..c0d52db33 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_main.c @@ -1629,7 +1629,7 @@ static void igb_check_swap_media(struct igb_adapter *adapter) */ static int igb_get_i2c_data(void *data) { - struct igb_adapter *adapter = (struct igb_adapter *)data; + struct igb_adapter *adapter = data; struct e1000_hw *hw = &adapter->hw; s32 i2cctl = E1000_READ_REG(hw, E1000_I2CPARAMS); @@ -1644,7 +1644,7 @@ static int igb_get_i2c_data(void *data) */ static void igb_set_i2c_data(void *data, int state) { - struct igb_adapter *adapter = (struct igb_adapter *)data; + struct igb_adapter *adapter = data; struct e1000_hw *hw = &adapter->hw; s32 i2cctl = E1000_READ_REG(hw, E1000_I2CPARAMS); @@ -1669,7 +1669,7 @@ static void igb_set_i2c_data(void *data, int state) */ static void igb_set_i2c_clk(void *data, int state) { - struct igb_adapter *adapter = (struct igb_adapter *)data; + struct igb_adapter *adapter = data; struct e1000_hw *hw = &adapter->hw; s32 i2cctl = E1000_READ_REG(hw, E1000_I2CPARAMS); @@ -1691,7 +1691,7 @@ static void igb_set_i2c_clk(void *data, int state) */ static int igb_get_i2c_clk(void *data) { - struct igb_adapter *adapter = (struct igb_adapter *)data; + struct igb_adapter *adapter = data; struct e1000_hw *hw = &adapter->hw; s32 i2cctl = E1000_READ_REG(hw, E1000_I2CPARAMS); diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c index bc3cb2f48..cdfcb9596 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c +++ b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_ethtool.c @@ -1462,7 +1462,7 @@ static int ixgbe_eeprom_test(struct ixgbe_adapter *adapter, u64 *data) static irqreturn_t ixgbe_test_intr(int irq, void *data) { - struct net_device *netdev = (struct net_device *) data; + struct net_device *netdev = data; struct ixgbe_adapter *adapter = netdev_priv(netdev); adapter->test_icr |= IXGBE_READ_REG(&adapter->hw, IXGBE_EICR); @@ -2447,7 +2447,7 @@ static int ixgbe_get_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd, break; case ETHTOOL_GRXCLSRLALL: ret = ixgbe_get_ethtool_fdir_all(adapter, cmd, - (u32 *)rule_locs); + rule_locs); break; case ETHTOOL_GRXFH: ret = ixgbe_get_rss_hash_opts(adapter, cmd); diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/lib/librte_eal/linuxapp/kni/kni_misc.c index f1f6bea6f..818f7ce4b 100644 --- a/lib/librte_eal/linuxapp/kni/kni_misc.c +++ b/lib/librte_eal/linuxapp/kni/kni_misc.c @@ -159,7 +159,7 @@ static int kni_thread_multiple(void *param) { int j; - struct kni_dev *dev = (struct kni_dev *)param; + struct kni_dev *dev = param; while (!kthread_should_stop()) { for (j = 0; j < KNI_RX_LOOP_NUM; j++) {