From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7EDA2A0613 for ; Fri, 27 Sep 2019 10:06:57 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 492D72C16; Fri, 27 Sep 2019 10:06:57 +0200 (CEST) Received: from mail-io1-f68.google.com (mail-io1-f68.google.com [209.85.166.68]) by dpdk.org (Postfix) with ESMTP id ABF5A2BE6 for ; Fri, 27 Sep 2019 10:06:55 +0200 (CEST) Received: by mail-io1-f68.google.com with SMTP id b19so14041338iob.4 for ; Fri, 27 Sep 2019 01:06:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=q2OHuIEW30fIVp2UQRbAusxW/a2tPYNh7LZQI5PBOGs=; b=o6sJM9+W9QMRx8dIUOskG0qUSYMMtUUVUTsiOsFJTjHWEwqWQ+5WupmnFpyMhYbTs7 4SzQQhAhYYrMuctlYyn8EMU8LkmcMAbq8BdANP0kwcQ0HGasMFD1+vg+EYA2qQYhtb2U kSISBp8OoBMocowLoR76yBfc4Pul2I3+RWWr2NvwMaWFHO65SonfgGF1zhKAnQ85Z18g YNHaIpETXs8VXG/Dx59ohvnCBSWz5m3SM+7b/dYNiHMQl1eFwyBVvYIx0LmGtBUfX8wD dlvAkOJg1lBZgfAImJ/35ISSNfqPZCfBIMxzR2X1/GGm8Apv7CgQ0QegV6nlT7nyRsFV unvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=q2OHuIEW30fIVp2UQRbAusxW/a2tPYNh7LZQI5PBOGs=; b=NRVacXNT/sxdUJHCHJ3+hYPC/RHFf7xFoalHLsYqf1z+yPA9fPcGXGNSihHyXwrus/ qVgb0Ime5T2hBwOtV6qJxJIY0/P8uCBp/9dTUTlXVcNRWqzquNFjt5so6ajcGuNu/BDa r6QagEbo/qvDRPKuJkUYJ2VTNi+nMqvRyUQqO5a/18RqAj8yWuMJgBr2dJqDwbznYHd/ zJaiJOFerMhPUGxHgZz2GrokRUeGIbezvXvk/8McPLDpbn4lXvqIoBOdCokvlznP2A/+ PfMdBnG2DOldPgSSGjeLVPOIao1mcTHuYrmJwz5/riCaVJXgkS9X7rT4YI6S+AoFS0RO PNGg== X-Gm-Message-State: APjAAAUKcSLqUkxTq4TJ7x99g7IaUo6q012cQWIfm34erjKDWyYea+zA bMKpO91oxGgkwIxYa/wPF/L4NSnZ6ftkoRKWJ5c= X-Google-Smtp-Source: APXvYqybtIgr9TIlEcnFxmjXYhlZeRnoCVAHvUrOCqkJmjtpqLi6xZ5xxz6/nARIyY7FSviNOcBLl6QNTbVpZhZ3V2g= X-Received: by 2002:a6b:c895:: with SMTP id y143mr6049894iof.271.1569571614953; Fri, 27 Sep 2019 01:06:54 -0700 (PDT) MIME-Version: 1.0 References: <20190909195404.4760-1-pallavi.kadam@intel.com> <20190926202924.6876-1-pallavi.kadam@intel.com> <20190926202924.6876-6-pallavi.kadam@intel.com> In-Reply-To: <20190926202924.6876-6-pallavi.kadam@intel.com> From: Jerin Jacob Date: Fri, 27 Sep 2019 13:36:43 +0530 Message-ID: To: Pallavi Kadam Cc: dpdk-dev , Thomas Monjalon , Harini.Ramakrishnan@microsoft.com, keith.wiles@intel.com, "Richardson, Bruce" , ranjit.menon@intel.com, antara.ganesh.kolar@intel.com Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH v2 5/9] eal: add additional function overrides in windows header files 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" On Fri, Sep 27, 2019 at 2:25 AM Pallavi Kadam wrote: > > Adding additional function definitions for pthread, cpuset > implementation, asprintf implementation, in order to support > common code. > > Signed-off-by: Pallavi Kadam > Signed-off-by: Antara Ganesh Kolar > Reviewed-by: Ranjit Menon > Reviewed-by: Keith Wiles > --- > lib/librte_eal/common/include/rte_lcore.h | 5 ++ > lib/librte_eal/windows/eal/include/pthread.h | 66 +++++++++++++++++++ > lib/librte_eal/windows/eal/include/rte_os.h | 28 ++++++++ > lib/librte_eal/windows/eal/include/sched.h | 58 ++++++++++++++-- > .../windows/eal/include/sys/queue.h | 8 +++ > 5 files changed, 159 insertions(+), 6 deletions(-) > > diff --git a/lib/librte_eal/common/include/rte_lcore.h b/lib/librte_eal/common/include/rte_lcore.h > index c86f72eb1..d5e7e3e33 100644 > --- a/lib/librte_eal/common/include/rte_lcore.h > +++ b/lib/librte_eal/common/include/rte_lcore.h > @@ -64,6 +64,11 @@ typedef cpuset_t rte_cpuset_t; > CPU_NAND(&tmp, src); \ > CPU_COPY(&tmp, dst); \ > } while (0) > +#elif defined(_WIN64) > +#define RTE_CPU_AND(dst, src1, src2) CPU_AND(dst, src1, src2) > +#define RTE_CPU_OR(dst, src1, src2) CPU_OR(dst, src1, src2) > +#define RTE_CPU_FILL(set) CPU_FILL(set) > +#define RTE_CPU_NOT(dst, src) CPU_NOT(dst, src) RTE_CPU* definitions are OS-specific. Instead of adding new #elif and make the common code less readable. Please create eal abstraction for the same and move Linux, FreeBSD, Windows to the specific directory to avoid #ifdef clutter in lib/librte_eal/common/include/rte_lcore.h. > #endif >