From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f45.google.com (mail-wm0-f45.google.com [74.125.82.45]) by dpdk.org (Postfix) with ESMTP id B68B64CE4 for ; Fri, 15 Jul 2016 18:42:26 +0200 (CEST) Received: by mail-wm0-f45.google.com with SMTP id f126so32803409wma.1 for ; Fri, 15 Jul 2016 09:42:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=iLnTP1leS7mzzzTk01ak/4cXhnOCAz7VO1h9uRl1X48=; b=GAPYgdVVbBOn412EvvcZHCOF5d4S+iORJjAhmDctkeqLfMAPvob8k36WucaB/q0FRE svV9VYxh+tPWHoIdriAZY9rUpbzjDQLau+1urbqjgXNnaH9FHm3Y2NWu7GQV6wLda7Ux ooXUpTGjWc14L/VSrOFpBkAI9p2KJeG7rQdd0tMWBWMe3aJDIgbPu8lwmn5C0ZVLHnOb OLN9EN+zrN1vMnX5N5friCGNh3w2qJ6e1JNdf+dzdu8RfXJQOBaYa1VF6nS5wB3FvLJQ MSlMkmkPxXd8c8V1AVxL77oJGnj/wW5rhlb7aKsOBViG9ghkr89OEF5wgPpjlijmMEtq Vlkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=iLnTP1leS7mzzzTk01ak/4cXhnOCAz7VO1h9uRl1X48=; b=F22zD0lDrAbvjSr08xdtKMLzyRKYgQZQMk1gWa096BKZrF8y6dK4dF3lkTUNAPQKKA uZbyPqJk2kiFPIhZhwM8/2z4F4MZh4ejTE669iZEZukEllj/QqNs7zmxyQAs2jAm2TpT mR7fFeAHsMFbJpe5piUtQrs9NOFrQugnrR8I7p52OE4sCP9xe6AHxonxJyJkIWn6AjWN tx6YoQhfp7q+TaatCbxSHlfHGBoGhsZNhh8YO+saWqm9l0OpH0dQ+CzfIfBwOZHHlIlz C+t3Mxz/x/NChYaVvwApr8BL3efEpyuiozGmtUjk5NH4w80SgAALS3DJJJBgg77Uahmi U6zA== X-Gm-Message-State: ALyK8tL690yaSuUVjoYGgVPRn8SzKbBqm+FnoTBBAT/AfkFOtV8zkjoVyegpmQKBz5HLX+0N X-Received: by 10.194.53.228 with SMTP id e4mr1602913wjp.179.1468600946535; Fri, 15 Jul 2016 09:42:26 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id bf3sm1568186wjb.32.2016.07.15.09.42.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 15 Jul 2016 09:42:25 -0700 (PDT) From: Thomas Monjalon To: Yong Wang Cc: dev@dpdk.org, anatoly.burakov@intel.com, dan@kernelim.com, Ronghua Zhang Date: Fri, 15 Jul 2016 18:42:24 +0200 Message-ID: <2113476.6KVZGvHTNJ@xps13> User-Agent: KMail/4.14.10 (Linux/4.5.4-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <6504660.SWBHcg24lf@xps13> References: <20160714153415.GA8329@gmail.com> <1468541710-47751-1-git-send-email-yongwang@vmware.com> <6504660.SWBHcg24lf@xps13> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Subject: Re: [dpdk-dev] [PATCH v2] vfio: fix pci_vfio_map_resource 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: Fri, 15 Jul 2016 16:42:26 -0000 2016-07-15 17:32, Thomas Monjalon: > 2016-07-14 17:15, Yong Wang: > > -=09=09=09=09void *second_addr =3D RTE_PTR_ADD(bar_addr, memreg[1].= offset); > > +=09=09=09=09void *second_addr =3D RTE_PTR_ADD(bar_addr, > > +=09=09=09=09=09=09=09=09memreg[1].offset - reg.offset); >=20 > There is an error for 32-bit: > =09error: cast to pointer from integer of different size > =09note: in expansion of macro =E2=80=98RTE_PTR_ADD=E2=80=99 It can fixed like this: - memreg[1].offset - reg.offset); + memreg[1].offset - + (uintptr_t)reg.offset);