From mboxrd@z Thu Jan 1 00:00:00 1970 From: Remy Horton Subject: Re: [PATCH v3 2/2] examples/ethtool: get reg width to allocate memory Date: Tue, 07 Jun 2016 10:52:25 +0100 Message-ID: <57569959.5000407@intel.com> References: <1464767771-19159-1-git-send-email-zr@semihalf.com> <1464767771-19159-2-git-send-email-zr@semihalf.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org To: zr@semihalf.com, thomas.monjalon@6wind.com Return-path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 7935F95FE for ; Tue, 7 Jun 2016 11:52:28 +0200 (CEST) In-Reply-To: <1464767771-19159-2-git-send-email-zr@semihalf.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 01/06/2016 08:56, zr@semihalf.com wrote: > From: Zyta Szpak > > Version 2 of fixing the fixed register width assumption. > Not every device uses 32-bit wide register. The app was allocating too > little space for 64-bit registers which resulted in memory corruption. > This commit resolves this by getting the size of register in bytes for > a specific device. If the device does not implement this function, it > fallsback to sizeof(uint32_t) > > Signed-off-by: Zyta Szpak Acked-by: Remy Horton