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 36C83A0C42 for ; Tue, 11 May 2021 09:55:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 23901410E9; Tue, 11 May 2021 09:55:53 +0200 (CEST) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by mails.dpdk.org (Postfix) with ESMTP id D78394003E; Tue, 11 May 2021 09:55:50 +0200 (CEST) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 7A1B05C0126; Tue, 11 May 2021 03:55:50 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Tue, 11 May 2021 03:55:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm1; bh= qxtq1iRegA+e8JzPEQjU3ZyZ/ClWzEln0OMgFku2XhM=; b=yY2mAP5om3dV1Gdv RKhe753SiT1jgyC0GP1ZXaO5fKj0vt1DtfxMYUAfnxTXFbFe/eDo7/yjIxxt6Ont uvpsyzxBb6WWQJXzR5gS4Zm/gJTJ5sniXzLwYWEK2i+/92pZ1aUP4nSHxsDzg4Wn eqcQNyqWQk0hJASbeWVC2XtVZRJ2bJWBj5F7Wr1nQHA0ZlA1mJy/irlCB1UVr/V+ d2DqAlCEzY5qERnf9W/1RJjMUj7IWaLZh6tPtESFXBhGoBvCDx1ZxAiAaYFhgnug 40aadMOWu3gbfMqBZphCmx/+kFERPIqbDppWmQrWwsNjFouVorfA1LjNAWnvPi3a z4Poww== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=qxtq1iRegA+e8JzPEQjU3ZyZ/ClWzEln0OMgFku2X hM=; b=nrdCCsnlkgDkC+6GqPfFaATSToGrz1k2LVDZfnvFh6UtWORyKUKDfQbPR uU8DWDoHJZq4KRLeVH/MZJ90SU7I/7VEp8v6WP1Jsqnjopd87F07IuwCW1NiJ9RC ePox00/dMV9uuBKVJ/oUxsKPqUe3mIpalKoRwg3RFQ0rQ1svI4xOZq1NNmCgKwjQ 7lw47GWA7zPYz22h7TA8a7U73rQVgTZ3yoD/ikCkpzpoQl/v5GzS15IiS38pSx/i lEkceihr83cRExmH/dZGBYgIwjaxaJMZh3xKSpw0wojzAOf24VODKHHa21dB3BwI ZIwZ0Rhr2RNgPJaPGrTcgHN3rtQHA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdegledguddviecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdej ueeiiedvffegheenucfkphepjeejrddufeegrddvtdefrddukeegnecuvehluhhsthgvrh fuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgr lhhonhdrnhgvth X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 11 May 2021 03:55:48 -0400 (EDT) From: Thomas Monjalon To: Lance Richardson Cc: stable@dpdk.org, "Burakov, Anatoly" , Dmitry Kozlyuk , Narcisa Ana Maria Vasile , Dmitry Malloy , Pallavi Kadam , dev@dpdk.org, dpdk stable Date: Tue, 11 May 2021 09:55:47 +0200 Message-ID: <1626253.x5JiVkcpTH@thomas> In-Reply-To: References: <20210507181025.84012-1-lance.richardson@broadcom.com> <4580427.4aQfPY00Ab@thomas> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH v3] eal: fix memory mapping for 32-bit targets 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 Sender: "stable" 10/05/2021 18:04, Lance Richardson: > On Mon, May 10, 2021 at 11:55 AM Thomas Monjalon > wrote: > > > 10/05/2021 17:31, Burakov, Anatoly: > > > On 10-May-21 1:42 PM, Thomas Monjalon wrote: > > > > +Cc Anatoly > > > > > > > > 08/05/2021 16:27, Lance Richardson: > > > >> For 32-bit targets, size_t is normally a 32-bit type and > > > >> does not have sufficient range to represent 64-bit offsets > > > >> that can are needed when mapping PCI addresses. Use uint64_t > > > >> instead. > > > >> > > > >> Found when attempting to run 32-bit Linux dpdk-testpmd > > > >> using VFIO driver: > > > >> > > > >> EAL: pci_map_resource(): cannot map resource(63, 0xc0010000, \ > > > >> 0x200000, 0x20000000000): Invalid argument ((nil)) > > > >> > > > >> Fixes: c4b89ecb64ea ("eal: introduce memory management wrappers") > > > >> Cc: stable@dpdk.org > > > >> Signed-off-by: Lance Richardson > > > >> --- > > > > > > LGTM, although the Fixes: tag is probably wrong because IIRC previous > > > versions did have the same issue. > > > > What should be the right Fixes tag Anatoly? > > > > I think this would be more appropriate (prior to this commit, > pci_map_resource() > called mmap() directly with off_t offset, with this commit offset was > narrowed > to size_t before calling mmap()): > > Fixes: 2fd3567e5425 ("pci: use OS generic memory mapping functions") That's only one usage of rte_mem_map. I prefer the original Fixes: line.