From patchwork Tue Jun 28 12:05:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Balasubramanian Manoharan X-Patchwork-Id: 71074 Delivered-To: patch@linaro.org Received: by 10.140.28.4 with SMTP id 4csp1547651qgy; Tue, 28 Jun 2016 05:07:24 -0700 (PDT) X-Received: by 10.13.244.132 with SMTP id d126mr388917ywf.145.1467115644475; Tue, 28 Jun 2016 05:07:24 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id n78si22259343qkl.217.2016.06.28.05.07.24; Tue, 28 Jun 2016 05:07:24 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 72ED76886C; Tue, 28 Jun 2016 12:07:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id C7ABE6886F; Tue, 28 Jun 2016 12:06:48 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 9DFD86886D; Tue, 28 Jun 2016 12:06:44 +0000 (UTC) Received: from mail-pf0-f181.google.com (mail-pf0-f181.google.com [209.85.192.181]) by lists.linaro.org (Postfix) with ESMTPS id ADDA768577 for ; Tue, 28 Jun 2016 12:06:21 +0000 (UTC) Received: by mail-pf0-f181.google.com with SMTP id c2so6337333pfa.2 for ; Tue, 28 Jun 2016 05:06:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=ZFNEQZBMAK7qbQInq42xKLdiVmAfGOZ4Ajd//yLtWTE=; b=XaDz0E+hGl3Q3m3RB3sjP7hPrUCOQkN81uxSxoc5wXrY8PrPOc0p9cOv/PaRo5/toc wk2+wCwEGNEozWe23folyplBx7kfhOw7bUYs/MRhBOuC+glJJ2nhPazOmRiEtNa6vGeI vrXNpQc8n1rq7hVc01gYkcRZ7daRqej1kF2Scz1MKb/fHwmMhVbN23iL7xBBo4y/VlZW rrunAELo5PAqmQktPFIf3hY9usM48s7qr4bXypGTm7I2Ci3TdhZuN2dWrV4/2EaOqOlH 6Tb7wnIg5QBSwERBfkgAtE2DVTYF1KUdijY/R5hXi1qjxW0dRjejS8Vfn2+0rZ3oR+Aw FKfQ== X-Gm-Message-State: ALyK8tK//c4iRtYhLJfasF2iowkd5y3HavJIm2LH1slVdREp9w7Wj74TGZMcB5FZdCxog60EIJM= X-Received: by 10.98.27.141 with SMTP id b135mr1145518pfb.111.1467115580996; Tue, 28 Jun 2016 05:06:20 -0700 (PDT) Received: from localhost.localdomain ([122.166.219.57]) by smtp.gmail.com with ESMTPSA id i68sm6437057pfe.64.2016.06.28.05.06.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 28 Jun 2016 05:06:20 -0700 (PDT) From: Balasubramanian Manoharan To: lng-odp@lists.linaro.org Date: Tue, 28 Jun 2016 17:35:56 +0530 Message-Id: <1467115556-8187-3-git-send-email-bala.manoharan@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1467115556-8187-1-git-send-email-bala.manoharan@linaro.org> References: <1467115556-8187-1-git-send-email-bala.manoharan@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH/API-NEXTv2 3/3] example: traffic_mngr: support for pktio interface in odp_tm_egress_t struct X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Example modifications to support pktio interface in TM system Signed-off-by: Balasubramanian Manoharan --- test/validation/traffic_mngr/traffic_mngr.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/validation/traffic_mngr/traffic_mngr.c b/test/validation/traffic_mngr/traffic_mngr.c index 0645370..2fcf2fa 100644 --- a/test/validation/traffic_mngr/traffic_mngr.c +++ b/test/validation/traffic_mngr/traffic_mngr.c @@ -323,7 +323,7 @@ static odp_pktio_t pktios[MAX_NUM_IFACES]; static odp_pktin_queue_t pktins[MAX_NUM_IFACES]; static odp_pktout_queue_t pktouts[MAX_NUM_IFACES]; static odp_pktin_queue_t rcv_pktin; -static odp_pktout_queue_t xmt_pktout; +static odp_pktio_t xmt_pktio; static odph_ethaddr_t src_mac; static odph_ethaddr_t dst_mac; @@ -543,7 +543,7 @@ static int open_pktios(void) } if (2 <= num_ifaces) { - xmt_pktout = pktouts[0]; + xmt_pktio = pktios[0]; rcv_pktin = pktins[1]; ret = odp_pktio_start(pktios[1]); if (ret != 0) { @@ -551,7 +551,7 @@ static int open_pktios(void) return -1; } } else { - xmt_pktout = pktouts[0]; + xmt_pktio = pktios[0]; rcv_pktin = pktins[0]; } @@ -1627,7 +1627,7 @@ static int create_tm_system(void) } egress.egress_kind = ODP_TM_EGRESS_PKT_IO; - egress.pktout = xmt_pktout; + egress.pktio = xmt_pktio; snprintf(tm_name, sizeof(tm_name), "TM_system_%u", num_odp_tm_systems); odp_tm = odp_tm_create(tm_name, &requirements, &egress);