From patchwork Fri Sep 21 11:46:05 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hemant Agrawal X-Patchwork-Id: 147246 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp713646ljw; Fri, 21 Sep 2018 04:48:42 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZH/nlXGMt7CdfZZnt19Tn2/HrRjC5GQEYr90lJeYiD3dUc1vPRkQ9FQhjNmfvpmT5jSz4x X-Received: by 2002:a1c:85cb:: with SMTP id h194-v6mr6479746wmd.54.1537530522242; Fri, 21 Sep 2018 04:48:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537530522; cv=none; d=google.com; s=arc-20160816; b=Ju3oxDzk9f2zjaGyIhmyvXncgBICI6KArMrX3bUZsSAZhi3e4phCkXJaKfCI/c845V egRe54kt1gT1v7ZCPAv076KLVpYsrfmP/K0y1QCJZYYUpUn/30LfL5a8sIF4rYp+YW+d Xf/plryTm2FraCJDLVmfu5ZITe+ygouG9j+Ym8XEmleGp970BGUGwi49JxfPKBWsu+5V olx6wrmRYp8OubCoLD0Z8cS0kB0C9axM+uXkYWz/KofkZqdAblE8cH1jHWS0a5PJ4j1h i4ESMEktmmfZJmvnuviICGYY1ERZsxsdunqId313JFohkwRcVpUSKUvgkVtKQN+K2z5I R0Zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:cc:to:from; bh=AN2Tcq9fKOjUryhMgwvTdq3Jd1mA6e06DQp29rc6mYo=; b=Ze/jDU2t3rGrKXT7pvw4VjkbMJN60oRBtoCWyOn+ze2KhId4M5aSn1xWXOCncvq8pt isQxrVizbUfysE4DjxJVR4I1aq16h3uxy4KhY7JNXpT3egHnbAY5z4vKS9nI1dlkSLlf BoU1zwpVGhjfcALlhpATeTjZVu7Pcp5rG9TsQJ3qIqOd7kZ9uCa5P+CTtVQg7ADfOY+E mswHL4WBBVgYwYFGT6bh4TDF+Gm327EjGKLMz+taSzOdFzjXgCTZrxWPesZYO1bqtfSg F7qztHOm5qMmjHQtTikeC7OuVbdmUte0UCBXBF/8qIxyeO6p2kaTq7SDrNya5QQvbDep TUsQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id 4-v6si452120wrh.71.2018.09.21.04.48.42; Fri, 21 Sep 2018 04:48:42 -0700 (PDT) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 932964D3A; Fri, 21 Sep 2018 13:48:23 +0200 (CEST) Received: from inva020.nxp.com (inva020.nxp.com [92.121.34.13]) by dpdk.org (Postfix) with ESMTP id 099952BD3 for ; Fri, 21 Sep 2018 13:48:17 +0200 (CEST) Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id E09471A02CA; Fri, 21 Sep 2018 13:48:16 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 0B9FF1A02BE; Fri, 21 Sep 2018 13:48:15 +0200 (CEST) Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.134.28]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id 15DA7402E6; Fri, 21 Sep 2018 19:48:11 +0800 (SGT) From: Hemant Agrawal To: dev@dpdk.org Cc: jerin.jacob@caviumnetworks.com, Hemant Agrawal Date: Fri, 21 Sep 2018 17:16:05 +0530 Message-Id: <1537530366-4722-4-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1537530366-4722-1-git-send-email-hemant.agrawal@nxp.com> References: <1535609039-10869-1-git-send-email-hemant.agrawal@nxp.com> <1537530366-4722-1-git-send-email-hemant.agrawal@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Subject: [dpdk-dev] [PATCH v2 4/5] event/dpaa2: support Max event port value 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" This shall be number of available cores. Signed-off-by: Hemant Agrawal --- drivers/event/dpaa2/dpaa2_eventdev.c | 3 +++ 1 file changed, 3 insertions(+) -- 2.7.4 diff --git a/drivers/event/dpaa2/dpaa2_eventdev.c b/drivers/event/dpaa2/dpaa2_eventdev.c index 4b56e2e..456b446 100644 --- a/drivers/event/dpaa2/dpaa2_eventdev.c +++ b/drivers/event/dpaa2/dpaa2_eventdev.c @@ -293,6 +293,9 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev, dev_info->max_event_priority_levels = DPAA2_EVENT_MAX_EVENT_PRIORITY_LEVELS; dev_info->max_event_ports = rte_fslmc_get_device_count(DPAA2_IO); + /* we only support dpio upto number of cores*/ + if (dev_info->max_event_ports > rte_lcore_count()) + dev_info->max_event_ports = rte_lcore_count(); dev_info->max_event_port_dequeue_depth = DPAA2_EVENT_MAX_PORT_DEQUEUE_DEPTH; dev_info->max_event_port_enqueue_depth =