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 D020AA00C4 for ; Thu, 6 Oct 2022 11:05:52 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C54A342BD3; Thu, 6 Oct 2022 11:05:52 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id 1374E42BC2 for ; Thu, 6 Oct 2022 11:05:50 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1665047150; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qsR+2QCIxhVwvlyEYqK4hurm2l/+iI62MhnGTBRaPvw=; b=D2uAUKoN3U0yKKzuBJZZaJRnYEolBYu+A8SBz+TUQvPeDOVi0hOz5GZz/0wjZGtQsHpetE WICWyYnGehkmw0iouxierVQk+q7TEb4fo8ENOBbjurvqdeh2mKf41Jq/owt39Drx/i9RFk sAY1KjiAzhBrIwARGoM8IBTrJVirkEY= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-42-FLffBOibOwyewUDqmQUWqg-1; Thu, 06 Oct 2022 05:05:45 -0400 X-MC-Unique: FLffBOibOwyewUDqmQUWqg-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 E4D022932496; Thu, 6 Oct 2022 09:05:44 +0000 (UTC) Received: from [10.39.208.19] (unknown [10.39.208.19]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B9C22C15BA4; Thu, 6 Oct 2022 09:05:42 +0000 (UTC) Message-ID: <8076bfb2-421c-8003-9897-a0865edce448@redhat.com> Date: Thu, 6 Oct 2022 11:05:41 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.1 Subject: Re: [EXT] Re: [PATCH v3] vhost: fix build issues with GCC 12 To: Amit Prakash Shukla , Stephen Hemminger Cc: "dev@dpdk.org" , "cheng1.jiang@intel.com" , "chenbo.xia@intel.com" , "zhoumin@loongson.cn" , "david.marchand@redhat.com" , "thomas@monjalon.net" , "stable@dpdk.org" References: <20221005151159.72366-1-maxime.coquelin@redhat.com> <20221005203524.89336-1-maxime.coquelin@redhat.com> <20221005170143.6235a939@hermes.local> <3ef7068d-5e05-4a4d-653c-43b1b31dd869@redhat.com> From: Maxime Coquelin In-Reply-To: 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: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On 10/6/22 10:22, Amit Prakash Shukla wrote: > Hi Maxime, > > Compiled this patch with aarch64-linux-gnu-gcc (GCC) 12.2.0 and it compiles fine. Thanks Amit! > Thanks, > Amit Shukla > >> -----Original Message----- >> From: Maxime Coquelin >> Sent: Thursday, October 6, 2022 1:21 PM >> To: Stephen Hemminger >> Cc: dev@dpdk.org; cheng1.jiang@intel.com; chenbo.xia@intel.com; >> zhoumin@loongson.cn; david.marchand@redhat.com; >> thomas@monjalon.net; stable@dpdk.org >> Subject: [EXT] Re: [PATCH v3] vhost: fix build issues with GCC 12 >> >> External Email >> >> ---------------------------------------------------------------------- >> Hi Stephen, >> >> On 10/6/22 02:01, Stephen Hemminger wrote: >>> On Wed, 5 Oct 2022 22:35:24 +0200 >>> Maxime Coquelin wrote: >>> >>>> In practice, it would never happen since 'pkt->pkt_len' is unlikely >>>> to be close to UINT32_MAX, but let's just change 'size' to uint64_t >>>> to make the compiler happy without having to add runtime checks. >>> >>> >>> Would the standard typedef size_t work since that is what sizeof() returns. >>> >> >> I'm not sure it would not create issues on 32 bits architectures build given >> size_t is 32bits in this case if I'm not mistaken, as it adds something to a u32, >> so it could wrap to 0. >