From patchwork Fri Jan 8 20:30:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 59408 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp757599lbb; Fri, 8 Jan 2016 11:52:48 -0800 (PST) X-Received: by 10.55.207.73 with SMTP id e70mr145298564qkj.77.1452282768231; Fri, 08 Jan 2016 11:52:48 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id z192si87452622qka.1.2016.01.08.11.52.47; Fri, 08 Jan 2016 11:52: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 Received: by lists.linaro.org (Postfix, from userid 109) id C950E61684; Fri, 8 Jan 2016 19:52:47 +0000 (UTC) Authentication-Results: lists.linaro.org; dkim=fail reason="verification failed; unprotected key" header.d=linaro.org header.i=@linaro.org header.b=UDHkTgIB; dkim-adsp=none (unprotected policy); dkim-atps=neutral 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 B5D7B61CA5; Fri, 8 Jan 2016 19:37:59 +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 EB3C06179C; Fri, 8 Jan 2016 19:35:39 +0000 (UTC) Received: from mail-lf0-f41.google.com (mail-lf0-f41.google.com [209.85.215.41]) by lists.linaro.org (Postfix) with ESMTPS id EF10F61B3D for ; Fri, 8 Jan 2016 19:31:59 +0000 (UTC) Received: by mail-lf0-f41.google.com with SMTP id d17so15378604lfb.1 for ; Fri, 08 Jan 2016 11:31:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=wtfk2q8OfdERtXWDvYn8moVqdhB9h+d/7rosUVUeYyU=; b=UDHkTgIB3q7OWueYAj1gwyKbRPtnQtHC5B6MeP1TMy3HB6XNFlDWP87KHTEsO2UEFe v7OIEpYL5p3WKw54/PLAeBXpZ95OSSQqmZqHseOtA9v+OsPhnG42iEZKyzpzwnh6Ikf8 DG/EgdSLME01q9Al6QDeFva94EyXDuS9ksP0g= 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=wtfk2q8OfdERtXWDvYn8moVqdhB9h+d/7rosUVUeYyU=; b=PwHRkJg1ACv+oLCnqPb19DIF+GvEHXDo1oCOH2zS3nVfa5J9VqJnkb3byVFzlPCKHP uJH1dbpX1kER9MKDbBlQQBBf3Z1ZBjK5YEfC523+gumF0nwKthQhBo0+MNEJ1d/QFV2w paxb8dskq/Hy86ZmxS29FDPdpVVdLGro9feWnKslxymJb9ddkha0KXUMXHC5aJGr3/Yj Ofdr2xDmxl3Y+sYDiNBs2hRR4IziRM+pfEeMw6Pux9xk6NS1WZmzqC+nRzx66b2NeXmE N8ZqCtb4zzyiAKHczh8Xo4T+8v/58L+y6fjENZhszc3D63rWfYw2ThtotyBRxu+nyCIr 0zJg== X-Gm-Message-State: ALoCoQnFivWmx9D/gG5VNmv4/lRdozgYxwTQaJH7tvrtmirb7A/9Yk2706A+tlNtz2SD8ZrqfVT2LS9gLHe/xxY3coTOiqph2w== X-Received: by 10.25.77.79 with SMTP id a76mr13096843lfb.1.1452281518946; Fri, 08 Jan 2016 11:31:58 -0800 (PST) Received: from erachmi-ericsson.ki.sw.ericsson.se (c-83-233-90-46.cust.bredband2.com. [83.233.90.46]) by smtp.gmail.com with ESMTPSA id l204sm2085534lfg.49.2016.01.08.11.31.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 08 Jan 2016 11:31:58 -0800 (PST) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, stuart.haslam@linaro.org, maxim.uvarov@linaro.org, bill.fischofer@linaro.org, petri.savolainen@linaro.org, edavis@broadcom.com Date: Fri, 8 Jan 2016 21:30:04 +0100 Message-Id: <1452285014-60320-22-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1452285014-60320-1-git-send-email-christophe.milard@linaro.org> References: <1452285014-60320-1-git-send-email-christophe.milard@linaro.org> Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [API-NEXT RFC 21/31] drivers: defining the drivers logging macros. 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" These map 1:1 to the ODP ones at the time being but may be redefined if needed. Signed-off-by: Christophe Milard --- drivers/driver_log.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 drivers/driver_log.h diff --git a/drivers/driver_log.h b/drivers/driver_log.h new file mode 100644 index 0000000..79353f3 --- /dev/null +++ b/drivers/driver_log.h @@ -0,0 +1,26 @@ +/* Copyright (c) 2015, Linaro Limited + * All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +#include + +/** + * Log error message. + */ +#define DRV_ERR(fmt, ...) \ + ODP_ERR("DRIVER: " fmt, ##__VA_ARGS__) + +/** + * Log debug message. + */ +#define DRV_DBG(fmt, ...) \ + ODP_DBG("DRIVER: " fmt, ##__VA_ARGS__) + +/** + * Log debug message. + */ +#define DRV_ABORT(fmt, ...) \ + ODP_ABORT("DRIVER: " fmt, ##__VA_ARGS__) +