Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932687AbbFTUWR (ORCPT ); Sat, 20 Jun 2015 16:22:17 -0400 Received: from mail-wi0-f176.google.com ([209.85.212.176]:32883 "EHLO mail-wi0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932562AbbFTUVx (ORCPT ); Sat, 20 Jun 2015 16:21:53 -0400 From: Tal Shorer To: rostedt@goodmis.org, mingo@redhat.com Cc: linux-kernel@vger.kernel.org, Tal Shorer Subject: [Patch RFC 2/2] tracing: gpio: add Kconfig option for enabling/disabling trace events Date: Sat, 20 Jun 2015 23:21:19 +0300 Message-Id: <1434831679-3852-3-git-send-email-tal.shorer@gmail.com> X-Mailer: git-send-email 2.2.2 In-Reply-To: <1434831679-3852-1-git-send-email-tal.shorer@gmail.com> References: <1434831679-3852-1-git-send-email-tal.shorer@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1264 Lines: 47 Add a new options to gpio Kconfig, CONFIG_GPIO_TRACING, that is used for enabling/disabling compilation of gpio function trace events. Signed-off-by: Tal Shorer --- drivers/gpio/Kconfig | 6 ++++++ include/trace/events/gpio.h | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig index caefe80..1480a22 100644 --- a/drivers/gpio/Kconfig +++ b/drivers/gpio/Kconfig @@ -88,6 +88,12 @@ config GPIO_SYSFS config GPIO_GENERIC tristate +config GPIO_TRACING + bool "gpio tracing" + depends on TRACING + help + Enable tracing for gpio subsystem + # put drivers in the right section, in alphabetical order # This symbol is selected by both I2C and SPI expanders diff --git a/include/trace/events/gpio.h b/include/trace/events/gpio.h index 927a8ad..09af636 100644 --- a/include/trace/events/gpio.h +++ b/include/trace/events/gpio.h @@ -1,6 +1,10 @@ #undef TRACE_SYSTEM #define TRACE_SYSTEM gpio +#ifndef CONFIG_GPIO_TRACING +#define NOTRACE +#endif + #if !defined(_TRACE_GPIO_H) || defined(TRACE_HEADER_MULTI_READ) #define _TRACE_GPIO_H -- 2.2.2 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in Please read the FAQ at http://www.tux.org/lkml/