From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id C0BF78D86 for ; Mon, 20 Jun 2016 13:29:12 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP; 20 Jun 2016 04:29:11 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,498,1459839600"; d="scan'208";a="1001479102" Received: from smonroyx-mobl.ger.corp.intel.com (HELO [10.237.221.32]) ([10.237.221.32]) by orsmga002.jf.intel.com with ESMTP; 20 Jun 2016 04:29:07 -0700 To: Thomas Monjalon References: <1466088738-16990-1-git-send-email-slawomirx.mrozowicz@intel.com> <3354397.Tgjzuq1405@xps13> <5727542.OiCZAjWWDW@xps13> Cc: Slawomir Mrozowicz , dev@dpdk.org, david.marchand@6wind.com From: Sergio Gonzalez Monroy Message-ID: <93a9aba2-4fd0-ea57-18bc-b794ecb91b92@intel.com> Date: Mon, 20 Jun 2016 12:29:06 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: <5727542.OiCZAjWWDW@xps13> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v5] eal: out-of-bounds write 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: Mon, 20 Jun 2016 11:29:13 -0000 On 20/06/2016 11:09, Thomas Monjalon wrote: > 2016-06-20 10:38, Sergio Gonzalez Monroy: >> On 20/06/2016 10:14, Thomas Monjalon wrote: >>>> + RTE_LOG(ERR, EAL, >>>> + "All memory segments exhausted by IVSHMEM. " >>> There is no evidence that it is related to IVSHMEM. >>> "Not enough memory segments." would be more appropriate. >> Actually we would hit this issue when all memsegs have been used by IVSHMEM. >> So I think the message is accurate. > I think it's saner to avoid mixing "potential root cause of a use case" and > "accurate description of the error". > One day, the root cause could be different and the message will become wrong. > Here there is not enough memory segment. > Right. So the whole point of doing the check before the loop was to display the error message with its specific cause. I would think that if the code changes and the message is not accurate then it should also be updated. So if folks prefer a more generic error message probably we don't need the check before the loop and just change the check condition inside the loop that would end up printing the generic error message (after the loop). Basically v1 would do that. http://dpdk.org/dev/patchwork/patch/12241/ Sergio