From: Lina Iyer <ilina@codeaurora.org>
To: tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com
Cc: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
sboyd@codeaurora.org, rnayak@codeaurora.org,
asathyak@codeaurora.org, Lina Iyer <ilina@codeaurora.org>,
Steven Rostedt <rostedt@goodmis.org>
Subject: [PATCH RFC 3/4] drivers: irqchip: pdc: log PDC info in FTRACE
Date: Tue, 23 Jan 2018 10:56:55 -0700 [thread overview]
Message-ID: <20180123175656.11942-4-ilina@codeaurora.org> (raw)
In-Reply-To: <20180123175656.11942-1-ilina@codeaurora.org>
From: Archana Sathyakumar <asathyak@codeaurora.org>
Log key PDC pin configuration in FTRACE.
Cc: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Archana Sathyakumar <asathyak@codeaurora.org>
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
---
drivers/irqchip/qcom-pdc.c | 6 ++++++
include/trace/events/pdc.h | 50 ++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 56 insertions(+)
create mode 100644 include/trace/events/pdc.h
diff --git a/drivers/irqchip/qcom-pdc.c b/drivers/irqchip/qcom-pdc.c
index 57f1348bd81c..9b626e9f3a29 100644
--- a/drivers/irqchip/qcom-pdc.c
+++ b/drivers/irqchip/qcom-pdc.c
@@ -26,6 +26,8 @@
#include <linux/platform_device.h>
#include <linux/slab.h>
#include <linux/types.h>
+#define CREATE_TRACE_POINTS
+#include "trace/events/pdc.h"
#include "qcom-pdc.h"
@@ -78,6 +80,7 @@ static inline void pdc_enable_intr(struct irq_data *d, bool on)
break;
udelay(5);
} while (1);
+ trace_irq_pin_config("enable", (u32)pin_out, (u32)d->hwirq, 0, on);
spin_unlock_irqrestore(&pdc_lock, flags);
WARN_ON(r_enable != enable);
}
@@ -161,6 +164,9 @@ static int qcom_pdc_gic_set_type(struct irq_data *d, unsigned int type)
udelay(5);
} while (1);
+ trace_irq_pin_config("type_config", (u32)pin_out, (u32)d->hwirq,
+ pdc_type, 0);
+
/*
* If type is edge triggered, forward that as Rising edge as PDC
* takes care of converting falling edge to rising edge signal
diff --git a/include/trace/events/pdc.h b/include/trace/events/pdc.h
new file mode 100644
index 000000000000..bec54c414880
--- /dev/null
+++ b/include/trace/events/pdc.h
@@ -0,0 +1,50 @@
+/* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 and
+ * only version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM pdc
+
+#if !defined(_TRACE_PDC_) || defined(TRACE_HEADER_MULTI_READ)
+#define _TRACE_PDC_H_
+
+#include <linux/tracepoint.h>
+
+TRACE_EVENT(irq_pin_config,
+
+ TP_PROTO(char *func, u32 pin, u32 hwirq, u32 type, u32 enable),
+
+ TP_ARGS(func, pin, hwirq, type, enable),
+
+ TP_STRUCT__entry(
+ __field(char *, func)
+ __field(u32, pin)
+ __field(u32, hwirq)
+ __field(u32, type)
+ __field(u32, enable)
+ ),
+
+ TP_fast_assign(
+ __entry->pin = pin;
+ __entry->func = func;
+ __entry->hwirq = hwirq;
+ __entry->type = type;
+ __entry->enable = enable;
+ ),
+
+ TP_printk("%s hwirq:%u pin:%u type:%u enable:%u",
+ __entry->func, __entry->pin, __entry->hwirq, __entry->type,
+ __entry->enable)
+);
+
+#endif
+#define TRACE_INCLUDE_FILE pdc
+#include <trace/define_trace.h>
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
next prev parent reply other threads:[~2018-01-23 17:56 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-23 17:56 [PATCH RFC 0/4] irqchip: qcom: add support for PDC interrupt controller Lina Iyer
2018-01-23 17:56 ` [PATCH RFC 1/4] drivers: irqchip: pdc: " Lina Iyer
2018-01-24 14:20 ` Marc Zyngier
2018-01-25 18:52 ` Lina Iyer
2018-01-30 17:56 ` Lina Iyer
2018-01-30 18:11 ` Marc Zyngier
2018-01-31 16:24 ` Lina Iyer
2018-01-31 16:46 ` Marc Zyngier
2018-02-01 16:49 ` Lina Iyer
2018-01-23 17:56 ` [PATCH RFC 2/4] dt-bindings/interrupt-controller: pdc: descibe PDC device binding Lina Iyer
2018-01-23 18:09 ` Sudeep Holla
2018-01-23 18:46 ` Lina Iyer
2018-01-24 14:24 ` Marc Zyngier
2018-01-30 15:20 ` Rob Herring
2018-01-23 17:56 ` Lina Iyer [this message]
2018-01-23 18:13 ` [PATCH RFC 3/4] drivers: irqchip: pdc: log PDC info in FTRACE Steven Rostedt
2018-01-25 15:45 ` Lina Iyer
2018-01-23 17:56 ` [PATCH RFC 4/4] drivers: irqchip: qcom: add pin information for SDM845 Lina Iyer
2018-01-24 14:20 ` Marc Zyngier
2018-01-25 18:14 ` Lina Iyer
2018-01-23 18:15 ` [PATCH RFC 0/4] irqchip: qcom: add support for PDC interrupt controller Sudeep Holla
2018-01-23 18:44 ` Lina Iyer
2018-01-24 10:10 ` Sudeep Holla
2018-01-24 17:43 ` Lina Iyer
2018-01-24 17:54 ` Sudeep Holla
2018-01-25 15:54 ` Lina Iyer
2018-01-25 16:39 ` Sudeep Holla
2018-01-25 18:13 ` Lina Iyer
2018-01-25 18:43 ` Sudeep Holla
2018-01-25 20:05 ` Lina Iyer
2018-01-26 11:39 ` Sudeep Holla
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180123175656.11942-4-ilina@codeaurora.org \
--to=ilina@codeaurora.org \
--cc=asathyak@codeaurora.org \
--cc=jason@lakedaemon.net \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marc.zyngier@arm.com \
--cc=rnayak@codeaurora.org \
--cc=rostedt@goodmis.org \
--cc=sboyd@codeaurora.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).