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 99D32A0C3F for ; Wed, 28 Apr 2021 11:26:24 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 84017411D9; Wed, 28 Apr 2021 11:26:24 +0200 (CEST) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mails.dpdk.org (Postfix) with ESMTP id BE5A640147; Wed, 28 Apr 2021 11:26:21 +0200 (CEST) IronPort-SDR: neBZoZeKF2M1O/ivCFpDpNeDZ3EGy2T7wemE3O9QwQA259yTuofigNZcFVOKShOS/ergkuIkVc Y0WoKCpBk/ww== X-IronPort-AV: E=McAfee;i="6200,9189,9967"; a="194583509" X-IronPort-AV: E=Sophos;i="5.82,257,1613462400"; d="scan'208";a="194583509" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Apr 2021 02:26:20 -0700 IronPort-SDR: EK01fG08qp+AoLPLHHkIpjyjkLgFGy4fjx6tgmoanxL7CbVoUb1oKOv//NPfST6QaqlCbDUfED SySEMIH+Dogg== X-IronPort-AV: E=Sophos;i="5.82,257,1613462400"; d="scan'208";a="423443986" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.213.241.177]) ([10.213.241.177]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Apr 2021 02:26:19 -0700 To: Wei Huang , dev@dpdk.org, rosen.xu@intel.com, qi.z.zhang@intel.com Cc: stable@dpdk.org, tianfei.zhang@intel.com References: <20210422082716.4734-1-wei.huang@intel.com> From: Ferruh Yigit X-User: ferruhy Message-ID: <26133efc-2ebc-8b5b-657e-b3a468cd0fb7@intel.com> Date: Wed, 28 Apr 2021 10:26:15 +0100 MIME-Version: 1.0 In-Reply-To: <20210422082716.4734-1-wei.huang@intel.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-stable] [PATCH v1] raw/ifpga: fix ifpga device name format 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" On 4/22/2021 9:27 AM, Wei Huang wrote: > The device name format used in ifpga_rawdev_create() was changed to > "IFPGA:%02x:%02x.%x", but the format used in ifpga_rawdev_destroy() > was left as "IFPGA:%x:%02x.%x", it should be changed synchronously. > Hi Wei, If the name is significant, why not convert the format into a macro and use it? This prevents further similar errors, also highlights that format should be exact same. > Fixes: 9c006c45d0c5 ("raw/ifpga: scan PCIe BDF device tree") > Cc: stable@dpdk.org > > Signed-off-by: Wei Huang > --- > drivers/raw/ifpga/ifpga_rawdev.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/raw/ifpga/ifpga_rawdev.c b/drivers/raw/ifpga/ifpga_rawdev.c > index d9a46ef915..f591a87b49 100644 > --- a/drivers/raw/ifpga/ifpga_rawdev.c > +++ b/drivers/raw/ifpga/ifpga_rawdev.c > @@ -1551,7 +1551,7 @@ ifpga_rawdev_destroy(struct rte_pci_device *pci_dev) > } > > memset(name, 0, sizeof(name)); > - snprintf(name, RTE_RAWDEV_NAME_MAX_LEN, "IFPGA:%x:%02x.%x", > + snprintf(name, RTE_RAWDEV_NAME_MAX_LEN, "IFPGA:%02x:%02x.%x", > pci_dev->addr.bus, pci_dev->addr.devid, pci_dev->addr.function); > > IFPGA_RAWDEV_PMD_INFO("Closing %s on NUMA node %d", >