From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by dpdk.org (Postfix) with ESMTP id 6BE192C72 for ; Tue, 28 Aug 2018 12:14:23 +0200 (CEST) Received: by mail-wm0-f68.google.com with SMTP id c14-v6so1315653wmb.4 for ; Tue, 28 Aug 2018 03:14:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:content-transfer-encoding:mime-version; bh=I+DOwr2zfM4K6oHdER1lDehhlrAVcX1ncZQmDbZM6+k=; b=iH0Hb+QkX1S7QAj9NoMe7Vi+g1de15w934ZOS2BdiIdA91Biwk9idVwWviTsd2nXxV 8Pcf6hP8h+UELj08swciYA170qEP9GNmlsN2UOWhEc6bSdbHvwgwcx6ZoJcOtG7SQo7X P5jbHOKBJmzCnJrssKbh9rsV6zUDajWcm8Oh71G5iAvqYOoCd8sJmUj1UhnG87WfsvvZ 62JH28fBK35nMDgFPQVXU8+3OpJkkDxtP6f7vnLMpx3cHViqHFPzeIrQ16ddFEX3vdrN Y9NbBzDU8pj4waCy0OcBnPS4ajmVlTHl5SogsQaCSaWfRh+xMzh1i9rTwrcEm1/bfDGW rNHQ== X-Gm-Message-State: APzg51DJi1KPwz4E+5TCd7pwd4F0H6ur/im2t6wVY/WJyMvzBsldcFeu xC/AUVyKQ64kBuLZSFDZfec= X-Google-Smtp-Source: ANB0VdaSe8/V6KNErNsITDWhQ1q7txzqTyeRdI9Jye4A1IOWAQNga0SvALda5/jsREo/lmLPIztvPg== X-Received: by 2002:a1c:1584:: with SMTP id 126-v6mr917856wmv.24.1535451263201; Tue, 28 Aug 2018 03:14:23 -0700 (PDT) Received: from localhost ([2001:1be0:110d:fcfe:41aa:5bfa:6cf3:7531]) by smtp.gmail.com with ESMTPSA id o15-v6sm460442wru.23.2018.08.28.03.14.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 28 Aug 2018 03:14:22 -0700 (PDT) Message-ID: <1535451261.1113.1.camel@debian.org> From: Luca Boccassi To: Tiwei Bie Cc: dev@dpdk.org, maxime.coquelin@redhat.com, zhihong.wang@intel.com, bruce.richardson@intel.com, Brian Russell Date: Tue, 28 Aug 2018 11:14:21 +0100 In-Reply-To: <20180828064353.GA80296@fbsd.sh.intel.com> References: <20180824171420.31246-1-bluca@debian.org> <20180827165240.28322-1-bluca@debian.org> <20180827165240.28322-2-bluca@debian.org> <20180828064353.GA80296@fbsd.sh.intel.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Evolution 3.22.6-1+deb9u1 Mime-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v5 2/2] virtio: fix PCI config err handling X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Aug 2018 10:14:23 -0000 On Tue, 2018-08-28 at 14:43 +0800, Tiwei Bie wrote: > I just noticed the title. It should be "net/virtio: xxx", > instead of "virtio: xxx". Fixed > On Mon, Aug 27, 2018 at 05:52:40PM +0100, Luca Boccassi wrote: > [...] > > + ret =3D rte_pci_read_config(dev, &flags, > > sizeof(flags), > > + pos + sizeof(cap)); > > + if (ret !=3D sizeof(flags)) { > > + PMD_INIT_LOG(DEBUG, > > + =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0"failed to read pci > > cap at pos:" > > + =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0" %lx ret %d", pos + > > sizeof(cap), > > + =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0ret); >=20 > In file included from drivers/net/virtio/virtio_pci.c:15:0: > drivers/net/virtio/virtio_pci.c: In function =E2=80=98vtpci_msix_detect= =E2=80=99: > drivers/net/virtio/virtio_logs.h:13:3: error: format =E2=80=98%lx=E2=80= =99 expects > argument of type =E2=80=98long unsigned int=E2=80=99, but argument 5 has = type > =E2=80=98unsigned int=E2=80=99 [-Werror=3Dformat=3D] > =C2=A0=C2=A0=C2=A0"%s(): " fmt "\n", __func__, ##args) > =C2=A0=C2=A0=C2=A0^ > drivers/net/virtio/virtio_pci.c:737:5: note: in expansion of macro > =E2=80=98PMD_INIT_LOG=E2=80=99 > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0PMD_INIT_LOG(DEBUG, > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0^ > cc1: all warnings being treated as errors >=20 > I got above build issues in 32bit build. >=20 >=20 > Apart from that, >=20 > Reviewed-by: Tiwei Bie >=20 > Thanks! So the 32 and 64 bit builds want opposite things, due to the sizeof type. I changed it to avoid sizeof and just calculate it like in every other prints of these functions to avoid the issue. --=20 Kind regards, Luca Boccassi