From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f65.google.com (mail-pa0-f65.google.com [209.85.220.65]) by dpdk.org (Postfix) with ESMTP id D59BDADEB for ; Tue, 21 Jun 2016 10:37:58 +0200 (CEST) Received: by mail-pa0-f65.google.com with SMTP id ts6so885103pac.0 for ; Tue, 21 Jun 2016 01:37:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=user-agent:from:to:subject:date:message-id:mime-version; bh=hK6GeiOrCilW59hSXyLfz0Lx93qq87AUErg99NjBr/U=; b=v+E28QwFpp6LaHQxB5ZgGP4v9jc22ZDcGvTqpBGhiE44nDpTRDFvhxihqZAzn7fszB qYVk3OHhi5Kbhg6xqa7avbP5JeaB8Q0LFUZrJghVSE1/FyBRz314GxHf3w+EbPczalKO SBPpKxtGUax/zUkdR1/39SMV7blRsj6L5ZnTLc8N8gwJ+kxUS81W4p00xm00xNxZpzRw bIX8B+ebP5Z5mjlHmoG8QJhWOpJvubJ9DzHEoGsQIwx1X/QnWH9QCOpcruk1DuDyIF6+ 9c1tcuUD44LuVVA2hO3RjrLqNI969npg+yxgWnEIw+McLn3B34phL56QAHE2ez9cn67M 8JNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:user-agent:from:to:subject:date:message-id :mime-version; bh=hK6GeiOrCilW59hSXyLfz0Lx93qq87AUErg99NjBr/U=; b=Br5M5et0U5nWPpEuBvn8ovhVRCUeIoZ417f/Y52UR/PZFkZ5KRHT5WxnNVswf32LFj cNpY9UD6F6jLbcWWRp8p69weJdsO4Z8JEFFyJLNMJuRHr7W9GgGe3m9RMv5k6VWtFfl9 qUXZhrVPDF1RRwatdOfFEVDvk18zuJpoY4zqr6jJ85Chpb8ehNcEag9Lrh76ehdlzIRG cx9CmK4wI9lUcJ65inyt9ofTB1i633JkVPmL4CWfsXkrLEx8yw8RvYb2A20/wft9hwU4 +e6VyJbu1a4yG9k0nhIBxHu6U61GHtARUx1jedlAb/Vb5OROFLONMmA3uY5HYXR27mVl 8h5g== X-Gm-Message-State: ALyK8tIuKJWpCPKJZCaCQNwLv5wBRXseIH3qeMxGx/AtcCy9e8vxJiRZS0sF0+71Q+SX/w== X-Received: by 10.66.84.164 with SMTP id a4mr26611291paz.90.1466498276862; Tue, 21 Jun 2016 01:37:56 -0700 (PDT) Received: from localhost ([114.143.135.2]) by smtp.gmail.com with ESMTPSA id 4sm83815931pav.33.2016.06.21.01.37.55 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 21 Jun 2016 01:37:56 -0700 (PDT) User-agent: mu4e 0.9.16; emacs 24.5.1 From: Anupam Kapoor To: dev@dpdk.org Date: Tue, 21 Jun 2016 14:07:53 +0530 Message-ID: <87eg7ros2m.fsf@fatcat.parallelwireless> MIME-Version: 1.0 Content-Type: text/plain Subject: [dpdk-dev] [PATCH] kni : fix build errors for gcc --version >= 6.1 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jun 2016 08:37:59 -0000 This commit fixes build errors triggered due misleading indentation. Fixes: 366113dbfb696 (e1000: suppress misleading indentation warning) Signed-off-by: Anupam Kapoor --- lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c | 12 ++++++++---- lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c | 6 +++--- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c b/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c index df224702ed7d..26352da15101 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c +++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/e1000_phy.c @@ -3299,13 +3299,15 @@ s32 e1000_read_phy_reg_mphy(struct e1000_hw *hw, u32 address, u32 *data) return -E1000_ERR_PHY; *data = E1000_READ_REG(hw, E1000_MPHY_DATA); - /* Disable access to mPHY if it was originally disabled */ - if (locked) + /* Disable access to mPHY if it was originally enabled */ + if (locked) { ready = e1000_is_mphy_ready(hw); if (!ready) return -E1000_ERR_PHY; + E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL, E1000_MPHY_DIS_ACCESS); + } return E1000_SUCCESS; } @@ -3364,13 +3366,15 @@ s32 e1000_write_phy_reg_mphy(struct e1000_hw *hw, u32 address, u32 data, return -E1000_ERR_PHY; E1000_WRITE_REG(hw, E1000_MPHY_DATA, data); - /* Disable access to mPHY if it was originally disabled */ - if (locked) + /* Disable access to mPHY if it was originally enabled */ + if (locked) { ready = e1000_is_mphy_ready(hw); if (!ready) return -E1000_ERR_PHY; + E1000_WRITE_REG(hw, E1000_MPHY_ADDR_CTRL, E1000_MPHY_DIS_ACCESS); + } return E1000_SUCCESS; } diff --git a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c index 017dfe16c73f..dc2a4fb61c25 100644 --- a/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c +++ b/lib/librte_eal/linuxapp/kni/ethtool/ixgbe/ixgbe_82599.c @@ -870,9 +870,9 @@ s32 ixgbe_setup_mac_link_82599(struct ixgbe_hw *hw, if (speed & IXGBE_LINK_SPEED_10GB_FULL) if (orig_autoc & IXGBE_AUTOC_KX4_SUPP) autoc |= IXGBE_AUTOC_KX4_SUPP; - if ((orig_autoc & IXGBE_AUTOC_KR_SUPP) && - (hw->phy.smart_speed_active == false)) - autoc |= IXGBE_AUTOC_KR_SUPP; + if ((orig_autoc & IXGBE_AUTOC_KR_SUPP) && + (hw->phy.smart_speed_active == false)) + autoc |= IXGBE_AUTOC_KR_SUPP; if (speed & IXGBE_LINK_SPEED_1GB_FULL) autoc |= IXGBE_AUTOC_KX_SUPP; } else if ((pma_pmd_1g == IXGBE_AUTOC_1G_SFI) && -- 2.9.0