All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nicolas Boichat <drinkcat@chromium.org>
To: Mauro Carvalho Chehab <mchehab@kernel.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Nicolas Boichat <drinkcat@chromium.org>,
	Andy Gross <agross@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>,
	Todor Tomov <todor.too@gmail.com>,
	linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-media@vger.kernel.org
Subject: [PATCH v4 1/3, RESEND] media: camss: vfe: Use trace_printk for debugging only
Date: Thu, 20 Aug 2020 17:14:10 +0800	[thread overview]
Message-ID: <20200820170951.v4.1.Ia54fe801f246a0b0aee36fb1f3bfb0922a8842b0@changeid> (raw)

trace_printk should not be used in production code. Since
tracing interrupts is presumably latency sensitive, pr_dbg is
not appropriate, so guard the call with a preprocessor symbol
that can be defined for debugging purpose.

Signed-off-by: Nicolas Boichat <drinkcat@chromium.org>
---

(resending this patch as part of the whole series, since we need a new
patch 3/3 now).

 drivers/media/platform/qcom/camss/camss-vfe-4-1.c | 2 ++
 drivers/media/platform/qcom/camss/camss-vfe-4-7.c | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/drivers/media/platform/qcom/camss/camss-vfe-4-1.c b/drivers/media/platform/qcom/camss/camss-vfe-4-1.c
index 174a36be6f5d866..0c57171fae4f9e9 100644
--- a/drivers/media/platform/qcom/camss/camss-vfe-4-1.c
+++ b/drivers/media/platform/qcom/camss/camss-vfe-4-1.c
@@ -936,8 +936,10 @@ static irqreturn_t vfe_isr(int irq, void *dev)
 
 	vfe->ops->isr_read(vfe, &value0, &value1);
 
+#ifdef CAMSS_VFE_TRACE_IRQ
 	trace_printk("VFE: status0 = 0x%08x, status1 = 0x%08x\n",
 		     value0, value1);
+#endif
 
 	if (value0 & VFE_0_IRQ_STATUS_0_RESET_ACK)
 		vfe->isr_ops.reset_ack(vfe);
diff --git a/drivers/media/platform/qcom/camss/camss-vfe-4-7.c b/drivers/media/platform/qcom/camss/camss-vfe-4-7.c
index 0dca8bf9281e774..307675925e5c779 100644
--- a/drivers/media/platform/qcom/camss/camss-vfe-4-7.c
+++ b/drivers/media/platform/qcom/camss/camss-vfe-4-7.c
@@ -1058,8 +1058,10 @@ static irqreturn_t vfe_isr(int irq, void *dev)
 
 	vfe->ops->isr_read(vfe, &value0, &value1);
 
+#ifdef CAMSS_VFE_TRACE_IRQ
 	trace_printk("VFE: status0 = 0x%08x, status1 = 0x%08x\n",
 		     value0, value1);
+#endif
 
 	if (value0 & VFE_0_IRQ_STATUS_0_RESET_ACK)
 		vfe->isr_ops.reset_ack(vfe);
-- 
2.28.0.220.ged08abb693-goog


             reply	other threads:[~2020-08-20  9:15 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-20  9:14 Nicolas Boichat [this message]
2020-08-20  9:14 ` [PATCH v4 2/3] kernel/trace: Add TRACING_ALLOW_PRINTK config option Nicolas Boichat
2020-08-20  9:14   ` [Intel-gfx] " Nicolas Boichat
2020-08-20  9:14   ` Nicolas Boichat
2020-08-20  9:14   ` [f2fs-dev] " Nicolas Boichat
2020-08-20  9:14 ` [PATCH v4 3/3] media: atomisp: Only use trace_printk if allowed Nicolas Boichat
2020-08-20  9:14   ` Nicolas Boichat
2020-08-20 14:23   ` Steven Rostedt
2020-08-20 14:23     ` Steven Rostedt
2020-08-21  0:13     ` Nicolas Boichat
2020-08-21  0:13       ` Nicolas Boichat
2020-08-21  0:36       ` Steven Rostedt
2020-08-21  0:36         ` Steven Rostedt
2020-08-21  1:39         ` Nicolas Boichat
2020-08-21  1:39           ` Nicolas Boichat
2020-08-21  1:57           ` Steven Rostedt
2020-08-21  1:57             ` Steven Rostedt
2020-08-21  2:36             ` Joe Perches
2020-08-21  2:36               ` Joe Perches
2020-08-21  2:42               ` Nicolas Boichat
2020-08-21  2:42                 ` Nicolas Boichat
2020-08-21  2:49                 ` Joe Perches
2020-08-21  2:49                   ` Joe Perches
2020-08-21  3:04                   ` Steven Rostedt
2020-08-21  3:04                     ` Steven Rostedt
2020-08-21  3:08                     ` Steven Rostedt
2020-08-21  3:08                       ` Steven Rostedt
2020-08-21  2:44               ` Steven Rostedt
2020-08-21  2:44                 ` Steven Rostedt
2020-08-21  2:39             ` Nicolas Boichat
2020-08-21  2:39               ` Nicolas Boichat
2020-08-21  3:01               ` Steven Rostedt
2020-08-21  3:01                 ` Steven Rostedt
2020-08-21 12:19                 ` Nicolas Boichat
2020-08-21 12:19                   ` Nicolas Boichat
2020-08-21  8:48         ` David Laight
2020-08-21  8:48           ` David Laight
2020-08-21 10:27           ` Nicolas Boichat
2020-08-21 10:27             ` Nicolas Boichat
2020-08-21 11:32             ` David Laight
2020-08-21 11:32               ` David Laight
2020-08-21 12:07               ` Nicolas Boichat
2020-08-21 12:07                 ` Nicolas Boichat
2020-08-21 12:18                 ` David Laight
2020-08-21 12:18                   ` David Laight
2020-08-21 12:37                   ` Nicolas Boichat
2020-08-21 12:37                     ` Nicolas Boichat
2020-08-20 14:21 ` [PATCH v4 1/3, RESEND] media: camss: vfe: Use trace_printk for debugging only Steven Rostedt

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=20200820170951.v4.1.Ia54fe801f246a0b0aee36fb1f3bfb0922a8842b0@changeid \
    --to=drinkcat@chromium.org \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=todor.too@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.