From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 783A342DC2; Mon, 3 Jul 2023 10:29:16 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EC57840ED5; Mon, 3 Jul 2023 10:29:15 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 9781D40156 for ; Mon, 3 Jul 2023 10:29:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1688372953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vtLv6lRj6jxI+mIEwrHnCD1CiDZFJtv9iNQJtTbgGtU=; b=CwGQbpg9goUyxIwEaPzNtnHJ6HxsOwD9750YLy/y9iytkvcfuJSqUlsVCXCe8br8tQ4/SH XcJ8o3a8JMuzURvypPzmD0QL3uXu5jm/qt6OY+Yu9378KOJhlks0VGIHyhxP27c9BPqP0K t6pgXavbFgXytfluzMVtCb+81tTBo+U= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-433-roaGZj1lNcC5wgUHlshviQ-1; Mon, 03 Jul 2023 04:29:09 -0400 X-MC-Unique: roaGZj1lNcC5wgUHlshviQ-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 9306B835170; Mon, 3 Jul 2023 08:29:09 +0000 (UTC) Received: from [10.39.208.21] (unknown [10.39.208.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id ADF56C00049; Mon, 3 Jul 2023 08:29:07 +0000 (UTC) Message-ID: <1bf23aa3-2b11-9a22-0116-6e2ed93f471b@redhat.com> Date: Mon, 3 Jul 2023 10:29:05 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH] vhost: fix build with gcc 4.8 To: Ali Alnubani , dev@dpdk.org References: <20230703082153.504569-1-alialnu@nvidia.com> From: Maxime Coquelin In-Reply-To: <20230703082153.504569-1-alialnu@nvidia.com> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Hi Ali, On 7/3/23 10:21, Ali Alnubani wrote: > Adds braces around initializer to resolve the following > false-positive build error with gcc 4.8.5 on CentOS: > lib/vhost/vduse.c:441:9: error: missing braces around initializer > [-Werror=missing-braces] > > Fixes: 653327e191f0 ("vhost: add multiqueue support to VDUSE") > Cc: maxime.coquelin@redhat.com > > Signed-off-by: Ali Alnubani > --- > lib/vhost/vduse.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/vhost/vduse.c b/lib/vhost/vduse.c > index a509daf80c..aa5f1f564d 100644 > --- a/lib/vhost/vduse.c > +++ b/lib/vhost/vduse.c > @@ -438,7 +438,7 @@ vduse_device_create(const char *path) > pthread_t fdset_tid; > uint32_t i, max_queue_pairs, total_queues; > struct virtio_net *dev; > - struct virtio_net_config vnet_config = { 0 }; > + struct virtio_net_config vnet_config = {{ 0 }}; > uint64_t ver = VHOST_VDUSE_API_VERSION; > uint64_t features = VDUSE_NET_SUPPORTED_FEATURES; > struct vduse_dev_config *dev_config = NULL; Reviewed-by: Maxime Coquelin This is not going to introduce any functional change so this is fine, but the DPDK documentation indicates the minimum requirement is GCC 4.9[0]: " General development tools including a supported C compiler such as gcc (version 4.9+) or clang (version 3.4+), and pkg-config or pkgconf to be used when building end-user binaries against DPDK. " Thanks, Maxime [0]: http://doc.dpdk.org/guides/linux_gsg/sys_reqs.html#compilation-of-the-dpdk