From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BY2-obe.outbound.protection.outlook.com (mail-by2nam01on0069.outbound.protection.outlook.com [104.47.34.69]) by dpdk.org (Postfix) with ESMTP id 0B8631B768 for ; Tue, 3 Apr 2018 17:05:46 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=zsaDz8rXPv/5uo2WZMgiSJb8QG4/kMqe+cgB2GJXPSU=; b=EOOjFCgaeD2rlhSHWoJcEzlFPhfUPpqmdPr6S89u2/ijpryavFspbPpaMgaoXYiULpRYV0oLWqHJamkklucnaKEIGj0T+IamTRc/HH1T3LUkhlr5TFZU3Aw4S0mbV1b7DA+pjKRqTWyrXBLyZPdB+uK7eZ811NUV50yGHAtNd10= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from ltp-pvn.caveonetworks.com (111.93.218.67) by MWHPR07MB3470.namprd07.prod.outlook.com (2603:10b6:301:63::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.631.10; Tue, 3 Apr 2018 15:05:43 +0000 From: Pavan Nikhilesh To: jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, erik.g.carrillo@intel.com Cc: dev@dpdk.org, Pavan Nikhilesh Date: Tue, 3 Apr 2018 20:35:03 +0530 Message-Id: <20180403150514.24201-2-pbhagavatula@caviumnetworks.com> X-Mailer: git-send-email 2.16.3 In-Reply-To: <20180403150514.24201-1-pbhagavatula@caviumnetworks.com> References: <20180216213700.3415-1-pbhagavatula@caviumnetworks.com> <20180403150514.24201-1-pbhagavatula@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: BM1PR0101CA0070.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:19::32) To MWHPR07MB3470.namprd07.prod.outlook.com (2603:10b6:301:63::21) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9afbbbe0-75fa-4045-7fdb-08d599746066 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4604075)(2017052603328)(7153060)(7193020); SRVR:MWHPR07MB3470; X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3470; 3:7y1s7vt+t0dP71sgAS8Fa1MrYiK+5crTMcQ/JJ6Wnmw0ZpzHLjNyveTUzO7VSTonzXa2es/K5w8MC6fT0qjxR0vak6+agDn8mHb4+ELpw+mGG3JlNz4oy/dMWnl1Ftjso8GBNUXxUy02TJRvFWSfA6rs4m1L6ZjlAH6A8fEN7/CCU0hT971J2+v+R0ozvKGi0AnSCNKcePeFz7x1MLjFmL1DriX4k+1Abj+7CBQq5Lou75Du7/tcb/iX3mw0JkvG; 25:9hTcDlqsDjqihoaqnVu3bU/JGltDzAFrOJRytdBcX6kqeUazwFpq+vHjgpvtbK/LmI4ZtnX1Nt0pbrpL1fFW31FOHQLCd/3AZmesvMsycgIN7AwXWPx8AfwEy2ZmKT8M5M7MtlZH6lD4twOxgPtVNbWY+Ntnt6bOgldafiU4yncojWP8XB2GymEspV3F6rx6atZ3Ddcq8ndjM1tG2Vwy6B4RXn1K9D7FnC/hpJaowaQdDlP37Y1zZOwLzG4rBSG1NGmkZirdpddhTkfF6c0pdPbLT9SyAAbKeWdnojFV+AAyC6ti2UeFU3hlBv7gR6pHtLZp/v1stUFEL0oo6+D8lQ==; 31:VXhuAzrdH235dSlcm1hlDkfG0zWghNn+wRSbJcFX7W5QDYVyhUN4BVTRz2y8r5y4+LuDFUbi3rxulpgctS4xdYjR1i8ErTS1iAvDIVIBPIih5JE4Lj0vdBNTPwMGZ5gZXc42v3wNpz3pYwuPXFYG1rbNGX0xY1DbHY4TUylI0ouylpJZv1gMiBDYUmdkykqONwYNoofVGrAm9pf86ZHrJHl/cY8RjqGTgBIc7PCkaB0= X-MS-TrafficTypeDiagnostic: MWHPR07MB3470: X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3470; 20:cg08c5V+z1G98BIgZslkNArGnNid2a17XTehL/rHHmgJvLy6EfvfbNsyN7OMcxylwMhkv9AnZhwSQxggjxFSl56qUwzfAUhBAe3kxIGmvrW7IsXOGzxAmcXOo9dRX8qxLrgKFHw253sUacQDurRoCFrXIJc+FmhsyBelo0U+wEQueH51R5pqpvR/49EV2corvtZi/V4tn9xdMEa2xdx0txQ+x3eJhX1YZGNTijRsCk2LenvwlwCY6nRn6lyB6Fr/me8y884BWuCmycRJpEuGgvhCTlj2Pem19boJiKp2OluqGVfdxRBYjVe8THq0P1ZuIAlyMj2z5Ep6XpgyYka1o2z3lboHHxHd21b1OQJ+cjdZ2i+e8XiJdLq/vh0Rmbc89G+f7EV4yv9sg8KO8vLceQKFRvo9SCefztI/NEzoKppisdr8n5TBzcOKAE6SEk7z6ovLu6Dc41fw1DIisvXLnbJvHDjaugC50vv+yYBHvRjvFQHGhgwMLCnKsjloEsBGEfdAHEz513BLDg6JCCTIggsRsUNcqJ9moRIumZMHld467mHgPefGj8f1GVJ7lL8UxHSVIMfrToIjYFkHHzoNP593Q0B265Xq8SNfNngQFqs=; 4:HM673lmlYBcjoNXtIwI3Emc5J6wWRFskEYseYqrD03cpRhlJZMvhVhijAQDrOL8NmPNZYM8eleMGy3GUwWnUd4x/8FRdCbCopeyZ1Rlwo7Egn5IcZHxT7/rNTq6kClY5/fMG/UhtJ5dBKmhVvGl/UW3G/VUbE3WgDf6Tha+gbzz7wYDibdD9ieZzv9IX30SWosWghJo7F5tie4e8KScv/Ul1kjDDUI2w5+WCbFdyPNeQaSfVuu+rUB7ABQ5XYqzH0Pvut/mrSZEOJwI9bwHqJA== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231221)(944501327)(52105095)(10201501046)(3002001)(93006095)(6041310)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123558120)(20161123564045)(6072148)(201708071742011); SRVR:MWHPR07MB3470; BCL:0; PCL:0; RULEID:; SRVR:MWHPR07MB3470; X-Forefront-PRVS: 0631F0BC3D X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(39380400002)(346002)(39850400004)(376002)(366004)(189003)(199004)(47776003)(305945005)(66066001)(72206003)(386003)(6506007)(16586007)(478600001)(316002)(48376002)(7736002)(76176011)(59450400001)(36756003)(52116002)(51416003)(5009440100003)(50466002)(68736007)(106356001)(4326008)(25786009)(486005)(476003)(2906002)(107886003)(6512007)(11346002)(6116002)(2616005)(53416004)(26005)(16526019)(5660300001)(6486002)(3846002)(1076002)(81166006)(81156014)(446003)(956004)(486005)(69596002)(8676002)(6666003)(97736004)(42882007)(50226002)(105586002)(8936002)(1857600001)(575784001)(53936002)(42262002); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR07MB3470; H:ltp-pvn.caveonetworks.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR07MB3470; 23:uzvIvFe7tHGsJlRNa/hBEt9GChMGucOA9MGKCYBbA?= =?us-ascii?Q?MoN6+0jvK80oi7sq2Uc56m/8zHtkq4V8mXe4x0Em11pS6ZIP1NskvjMf87Z7?= =?us-ascii?Q?dA96I0NV1LbL0M0f3Ue+DhJxWJcNKnTBZlk07JQICLx5TtDGNSbEIxyDGYdV?= =?us-ascii?Q?imkTe7yhOVOjoU1Nkr6xU7YUQybHvceswrcd+SYRxa0R3h2TJ4H2SrZz0TNy?= =?us-ascii?Q?EKKWCgbVbRZMc4NLu4h1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jBBNtx8Cwa4+5oS91j5Jgg==; 5:6LEh2JXEdNyDFmr7JfOadQqfxjR+SM3RfGz0YT1q0oouVBcELHUtuuPELeiokaAANcgxQawa76oIpZkb+8FHga1ECG851R22dmG8jh8Jw11qGC5/toISYy1TtvuNnto/OXLPZYZtqfkCMskBiARrmDYvl3AOLQmy0VtALgzBqsk=; 24:LexkGOxfoHxr3NHAo8SDvzX9cyYmIYkx07dNQdNXulEilwE3j+C1d88OZZ+NzClaJYeFfOJiaJS0vJQ1wjMAidCY8vv6WuY8rpy+ufRdrgg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3470; 7:xUQ0qaJFaHhhkoTdiy9Lqkj4uDnvLYAAv4MiX3kQaoFAILte3QOMkMmB9a8dZl9hsXgfwa5z1l4mXQ61tnbiWHQarE1i5tid53+p/loeuTIXoZqXYwfZw1xxF6GOzEp1BP3i+yInSJXkHfGeeOdhBc9OUCkkAXALzXwmgwtVzi3loTaDItUhex0spjT756CtnVmmNKwJEJLiW4hbW7xr9sq7i0FqhW4Eb5kZnee9AjsS3qfOXbk57AVXAech0fO/ X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Apr 2018 15:05:43.7723 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 9afbbbe0-75fa-4045-7fdb-08d599746066 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR07MB3470 Subject: [dpdk-dev] [PATCH v3 01/12] mempool/octeontx: probe timvf PCIe devices 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, 03 Apr 2018 15:05:47 -0000 On Octeontx HW, each event timer device is enumerated as separate SRIOV VF PCIe device. In order to expose as a event timer device: On PCIe probe, the driver stores the information associated with the PCIe device and later when appliacation requests for a event timer device through `rte_event_timer_adapter_create` the driver infrastructure creates the timer adapter with earlier probed PCIe VF devices. Signed-off-by: Pavan Nikhilesh --- drivers/mempool/octeontx/Makefile | 1 + drivers/mempool/octeontx/meson.build | 1 + drivers/mempool/octeontx/octeontx_mbox.h | 7 + drivers/mempool/octeontx/octeontx_timvf.c | 145 +++++++++++++++++++++ .../octeontx/rte_mempool_octeontx_version.map | 3 + 5 files changed, 157 insertions(+) create mode 100644 drivers/mempool/octeontx/octeontx_timvf.c diff --git a/drivers/mempool/octeontx/Makefile b/drivers/mempool/octeontx/Makefile index dfc373e62..a0547437a 100644 --- a/drivers/mempool/octeontx/Makefile +++ b/drivers/mempool/octeontx/Makefile @@ -20,6 +20,7 @@ LIBABIVER := 1 SRCS-$(CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL) += octeontx_ssovf.c SRCS-$(CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL) += octeontx_mbox.c SRCS-$(CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL) += octeontx_fpavf.c +SRCS-$(CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL) += octeontx_timvf.c SRCS-$(CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL) += rte_mempool_octeontx.c ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y) diff --git a/drivers/mempool/octeontx/meson.build b/drivers/mempool/octeontx/meson.build index 1e894a56b..c938436c9 100644 --- a/drivers/mempool/octeontx/meson.build +++ b/drivers/mempool/octeontx/meson.build @@ -4,6 +4,7 @@ sources = files('octeontx_ssovf.c', 'octeontx_mbox.c', 'octeontx_fpavf.c', + 'octeontx_timvf.c', 'rte_mempool_octeontx.c' ) diff --git a/drivers/mempool/octeontx/octeontx_mbox.h b/drivers/mempool/octeontx/octeontx_mbox.h index 1b056071a..7fcc9950f 100644 --- a/drivers/mempool/octeontx/octeontx_mbox.h +++ b/drivers/mempool/octeontx/octeontx_mbox.h @@ -21,6 +21,11 @@ enum octeontx_ssovf_type { OCTEONTX_SSO_HWS, /* SSO hardware workslot vf */ }; +struct octeontx_timvf_info { + uint16_t domain; /* Domain id */ + uint8_t total_timvfs; /* Total timvf available in domain */ +}; + struct octeontx_mbox_hdr { uint16_t vfid; /* VF index or pf resource index local to the domain */ uint8_t coproc; /* Coprocessor id */ @@ -32,5 +37,7 @@ int octeontx_ssovf_info(struct octeontx_ssovf_info *info); void *octeontx_ssovf_bar(enum octeontx_ssovf_type, uint8_t id, uint8_t bar); int octeontx_ssovf_mbox_send(struct octeontx_mbox_hdr *hdr, void *txdata, uint16_t txlen, void *rxdata, uint16_t rxlen); +int octeontx_timvf_info(struct octeontx_timvf_info *info); +void *octeontx_timvf_bar(uint8_t id, uint8_t bar); #endif /* __OCTEONTX_MBOX_H__ */ diff --git a/drivers/mempool/octeontx/octeontx_timvf.c b/drivers/mempool/octeontx/octeontx_timvf.c new file mode 100644 index 000000000..b20743a33 --- /dev/null +++ b/drivers/mempool/octeontx/octeontx_timvf.c @@ -0,0 +1,145 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright(c) 2017 Cavium, Inc + */ + +#include +#include +#include +#include + +#include "octeontx_mbox.h" +#include "octeontx_pool_logs.h" + +#ifndef PCI_VENDOR_ID_CAVIUM +#define PCI_VENDOR_ID_CAVIUM (0x177D) +#endif + +#define PCI_DEVICE_ID_OCTEONTX_TIM_VF (0xA051) +#define TIM_MAX_RINGS (64) + +struct timvf_res { + uint16_t domain; + uint16_t vfid; + void *bar0; + void *bar2; + void *bar4; +}; + +struct timdev { + uint8_t total_timvfs; + struct timvf_res rings[TIM_MAX_RINGS]; +}; + +static struct timdev tdev; + +int +octeontx_timvf_info(struct octeontx_timvf_info *tinfo) +{ + int i; + struct octeontx_ssovf_info info; + + if (tinfo == NULL) + return -EINVAL; + + if (!tdev.total_timvfs) + return -ENODEV; + + if (octeontx_ssovf_info(&info) < 0) + return -EINVAL; + + for (i = 0; i < tdev.total_timvfs; i++) { + if (info.domain != tdev.rings[i].domain) { + mbox_log_err("GRP error, vfid=%d/%d domain=%d/%d %p", + i, tdev.rings[i].vfid, + info.domain, tdev.rings[i].domain, + tdev.rings[i].bar0); + return -EINVAL; + } + } + + tinfo->total_timvfs = tdev.total_timvfs; + tinfo->domain = info.domain; + return 0; +} + +void* +octeontx_timvf_bar(uint8_t id, uint8_t bar) +{ + if (rte_eal_process_type() != RTE_PROC_PRIMARY) + return NULL; + + if (id > tdev.total_timvfs) + return NULL; + + switch (bar) { + case 0: + return tdev.rings[id].bar0; + case 4: + return tdev.rings[id].bar4; + default: + return NULL; + } +} + +static int +timvf_probe(struct rte_pci_driver *pci_drv, struct rte_pci_device *pci_dev) +{ + uint64_t val; + uint16_t vfid; + struct timvf_res *res; + + RTE_SET_USED(pci_drv); + + /* For secondary processes, the primary has done all the work */ + if (rte_eal_process_type() != RTE_PROC_PRIMARY) + return 0; + + if (pci_dev->mem_resource[0].addr == NULL || + pci_dev->mem_resource[4].addr == NULL) { + mbox_log_err("Empty bars %p %p", + pci_dev->mem_resource[0].addr, + pci_dev->mem_resource[4].addr); + return -ENODEV; + } + + val = rte_read64((uint8_t *)pci_dev->mem_resource[0].addr + 0x100); + vfid = (val >> 23) & 0xff; + if (vfid >= TIM_MAX_RINGS) { + mbox_log_err("Invalid vfid(%d/%d)", vfid, TIM_MAX_RINGS); + return -EINVAL; + } + + res = &tdev.rings[tdev.total_timvfs]; + res->vfid = vfid; + res->bar0 = pci_dev->mem_resource[0].addr; + res->bar2 = pci_dev->mem_resource[2].addr; + res->bar4 = pci_dev->mem_resource[4].addr; + res->domain = (val >> 7) & 0xffff; + tdev.total_timvfs++; + rte_wmb(); + + mbox_log_dbg("Domain=%d VFid=%d bar0 %p total_timvfs=%d", res->domain, + res->vfid, pci_dev->mem_resource[0].addr, + tdev.total_timvfs); + return 0; +} + + +static const struct rte_pci_id pci_timvf_map[] = { + { + RTE_PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, + PCI_DEVICE_ID_OCTEONTX_TIM_VF) + }, + { + .vendor_id = 0, + }, +}; + +static struct rte_pci_driver pci_timvf = { + .id_table = pci_timvf_map, + .drv_flags = RTE_PCI_DRV_NEED_MAPPING | RTE_PCI_DRV_IOVA_AS_VA, + .probe = timvf_probe, + .remove = NULL, +}; + +RTE_PMD_REGISTER_PCI(octeontx_timvf, pci_timvf); diff --git a/drivers/mempool/octeontx/rte_mempool_octeontx_version.map b/drivers/mempool/octeontx/rte_mempool_octeontx_version.map index fe8cdeca0..91e0a3a93 100644 --- a/drivers/mempool/octeontx/rte_mempool_octeontx_version.map +++ b/drivers/mempool/octeontx/rte_mempool_octeontx_version.map @@ -5,5 +5,8 @@ DPDK_17.11 { octeontx_ssovf_bar; octeontx_ssovf_mbox_send; + octeontx_timvf_info; + octeontx_timvf_bar; + local: *; }; -- 2.16.3