From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f44.google.com (mail-wm0-f44.google.com [74.125.82.44]) by dpdk.org (Postfix) with ESMTP id C3D9E1B681 for ; Fri, 13 Oct 2017 11:31:38 +0200 (CEST) Received: by mail-wm0-f44.google.com with SMTP id q132so20058047wmd.2 for ; Fri, 13 Oct 2017 02:31:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=OUdCMg37nmJVPEFywIsWovz7hOcERjmk/lJedIZOzTg=; b=0THssQvwfXodcyq9dTp+ReynFURHCtSl7ZUJvccFQpwvcGAn6ZlPYmC5TKZWIZs9o6 7VAI1hRYy+OJRu5kIP5vx0azPLkMuCDJdHxy8gFopRZxgwMw0HOjzo6vZhbQFzXiBplG SIphLuEvB/polsW7g+WeUzSUv2ecbX1U/aqFsKamwt2gjFTdAueXSqrVcBbXie39FDNK 901T2TRKNxNzfPYjzmQ+OYp0/HZPBro5Si4PJZy+4/+TWqTb1apNL7JhtMpZV/gJwFlH h3ZBRKZFVhl7oenQWqCQ/JNsgStOSu6/iopRmb3XffcyXBgVoK01jHLAKxh8yOxBojfC QwQA== 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; bh=OUdCMg37nmJVPEFywIsWovz7hOcERjmk/lJedIZOzTg=; b=aha5UULPc4VI985p/55p21TfN7I0zhmCjSMiVV24u/bxEGjV5WNEUsT2nnt/KqtcBU d61Z1p+OpHCESHzslNnaHz1CFb0iaMV6XDCVc3EudyaXsMtZtyYn1WC7t+gvfczWZrE/ MxiLX8k+szj7re/fnSHUSqJ5UQRGFs3JxBUUV+MPgeCqVZgpZ/Jv8FHV4DCrYnhuhDZg E0Br9H3qM0YmyJ6NnP3hkkBGgU9cBIXvd7YiGJVO07ZfBVTesh9Tjv3sxg97bixT6Io6 lRUZPBRtDlGFd7Qk6ZmBJuJcoJpnyRB8ha2PG/gn9SkSMfjMsZdNU3aG4f+01Lept4xj mCJA== X-Gm-Message-State: AMCzsaWsx69GQofguuQJNbsHZT4oERemKJl5IWQcW873IiPPzmeMFC9a k2zLq62YGkA7rEFmsXNUaCCA6IKg X-Google-Smtp-Source: AOwi7QCp9A/zRwkEr/nDpBRQ+bcHV46a00WTuQ9aD2FPIhbZ4+5tc2aoSFpRX2JNwqAZY/f+IqxYig== X-Received: by 10.223.157.141 with SMTP id p13mr905148wre.92.1507887098483; Fri, 13 Oct 2017 02:31:38 -0700 (PDT) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id q3sm366868wrd.78.2017.10.13.02.31.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Oct 2017 02:31:37 -0700 (PDT) From: Adrien Mazarguil To: Ferruh Yigit Cc: dev@dpdk.org, Nelio Laranjeiro Date: Fri, 13 Oct 2017 11:31:05 +0200 Message-Id: <1507887065-28332-1-git-send-email-adrien.mazarguil@6wind.com> X-Mailer: git-send-email 2.1.4 Subject: [dpdk-dev] [PATCH] net/mlx4: fix missing initializers for old GCCs 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: Fri, 13 Oct 2017 09:31:38 -0000 This patch works around compilation issues so far only seen on RHEL 7.2 using GCC 4.8.5: [...]/mlx4_rxq.c: In function `mlx4_rx_queue_setup': [...]/mlx4_rxq.c:473:3: error: missing initializer for field `ipackets' of `struct mlx4_rxq_stats' [-Werror=missing-field-initializers] [...]/mlx4_txq.c: In function `mlx4_tx_queue_setup': [...]/mlx4_txq.c:265:3: error: missing initializer for field `opackets' of `struct mlx4_txq_stats' [-Werror=missing-field-initializers] Fixes: 79770826499b ("net/mlx4: drop live queue reconfiguration support") Signed-off-by: Adrien Mazarguil Acked-by: Nelio Laranjeiro --- drivers/net/mlx4/mlx4_rxq.c | 4 +++- drivers/net/mlx4/mlx4_txq.c | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/net/mlx4/mlx4_rxq.c b/drivers/net/mlx4/mlx4_rxq.c index 7ce5b26..6fa48bc 100644 --- a/drivers/net/mlx4/mlx4_rxq.c +++ b/drivers/net/mlx4/mlx4_rxq.c @@ -469,7 +469,9 @@ mlx4_rx_queue_setup(struct rte_eth_dev *dev, uint16_t idx, uint16_t desc, dev->data->dev_conf.rxmode.hw_ip_checksum), .csum_l2tun = (priv->hw_csum_l2tun && dev->data->dev_conf.rxmode.hw_ip_checksum), - .stats.idx = idx, + .stats = { + .idx = idx, + }, .socket = socket, }; /* Enable scattered packets support for this queue if necessary. */ diff --git a/drivers/net/mlx4/mlx4_txq.c b/drivers/net/mlx4/mlx4_txq.c index 6d3dd78..a9c5bd2 100644 --- a/drivers/net/mlx4/mlx4_txq.c +++ b/drivers/net/mlx4/mlx4_txq.c @@ -261,7 +261,9 @@ mlx4_tx_queue_setup(struct rte_eth_dev *dev, uint16_t idx, uint16_t desc, } *txq = (struct txq){ .priv = priv, - .stats.idx = idx, + .stats = { + .idx = idx, + }, .socket = socket, .elts_n = desc, .elts = elts, -- 2.1.4