From patchwork Thu Dec 10 11:44:35 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Uvarov X-Patchwork-Id: 58201 Delivered-To: patch@linaro.org Received: by 10.112.147.194 with SMTP id tm2csp434625lbb; Thu, 10 Dec 2015 03:44:48 -0800 (PST) X-Received: by 10.140.84.40 with SMTP id k37mr14473614qgd.33.1449747888291; Thu, 10 Dec 2015 03:44:48 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id y189si14394556qka.89.2015.12.10.03.44.47; Thu, 10 Dec 2015 03:44:48 -0800 (PST) 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; dkim=neutral (body hash did not verify) header.i=@linaro-org.20150623.gappssmtp.com Received: by lists.linaro.org (Postfix, from userid 109) id 90E9161944; Thu, 10 Dec 2015 11:44:47 +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.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID, 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 A0E7F61810; Thu, 10 Dec 2015 11:44:43 +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 92D4B6181D; Thu, 10 Dec 2015 11:44:42 +0000 (UTC) Received: from mail-lf0-f44.google.com (mail-lf0-f44.google.com [209.85.215.44]) by lists.linaro.org (Postfix) with ESMTPS id AE81F6156A for ; Thu, 10 Dec 2015 11:44:41 +0000 (UTC) Received: by lffu14 with SMTP id u14so54867798lff.1 for ; Thu, 10 Dec 2015 03:44:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=L2DCj8+45D2qdSSahXkNsZ3WrpHdJMocTtJmkFd+APE=; b=XmdEg11A2w70PmXr0cY12mXqodh87azGXNer7IuO1Q45ijc9cC/0D12KUGiWtgIzvv 7k0at6LEzjo/0cIPT6ccDop7ap/Jyw5+uflX02eip0mLQfraB/Shfll5WE6g9V7KOYTR Y6IAHIxDspDe04goLAkriWz487cBRj9TqizZ0bt9Fs8cFgyXkVMg9uOxoDpXE7FzDYiu KlTCjy60Byo6T6oLiTMh3Ozgw73HIkGiGT2sde+Eyf8iKLU7tpZ1M9A+TE8zoCwgPn+P YMLyF5XHPmQKiLeHjyvbNeV/NXklLZIYeznJo3rx2BBVkGG/dXmRG1jsBWh8hx9U3E9O dL7Q== 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; bh=L2DCj8+45D2qdSSahXkNsZ3WrpHdJMocTtJmkFd+APE=; b=eU1Tyx1MT4DRVrzkK6YF45quT8ZxaPAzDp2T04j9xgCFC33WbKMtQKbLbF4BOcIJvO u+TOCMVK/bSqhFago9eR7FXB1HdvUNsul/rPIennvmrTkJBpzCO6i4/nH8uVI12ho+Q+ Ur/7qdZ4ANr/vJ2Jle3Go/DrdMXCBTc+Egy5tQrMLcMt6bRrFwIhxY/uwyG1tVdmGiR5 uOtSCJrieQgG5jDh9chX6xTGY4dNL5de0zsf/R/qt8TVcloo9duN8+0uBYyRWQOGqtWF PFcVZPjDdBhiha/ShN0qxXYbDsBIDSSPxLv2LaMthFXZ3ogyi1Fl5wbJZAGc75w2qwEn Ml8g== X-Gm-Message-State: ALoCoQmkNk0sTms9plXPX0WGfPmh2IWpew3MwVtOsx6w9S2mofbv2FlEZLJxwrjyO2oh/bNv6cMJEiv1Sd45RnsYuWlu/bcZWA== X-Received: by 10.25.16.151 with SMTP id 23mr4875035lfq.142.1449747880251; Thu, 10 Dec 2015 03:44:40 -0800 (PST) Received: from localhost.localdomain (ppp91-76-173-134.pppoe.mtu-net.ru. [91.76.173.134]) by smtp.gmail.com with ESMTPSA id g80sm2291055lfg.44.2015.12.10.03.44.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 10 Dec 2015 03:44:39 -0800 (PST) From: Maxim Uvarov To: lng-odp@lists.linaro.org Date: Thu, 10 Dec 2015 14:44:35 +0300 Message-Id: <1449747875-382-1-git-send-email-maxim.uvarov@linaro.org> X-Mailer: git-send-email 1.9.1 X-Topics: patch Subject: [lng-odp] [API-NEXT PATCH] api: pktio link state 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" Signed-off-by: Maxim Uvarov --- include/odp/api/packet_io.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/include/odp/api/packet_io.h b/include/odp/api/packet_io.h index 443841e..f970ad7 100644 --- a/include/odp/api/packet_io.h +++ b/include/odp/api/packet_io.h @@ -673,6 +673,17 @@ void odp_pktio_output_queue_param_init(odp_pktio_output_queue_param_t *param); void odp_pktio_print(odp_pktio_t pktio); /** + * Determine pktio link is up or down for a packet IO interface. + * + * @param[in] pktio Packet IO handle. + * + * @retval 1 link is up + * @retval 0 link is down + * @retval <0 on failure +*/ +int odp_pktio_link_state(odp_pktio_t pktio); + +/** * @} */