From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0084.outbound.protection.outlook.com [104.47.32.84]) by dpdk.org (Postfix) with ESMTP id 125C41B1AB for ; Tue, 16 Jan 2018 15:29:16 +0100 (CET) Received: from BN3PR03CA0075.namprd03.prod.outlook.com (10.167.1.163) by MWHPR03MB2702.namprd03.prod.outlook.com (10.168.207.136) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.407.7; Tue, 16 Jan 2018 14:29:15 +0000 Received: from BL2FFO11FD022.protection.gbl (2a01:111:f400:7c09::171) by BN3PR03CA0075.outlook.office365.com (2a01:111:e400:7a4d::35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.407.7 via Frontend Transport; Tue, 16 Jan 2018 14:29:15 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; NXP1.onmicrosoft.com; dkim=none (message not signed) header.d=none;NXP1.onmicrosoft.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BL2FFO11FD022.mail.protection.outlook.com (10.173.161.101) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.345.12 via Frontend Transport; Tue, 16 Jan 2018 14:29:15 +0000 Received: from b27504-OptiPlex-790.ap.freescale.net (b27504-OptiPlex-790.ap.freescale.net [10.232.132.60]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id w0GESqAH024963; Tue, 16 Jan 2018 07:29:13 -0700 From: Nipun Gupta To: CC: , , Date: Wed, 17 Jan 2018 02:13:59 +0530 Message-ID: <1516135443-10509-7-git-send-email-nipun.gupta@nxp.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1516135443-10509-1-git-send-email-nipun.gupta@nxp.com> References: <20171215130828.14218-1-sunil.kori@nxp.com> <1516135443-10509-1-git-send-email-nipun.gupta@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131605865558371984; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(39860400002)(396003)(39380400002)(346002)(376002)(2980300002)(1109001)(1110001)(339900001)(199004)(189003)(26005)(97736004)(47776003)(2906002)(296002)(316002)(59450400001)(68736007)(76176011)(51416003)(305945005)(2351001)(356003)(16586007)(54906003)(106466001)(105606002)(86362001)(6916009)(2950100002)(104016004)(6666003)(5660300001)(81166006)(48376002)(50226002)(8676002)(36756003)(8936002)(53936002)(8656006)(50466002)(4326008)(85426001)(498600001)(77096006)(81156014); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR03MB2702; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BL2FFO11FD022; 1:vVGeh5kDL7JTMBNPcr2lPoJ7Rfl+P9SYBb5TZialjwt6paA5UDhvW+cYo3Z1m6CgvLJMcTnb0335F9K1+Ay7BGB2NHcBJG5WhKxUHHyOKpFOL0mcDobjxRmorad4iIJq MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 136e2ad6-cf40-477e-ee90-08d55ced856d X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(5600026)(4604075)(2017052603307); SRVR:MWHPR03MB2702; X-Microsoft-Exchange-Diagnostics: 1; MWHPR03MB2702; 3:CXNWNvls0uXgyXn53qc470CEeFYim0sfTIWbWJ2AHbXux0VGU4Kq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MYuQJ9Z5wGoYfMK+VYj3O5YKpkZAYGFX3I6wldssTblcWNDIMMHYh+VAJh8s8SB+KFuMfoMphmzhKhamMinFBoVzajxrgx7p3pxBUv3NZvbA5tAInSkDB0pr7P+AlnhjYG6eT6Tq6oeDXzkvXBX555CwP9t9L2Qcf/wzkr9XD17uCi4SUBfUaNXSIwD4F7ZOZ5Df+1U/7ItkKqO0OS8bc9xIBU X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6095135)(2401047)(5005006)(8121501046)(93006095)(93001095)(3231023)(944501161)(10201501046)(3002001)(6055026)(6096035)(20161123563025)(20161123556025)(20161123565025)(20161123561025)(201703131430075)(201703131520075)(201703131448075)(201703131433075)(201703151042153)(20161123559100)(201708071742011); SRVR:MWHPR03MB2702; BCL:0; PCL:0; RULEID:(100000803101)(100110400095)(400006); SRVR:MWHPR03MB2702; X-Forefront-PRVS: 0554B1F54F X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR03MB2702; 23:cBfkJcGIPgVu941Xdb5YkdAQJCy8ba9DpAbnT2wJ1?= =?us-ascii?Q?psFG0RWNOVpA8wfG5aCOPFaT37LPVliX5aGl2fnWrAJq7OGaCBlnXj4mECZB?= =?us-ascii?Q?YR2XcROd5ZtDdZKBjpH5BtluVne33aIH2pr5SSsd3M1ia9WRoHReEnZaS8Mg?= =?us-ascii?Q?kmMpTP+Ugv8P9stoY2CW66+4HTCvJ7sx6yMmU8DkJ62YWQpD2Vv6qOVxqXAH?= =?us-ascii?Q?gCKrrGjYhtAu4/HHg7dyJwywlApjEKGudnRB6kXQ3I8yqZJKad7tqQO1P289?= =?us-ascii?Q?0mPJo3CFhMvCL3sG15k8FplSVpaqdKcx53HD6CzCT8Ivp722+2b9d1jRlWSl?= =?us-ascii?Q?rXAvachx0aopiXXSg3mjmqMAmR9kQSCu7nEHDKYn0IjvGm/CMpShsh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Ppylqn0N8PRkSvTkAi6Z4ysEPnVsp4ISi0pySUiIlSCZTbh2f4o/GDTNphKbvMUbfOXP8w2JLQh2yXV4a8LgdDXuGGdsDT5qkVT8uZLSBW3/zE3t1G7Gic2VPb9zl7Pebsp6lHcVXB0GKqPGo1MrNzHZVkovRb/68ZW+IX7Vhn7fYAAOIC8psGp3ZaqH8cujXs335qAtTZn9noWqOm7fhnApYgKQHP1atrBkly9SmatBIcl5spDAA=; 5:O7hVajRDrKbV47WDlAURznVjTlX6FZyODg2trRcy4Gy9cpWC+a4PTjg5+k5A4tk7TYR8fmeASkKkJAYFGomfL0/bwOt+8Fyp/W57L2oYSlxsp7rHaDqhROeyb6dT6WaXwvSD4eDPiFCYx2cgI+3nVTn1I/kyWhUM0BVpf8G7C1k=; 24:pXZXN2g7G2pgK3qa/0IeNbUvOZKQRU9i4f4zNCvnL5Oc5nnnVjOmOW4eTeyX9JMumO9bFZtpTNPzPKoBch3Dng0orK0kaLP39Ad2lhAsUFA=; 7:e/S71cX7PfwOh6v3xqobLxqlTYF60IMM6hbmwb8rNwk6PSfA+Nm6/Ga2P4xzHeVlesLikiFo+H22fRMY2XN8lfoza19lNI8+whlu7ZpaqPsXK7v8TDS8Jb3231cYnMIJLwqLvGe26ABJFkCAFkRLJjhRvP8774HgWRKNyn/LoTfqARaUduWXeK7G6SccOkcdvy+DW8m2UnELcGQlakz3WUYdHtp7h2q/GPKpsJF1592YdPpe77oO69fg+gzM8Me0 SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Jan 2018 14:29:15.6811 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 136e2ad6-cf40-477e-ee90-08d55ced856d X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR03MB2702 Subject: [dpdk-dev] [PATCH 06/10 v4] event/dpaa: add event queue config get/set 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: , X-List-Received-Date: Tue, 16 Jan 2018 14:29:17 -0000 From: Sunil Kumar Kori Signed-off-by: Sunil Kumar Kori Acked-by: Hemant Agrawal --- drivers/event/dpaa/dpaa_eventdev.c | 47 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/drivers/event/dpaa/dpaa_eventdev.c b/drivers/event/dpaa/dpaa_eventdev.c index ba9b814..e7548e5 100644 --- a/drivers/event/dpaa/dpaa_eventdev.c +++ b/drivers/event/dpaa/dpaa_eventdev.c @@ -201,7 +201,51 @@ return 0; } +static void +dpaa_event_queue_def_conf(struct rte_eventdev *dev, uint8_t queue_id, + struct rte_event_queue_conf *queue_conf) +{ + EVENTDEV_DRV_FUNC_TRACE(); + + RTE_SET_USED(dev); + RTE_SET_USED(queue_id); + + memset(queue_conf, 0, sizeof(struct rte_event_queue_conf)); + queue_conf->schedule_type = RTE_SCHED_TYPE_PARALLEL; + queue_conf->priority = RTE_EVENT_DEV_PRIORITY_HIGHEST; +} + +static int +dpaa_event_queue_setup(struct rte_eventdev *dev, uint8_t queue_id, + const struct rte_event_queue_conf *queue_conf) +{ + struct dpaa_eventdev *priv = dev->data->dev_private; + struct dpaa_eventq *evq_info = &priv->evq_info[queue_id]; + + EVENTDEV_DRV_FUNC_TRACE(); + + switch (queue_conf->schedule_type) { + case RTE_SCHED_TYPE_PARALLEL: + case RTE_SCHED_TYPE_ATOMIC: + break; + case RTE_SCHED_TYPE_ORDERED: + EVENTDEV_DRV_ERR("Schedule type is not supported."); + return -1; + } + evq_info->event_queue_cfg = queue_conf->event_queue_cfg; + evq_info->event_queue_id = queue_id; + + return 0; +} +static void +dpaa_event_queue_release(struct rte_eventdev *dev, uint8_t queue_id) +{ + EVENTDEV_DRV_FUNC_TRACE(); + + RTE_SET_USED(dev); + RTE_SET_USED(queue_id); +} static const struct rte_eventdev_ops dpaa_eventdev_ops = { .dev_infos_get = dpaa_event_dev_info_get, @@ -209,6 +253,9 @@ .dev_start = dpaa_event_dev_start, .dev_stop = dpaa_event_dev_stop, .dev_close = dpaa_event_dev_close, + .queue_def_conf = dpaa_event_queue_def_conf, + .queue_setup = dpaa_event_queue_setup, + .queue_release = dpaa_event_queue_release, .timeout_ticks = dpaa_event_dequeue_timeout_ticks, }; -- 1.9.1