From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 5DFB1A0679 for ; Tue, 2 Apr 2019 05:55:10 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 6A8A058F6; Tue, 2 Apr 2019 05:55:05 +0200 (CEST) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 954D854AE for ; Tue, 2 Apr 2019 05:55:01 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 01 Apr 2019 20:55:00 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,298,1549958400"; d="scan'208";a="287910248" Received: from anandraw-devbx.amr.corp.intel.com ([10.19.242.57]) by orsmga004.jf.intel.com with ESMTP; 01 Apr 2019 20:54:59 -0700 From: Anand Rawat To: dev@dpdk.org Cc: anand.rawat@intel.com, pallavi.kadam@intel.com, ranjit.menon@intel.com, jeffrey.b.shaw@intel.com, bruce.richardson@intel.com, thomas@monjalon.net Date: Mon, 1 Apr 2019 20:54:49 -0700 Message-Id: <20190402035458.14664-2-anand.rawat@intel.com> X-Mailer: git-send-email 2.17.1.windows.2 In-Reply-To: <20190402035458.14664-1-anand.rawat@intel.com> References: <20190306041634.12976-1-anand.rawat@intel.com> <20190402035458.14664-1-anand.rawat@intel.com> Subject: [dpdk-dev] [PATCH v8 01/10] eal: eal stub to add windows support 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Content-Type: text/plain; charset="UTF-8" Message-ID: <20190402035449.eW74Hn7e5PcJH2hzVWZgDMIEBOcEX6XVVnNF_4LT1Gc@z> Added initial stub source files for windows support. Updated the MAINTAINERS list for windows support. Signed-off-by: Pallavi Kadam Signed-off-by: Anand Rawat Reviewed-by: Jeff Shaw Reviewed-by: Ranjit Menon --- MAINTAINERS | 7 ++++++ lib/librte_eal/windows/eal/eal.c | 14 +++++++++++ lib/librte_eal/windows/eal/eal_debug.c | 15 ++++++++++++ lib/librte_eal/windows/eal/eal_lcore.c | 32 +++++++++++++++++++++++++ lib/librte_eal/windows/eal/eal_thread.c | 18 ++++++++++++++ 5 files changed, 86 insertions(+) create mode 100644 lib/librte_eal/windows/eal/eal.c create mode 100644 lib/librte_eal/windows/eal/eal_debug.c create mode 100644 lib/librte_eal/windows/eal/eal_lcore.c create mode 100644 lib/librte_eal/windows/eal/eal_thread.c diff --git a/MAINTAINERS b/MAINTAINERS index 9f34f905f..5d70fba9b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -283,6 +283,13 @@ FreeBSD UIO M: Bruce Richardson F: kernel/freebsd/nic_uio/ +Windows support +M: Harini Ramakrishnan +M: Omar Cardona +M: Anand Rawat +M: Ranjit Menon +F: lib/librte_eal/windows/ + Core Libraries -------------- diff --git a/lib/librte_eal/windows/eal/eal.c b/lib/librte_eal/windows/eal/eal.c new file mode 100644 index 000000000..37ed42233 --- /dev/null +++ b/lib/librte_eal/windows/eal/eal.c @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2019 Intel Corporation + */ + +#include + + /* Launch threads, called at application init(). */ +int +rte_eal_init(int argc __rte_unused, char **argv __rte_unused) +{ + /* TODO */ + /* This is a stub, not the expected result */ + return 0; +} diff --git a/lib/librte_eal/windows/eal/eal_debug.c b/lib/librte_eal/windows/eal/eal_debug.c new file mode 100644 index 000000000..a9705e257 --- /dev/null +++ b/lib/librte_eal/windows/eal/eal_debug.c @@ -0,0 +1,15 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2019 Intel Corporation + */ + +#include + + /* call abort(), it will generate a coredump if enabled */ +void +__rte_panic(const char *funcname __rte_unused, + const char *format __rte_unused, ...) +{ + /* TODO */ + /* This is a stub, not the expected result */ + abort(); +} diff --git a/lib/librte_eal/windows/eal/eal_lcore.c b/lib/librte_eal/windows/eal/eal_lcore.c new file mode 100644 index 000000000..e4fcb2615 --- /dev/null +++ b/lib/librte_eal/windows/eal/eal_lcore.c @@ -0,0 +1,32 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2019 Intel Corporation + */ + +#include + + /* Get the cpu core id value */ +unsigned int +eal_cpu_core_id(unsigned int lcore_id) +{ + /* TODO */ + /* This is a stub, not the expected result */ + return lcore_id; +} + +/* Check if a cpu is present by the presence of the cpu information for it */ +int +eal_cpu_detected(unsigned int lcore_id __rte_unused) +{ + /* TODO */ + /* This is a stub, not the expected result */ + return 1; +} + +/* Get CPU socket id (NUMA node) for a logical core */ +unsigned int +eal_cpu_socket_id(unsigned int cpu_id __rte_unused) +{ + /* TODO */ + /* This is a stub, not the expected result */ + return 0; +} diff --git a/lib/librte_eal/windows/eal/eal_thread.c b/lib/librte_eal/windows/eal/eal_thread.c new file mode 100644 index 000000000..f701443c3 --- /dev/null +++ b/lib/librte_eal/windows/eal/eal_thread.c @@ -0,0 +1,18 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2019 Intel Corporation + */ + +#include + +#include + +typedef uintptr_t eal_thread_t; + +/* function to create threads */ +int +eal_thread_create(eal_thread_t *thread __rte_unused) +{ + /* TODO */ + /* This is a stub, not the expected result */ + return 0; +} -- 2.17.1.windows.2