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 6FCB6A034F; Thu, 25 Feb 2021 15:51:56 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D4EA51608D5; Thu, 25 Feb 2021 15:51:55 +0100 (CET) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id AE7B840692 for ; Thu, 25 Feb 2021 15:51:53 +0100 (CET) IronPort-SDR: eDaWVKa2cZXYRXlRdTG42kd0IePEgVDvDjBPvkIrAT14RjOFB0LAdbR1vsA4B8JYdYxBKxHu+y g7K+CnxW25Mg== X-IronPort-AV: E=McAfee;i="6000,8403,9905"; a="246966374" X-IronPort-AV: E=Sophos;i="5.81,205,1610438400"; d="scan'208";a="246966374" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Feb 2021 06:51:52 -0800 IronPort-SDR: bxELIMBoylDZj4eqsvpEhdxalYHV9rGPjmySvoXaTwVhQt/DpfOG7Avw8G02ZykZv3KCrO4ifl BCm37cC1EDVw== X-IronPort-AV: E=Sophos;i="5.81,205,1610438400"; d="scan'208";a="404317146" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.252.17.100]) ([10.252.17.100]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Feb 2021 06:51:50 -0800 To: Dmitry Kozlyuk , dev@dpdk.org Cc: Tyler Retzlaff , Mike Wells References: <20210214012013.23165-1-dmitry.kozliuk@gmail.com> <20210214021616.26970-1-dmitry.kozliuk@gmail.com> <20210214021616.26970-4-dmitry.kozliuk@gmail.com> From: Ferruh Yigit X-User: ferruhy Message-ID: <0605b40f-d655-8a7f-89c9-802af0ff6d94@intel.com> Date: Thu, 25 Feb 2021 14:51:46 +0000 MIME-Version: 1.0 In-Reply-To: <20210214021616.26970-4-dmitry.kozliuk@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH v2 3/6] net/pcap: move OS-dependent code to separate files X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 2/14/2021 2:16 AM, Dmitry Kozlyuk wrote: > PCAP PMD queries interface information differently for Linux and > FreeBSD, OS-specific code is guarded by #ifdef. In preparation to add > Windows-specific part and libpcap wrapper, extract OS-independent > interface and move implementations to separate files. Rename > rte_eth_pcap.c to pcap_ethdev.c for consistency with the rest of DPDK. > > Signed-off-by: Dmitry Kozlyuk <...> > +int > +osdep_iface_index_get(const char *name) > +{ > + return if_nametoindex(name); > +} The 'osdep_iface_index_get' wrapper is not required for this patch and can be done in patch 6/6, but OK to have here to make the switch clear. Reviewed-by: Ferruh Yigit