From patchwork Tue Jul 28 12:16:31 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Uvarov X-Patchwork-Id: 51588 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f200.google.com (mail-wi0-f200.google.com [209.85.212.200]) by patches.linaro.org (Postfix) with ESMTPS id A6DDF20323 for ; Tue, 28 Jul 2015 12:16:55 +0000 (UTC) Received: by wilm20 with SMTP id m20sf38089156wil.2 for ; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:date :message-id:subject:precedence:list-id:list-unsubscribe:list-archive :list-post:list-help:list-subscribe:mime-version:content-type :content-transfer-encoding:errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=nGHCBPXPjwWS+4ifBGmGA/EvlSaCx6S0EvZsjvoFRh0=; b=M179U5KfAPVLwjam5jgIFZAtlG8PAnfeczDFYxOEQTv47bVLlEoW460rzeEo2s89yc LhdB8EuSDp4jmLmNARObueXcfJMpNSeTFB4elROvyOrX7IC29JqWLay0w/COavG2Z3LA JWwGys8Ukkc5og7osE0jzNrvP+FByLaOIxSTXS4SYMprBSdF4mnu+WlMfV6lT3NnqMf+ /A55LrGKwsGQ3j90Y7fT8EsmFHm67te6qvJ7asUetxMrLVdkQbv1kkBccbUR3sd1TCAo b5RRIeQTSG7+agYXqjFAV6olqRsk98K90bwjPSbBcqS5PHrDW5PG68S3QGBQv9xeu3U/ xf5Q== X-Gm-Message-State: ALoCoQn49ElGSnrxNZF5KT5U3vWOQMGZk+yLz3ATDbAtGP88vG3RuJkpKm2yshQoMQSojJK82wzf X-Received: by 10.112.253.135 with SMTP id aa7mr13884578lbd.11.1438085814882; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.20.10 with SMTP id j10ls784643lae.6.gmail; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) X-Received: by 10.112.105.104 with SMTP id gl8mr32526272lbb.81.1438085814611; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) Received: from mail-la0-f51.google.com (mail-la0-f51.google.com. [209.85.215.51]) by mx.google.com with ESMTPS id pr5si18160050lbb.140.2015.07.28.05.16.54 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Jul 2015 05:16:54 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.51 as permitted sender) client-ip=209.85.215.51; Received: by laah7 with SMTP id h7so67334574laa.0 for ; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) X-Received: by 10.152.120.135 with SMTP id lc7mr31612093lab.41.1438085814135; Tue, 28 Jul 2015 05:16:54 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.7.198 with SMTP id l6csp2103798lba; Tue, 28 Jul 2015 05:16:53 -0700 (PDT) X-Received: by 10.140.129.216 with SMTP id 207mr51467502qhb.39.1438085812752; Tue, 28 Jul 2015 05:16:52 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id h77si25027798qhc.61.2015.07.28.05.16.52; Tue, 28 Jul 2015 05:16:52 -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; Received: by lists.linaro.org (Postfix, from userid 109) id EC13361C7A; Tue, 28 Jul 2015 12:16:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from ip-10-142-244-252.ec2.internal (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 12A99615B0; Tue, 28 Jul 2015 12:16: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 5496E6184A; Tue, 28 Jul 2015 12:16:46 +0000 (UTC) Received: from mail-wi0-f182.google.com (mail-wi0-f182.google.com [209.85.212.182]) by lists.linaro.org (Postfix) with ESMTPS id 66147610FF for ; Tue, 28 Jul 2015 12:16:41 +0000 (UTC) Received: by wibud3 with SMTP id ud3so178089865wib.1 for ; Tue, 28 Jul 2015 05:16:40 -0700 (PDT) X-Received: by 10.194.172.8 with SMTP id ay8mr64700191wjc.106.1438085800669; Tue, 28 Jul 2015 05:16:40 -0700 (PDT) Received: from localhost.localdomain ([87.120.178.39]) by smtp.gmail.com with ESMTPSA id m10sm18747270wib.17.2015.07.28.05.16.38 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 28 Jul 2015 05:16:39 -0700 (PDT) From: Maxim Uvarov To: lng-odp@lists.linaro.org Date: Tue, 28 Jul 2015 15:16:31 +0300 Message-Id: <1438085791-19726-1-git-send-email-maxim.uvarov@linaro.org> X-Mailer: git-send-email 1.9.1 X-Topics: patch Subject: [lng-odp] [PATCHv2] linux-generic: fix logic for calling pktio init and term functions X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: 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" X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: maxim.uvarov@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.51 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Signed-off-by: Maxim Uvarov Reviewed-by: Stuart Haslam --- v2: fix subject and typo. platform/linux-generic/odp_packet_io.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/platform/linux-generic/odp_packet_io.c b/platform/linux-generic/odp_packet_io.c index 2bfec52..f3a4543 100644 --- a/platform/linux-generic/odp_packet_io.c +++ b/platform/linux-generic/odp_packet_io.c @@ -74,7 +74,7 @@ int odp_pktio_init_global(void) } for (pktio_if = 0; pktio_if_ops[pktio_if]; ++pktio_if) { - if (!pktio_if_ops[pktio_if]->init) + if (pktio_if_ops[pktio_if]->init) if (pktio_if_ops[pktio_if]->init()) ODP_ERR("failed to initialized pktio type %d", pktio_if); @@ -91,9 +91,9 @@ int odp_pktio_term_global(void) int pktio_if; for (pktio_if = 0; pktio_if_ops[pktio_if]; ++pktio_if) { - if (!pktio_if_ops[pktio_if]->term) + if (pktio_if_ops[pktio_if]->term) if (pktio_if_ops[pktio_if]->term()) - ODP_ERR("failed to terminaye pktio type %d", + ODP_ERR("failed to terminate pktio type %d", pktio_if); }