From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0083.outbound.protection.outlook.com [104.47.33.83]) by dpdk.org (Postfix) with ESMTP id A22171B3A1 for ; Wed, 18 Oct 2017 10:46:50 +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=SDbk5AQVw6vLbZug2QuoJxqKHrZsWiOKxJ/tVIWGeuE=; b=jwH+q935ub/OkNVqfXhtsWBgSauACpnmzuG8NUXPPWvDJzJvr16IaMOHPbsJJ2y6nKBWIVbTIEVOjHmf+ki0RuVLfhRG93XNOSS11qhrZLlvKu0ro8XyuIW7KmUD9HSvLx8WfGi504EMzg8Sp6eMK0k1BixWt7VASn5ZTjQTIKM= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from PBHAGAVATULA-LT.caveonetworks.com (111.93.218.67) by BN6PR07MB3457.namprd07.prod.outlook.com (10.161.153.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Wed, 18 Oct 2017 08:46:47 +0000 From: Pavan Nikhilesh To: jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, nikhil.rao@intel.com Cc: dev@dpdk.org, Pavan Nikhilesh Date: Wed, 18 Oct 2017 14:15:41 +0530 Message-Id: <1508316342-17781-2-git-send-email-pbhagavatula@caviumnetworks.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1508316342-17781-1-git-send-email-pbhagavatula@caviumnetworks.com> References: <1508230393-27018-1-git-send-email-pbhagavatula@caviumnetworks.com> <1508316342-17781-1-git-send-email-pbhagavatula@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: BMXPR01CA0048.INDPRD01.PROD.OUTLOOK.COM (10.174.214.34) To BN6PR07MB3457.namprd07.prod.outlook.com (10.161.153.20) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d4d17d07-0762-4ec7-5c86-08d51604c589 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254152)(2017052603199)(201703131423075)(201703031133081)(201702281549075); SRVR:BN6PR07MB3457; X-Microsoft-Exchange-Diagnostics: 1; BN6PR07MB3457; 3:O14wEYhpM7uzeMA3rZ4NGljU5M8UNlgnimyfBVxB3kfO+4VLaK1wSiyJ6Wk9SifO86DXhb7SL64rbhXr/LZZ0h8B16W8RYdXejgpywqL1o7+TqDRVt8AVsO4c7s+1c9ylpxzxe1erl9o6s+uLOj3ZPYmUVAQb+t1LNxHo2elGM81rXPRx+MdQTZqGzRD0XoBVXo3nhrKtZIctEedVFw2aAQ4GqsXyuIVb8oHWHSk2jMJEAA8+q93Psgm2EEUrIFM; 25:M1h9PvlhtS37hxZmQ9P4XaGngMq2+orDcm+Umm9NnJSnkD66EGQnsL+obgA/6cymzltLTlHScVwAt+sfRz0ko573vp5Z3e6Ns9J7rUfDzvfFrFk0KWMRUEt+fHdhOmQ+9AgBwrKXgQfvC+wLErJi7broJTTVxr7t9/mm8izXJAP9tJDwFphjW2ghCz9Ed5CbiW6BbFlncrSXcimAPeMmgMZ2EE7in3LPUCSxYorxtBlJa3ONSbBMlmAdqs4xAprDK9TJr5Mo+HNSCN7IdcLHJ5SbpG9le3W2rncsfjj4vp1oL9HYWrsUsZ67AP/3aeGLAvVjno81eico6Dts9qtwzg==; 31:BrlDk04WFIQUfBd08j418wk4UTt3MI+Col7Zm3G4No9jm28piP1bfIfI5Ecc+IhZR4MRIYzmw3aqIjbFwCsaml9RQaVj/nEmgrBSBZOXTKGXmHrKYgrJsKNKfQpgMofKDox1FJJVrdF1Jv67u49L1oMfKFUqgkHzdu1C/JiwJ08tWxG+UjirGIB5L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Test: UriScan:(228905959029699); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(8121501046)(5005006)(10201501046)(93006095)(100000703101)(100105400095)(3002001)(6041248)(20161123562025)(20161123560025)(20161123555025)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123558100)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:BN6PR07MB3457; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:BN6PR07MB3457; X-Forefront-PRVS: 0464DBBBC4 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(346002)(376002)(189002)(199003)(47776003)(107886003)(478600001)(4326008)(36756003)(33646002)(8936002)(81166006)(105586002)(5009440100003)(6116002)(81156014)(50986999)(53416004)(101416001)(68736007)(7736002)(72206003)(76176999)(16526018)(305945005)(316002)(3846002)(106356001)(8676002)(189998001)(50226002)(16586007)(5003940100001)(50466002)(97736004)(48376002)(6506006)(6486002)(69596002)(2906002)(6666003)(2950100002)(25786009)(6512007)(42882006)(66066001)(53936002)(5660300001)(42262002)(309714004); DIR:OUT; SFP:1101; SCL:1; SRVR:BN6PR07MB3457; H:PBHAGAVATULA-LT.caveonetworks.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN6PR07MB3457; 23:2gEwH7hCiDPTYWg1zYyc2OxKtzWIFGn7g6LANjD4t?= =?us-ascii?Q?i+3VAiIg4cXK4E99DRSP6T9R/CEpi3UE8DJ85CnRCyCWRLybAoc8Q9iw22Ig?= =?us-ascii?Q?HMjU5ihONsdn5ojoOMmhF4B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FhBEzhf+DNEM0lUBIkJ9zhdfmwpm+KGmkhCbtZNCL4StJxLt1WN+OYrIhtfFmZv/vojsnD57I1FLbE= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Oct 2017 08:46:47.6493 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR07MB3457 Subject: [dpdk-dev] [PATCH v2 2/3] event/octeontx: add support for event Rx adapter 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: Wed, 18 Oct 2017 08:46:51 -0000 Add Rx adapter queue add and delete API for both generic eth_devices as well as HW backed eth_octeontx which supports direct event injection to event device. The HW injected event needs to be converted into mbuf, previously this was done in eth_octeontx during rx_burst now it is moved to event_octeontx as events from Rx adapter are dequeued directly from event device. Signed-off-by: Pavan Nikhilesh Reviewed by: Nikhil Rao --- drivers/event/octeontx/Makefile | 1 + drivers/event/octeontx/ssovf_evdev.c | 126 ++++++++++++++++++++++++++++++++++ drivers/event/octeontx/ssovf_evdev.h | 1 + drivers/event/octeontx/ssovf_worker.h | 31 ++++++++- 4 files changed, 156 insertions(+), 3 deletions(-) diff --git a/drivers/event/octeontx/Makefile b/drivers/event/octeontx/Makefile index 08fc167..7f7b9b3 100644 --- a/drivers/event/octeontx/Makefile +++ b/drivers/event/octeontx/Makefile @@ -39,6 +39,7 @@ LIB = librte_pmd_octeontx_ssovf.a CFLAGS += $(WERROR_FLAGS) CFLAGS += -I$(RTE_SDK)/drivers/mempool/octeontx/ +CFLAGS += -I$(RTE_SDK)/drivers/net/octeontx/ EXPORT_MAP := rte_pmd_octeontx_ssovf_version.map diff --git a/drivers/event/octeontx/ssovf_evdev.c b/drivers/event/octeontx/ssovf_evdev.c index d829b49..7bdc85d 100644 --- a/drivers/event/octeontx/ssovf_evdev.c +++ b/drivers/event/octeontx/ssovf_evdev.c @@ -36,6 +36,8 @@ #include #include #include +#include +#include #include #include #include @@ -395,6 +397,123 @@ ssows_dump(struct ssows *ws, FILE *f) fprintf(f, "\tpwqp=0x%"PRIx64"\n", val); } +static int +ssovf_eth_rx_adapter_caps_get(const struct rte_eventdev *dev, + const struct rte_eth_dev *eth_dev, uint32_t *caps) +{ + int ret; + RTE_SET_USED(dev); + + ret = strncmp(eth_dev->data->name, "eth_octeontx", 12); + if (ret) + *caps = RTE_EVENT_ETH_RX_ADAPTER_SW_CAP; + else + *caps = RTE_EVENT_ETH_RX_ADAPTER_CAP_INTERNAL_PORT; + + return 0; +} + +static int +ssovf_eth_rx_adapter_queue_add(const struct rte_eventdev *dev, + const struct rte_eth_dev *eth_dev, int32_t rx_queue_id, + const struct rte_event_eth_rx_adapter_queue_conf *queue_conf) +{ + int ret = 0; + const struct octeontx_nic *nic = eth_dev->data->dev_private; + pki_mod_qos_t pki_qos; + RTE_SET_USED(dev); + + ret = strncmp(eth_dev->data->name, "eth_octeontx", 12); + if (ret) + return -EINVAL; + + if (rx_queue_id >= 0) + return -EINVAL; + + if (queue_conf->ev.sched_type == RTE_SCHED_TYPE_PARALLEL) + return -ENOTSUP; + + memset(&pki_qos, 0, sizeof(pki_mod_qos_t)); + + pki_qos.port_type = 0; + pki_qos.index = 0; + pki_qos.mmask.f_tag_type = 1; + pki_qos.mmask.f_port_add = 1; + pki_qos.mmask.f_grp_ok = 1; + pki_qos.mmask.f_grp_bad = 1; + pki_qos.mmask.f_grptag_ok = 1; + pki_qos.mmask.f_grptag_bad = 1; + + pki_qos.tag_type = queue_conf->ev.sched_type; + pki_qos.qos_entry.port_add = 0; + pki_qos.qos_entry.ggrp_ok = queue_conf->ev.queue_id; + pki_qos.qos_entry.ggrp_bad = queue_conf->ev.queue_id; + pki_qos.qos_entry.grptag_bad = 0; + pki_qos.qos_entry.grptag_ok = 0; + + ret = octeontx_pki_port_modify_qos(nic->port_id, &pki_qos); + if (ret < 0) + ssovf_log_err("failed to modify QOS, port=%d, q=%d", + nic->port_id, queue_conf->ev.queue_id); + + return ret; +} + +static int +ssovf_eth_rx_adapter_queue_del(const struct rte_eventdev *dev, + const struct rte_eth_dev *eth_dev, int32_t rx_queue_id) +{ + int ret = 0; + const struct octeontx_nic *nic = eth_dev->data->dev_private; + pki_del_qos_t pki_qos; + RTE_SET_USED(dev); + RTE_SET_USED(rx_queue_id); + + ret = strncmp(eth_dev->data->name, "eth_octeontx", 12); + if (ret) + return -EINVAL; + + pki_qos.port_type = 0; + pki_qos.index = 0; + memset(&pki_qos, 0, sizeof(pki_del_qos_t)); + ret = octeontx_pki_port_delete_qos(nic->port_id, &pki_qos); + if (ret < 0) + ssovf_log_err("Failed to delete QOS port=%d, q=%d", + nic->port_id, queue_conf->ev.queue_id); + return ret; +} + +static int +ssovf_eth_rx_adapter_start(const struct rte_eventdev *dev, + const struct rte_eth_dev *eth_dev) +{ + int ret; + const struct octeontx_nic *nic = eth_dev->data->dev_private; + RTE_SET_USED(dev); + + ret = strncmp(eth_dev->data->name, "eth_octeontx", 12); + if (ret) + return 0; + octeontx_pki_port_start(nic->port_id); + return 0; +} + + +static int +ssovf_eth_rx_adapter_stop(const struct rte_eventdev *dev, + const struct rte_eth_dev *eth_dev) +{ + int ret; + const struct octeontx_nic *nic = eth_dev->data->dev_private; + RTE_SET_USED(dev); + + ret = strncmp(eth_dev->data->name, "eth_octeontx", 12); + if (ret) + return 0; + octeontx_pki_port_stop(nic->port_id); + return 0; +} + static void ssovf_dump(struct rte_eventdev *dev, FILE *f) { @@ -488,6 +607,13 @@ static const struct rte_eventdev_ops ssovf_ops = { .port_link = ssovf_port_link, .port_unlink = ssovf_port_unlink, .timeout_ticks = ssovf_timeout_ticks, + + .eth_rx_adapter_caps_get = ssovf_eth_rx_adapter_caps_get, + .eth_rx_adapter_queue_add = ssovf_eth_rx_adapter_queue_add, + .eth_rx_adapter_queue_del = ssovf_eth_rx_adapter_queue_del, + .eth_rx_adapter_start = ssovf_eth_rx_adapter_start, + .eth_rx_adapter_stop = ssovf_eth_rx_adapter_stop, + .dump = ssovf_dump, .dev_start = ssovf_start, .dev_stop = ssovf_stop, diff --git a/drivers/event/octeontx/ssovf_evdev.h b/drivers/event/octeontx/ssovf_evdev.h index 933c5a3..bbce492 100644 --- a/drivers/event/octeontx/ssovf_evdev.h +++ b/drivers/event/octeontx/ssovf_evdev.h @@ -38,6 +38,7 @@ #include #include +#include #define EVENTDEV_NAME_OCTEONTX_PMD event_octeontx diff --git a/drivers/event/octeontx/ssovf_worker.h b/drivers/event/octeontx/ssovf_worker.h index 8dc1264..57a3c12 100644 --- a/drivers/event/octeontx/ssovf_worker.h +++ b/drivers/event/octeontx/ssovf_worker.h @@ -34,9 +34,11 @@ #include #include -#include "ssovf_evdev.h" #include +#include "ssovf_evdev.h" +#include "octeontx_rxtx.h" + enum { SSO_SYNC_ORDERED, SSO_SYNC_ATOMIC, @@ -50,6 +52,28 @@ enum { /* SSO Operations */ +static __rte_always_inline struct rte_mbuf * +ssovf_octeontx_wqe_to_pkt(uint64_t work, uint16_t port_id) +{ + struct rte_mbuf *mbuf; + octtx_wqe_t *wqe = (octtx_wqe_t *)(uintptr_t)work; + rte_prefetch_non_temporal(wqe); + + /* Get mbuf from wqe */ + mbuf = (struct rte_mbuf *)((uintptr_t)wqe - + OCTTX_PACKET_WQE_SKIP); + mbuf->packet_type = + ptype_table[wqe->s.w2.lcty][wqe->s.w2.lety][wqe->s.w2.lfty]; + mbuf->data_off = RTE_PTR_DIFF(wqe->s.w3.addr, mbuf->buf_addr); + mbuf->pkt_len = wqe->s.w1.len; + mbuf->data_len = mbuf->pkt_len; + mbuf->nb_segs = 1; + mbuf->ol_flags = 0; + mbuf->port = port_id; + rte_mbuf_refcnt_set(mbuf, 1); + return mbuf; +} + static __rte_always_inline uint16_t ssows_get_work(struct ssows *ws, struct rte_event *ev) { @@ -62,9 +86,10 @@ ssows_get_work(struct ssows *ws, struct rte_event *ev) ws->cur_tt = sched_type_queue & 0x3; ws->cur_grp = sched_type_queue >> 2; sched_type_queue = sched_type_queue << 38; - ev->event = sched_type_queue | (get_work0 & 0xffffffff); - ev->u64 = get_work1; + ev->u64 = get_work1 && ev->event_type == RTE_EVENT_TYPE_ETHDEV ? + (uint64_t)ssovf_octeontx_wqe_to_pkt(get_work1, + (ev->event >> 20) & 0xF) : get_work1; return !!get_work1; } -- 2.7.4