All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	linux-trace-kernel@vger.kernel.org, kernel@pengutronix.de
Subject: Re: [PATCH] usb: typec: add trace point for typec_set_mode
Date: Thu, 18 Jun 2026 14:31:00 +0300	[thread overview]
Message-ID: <ajPW9P6qZyhqtjvp@kuha> (raw)
In-Reply-To: <43e13854-a634-4706-bc12-723c871a5579@pengutronix.de>

Hi,

On Thu, Jun 18, 2026 at 01:00:58PM +0200, Ahmad Fatoum wrote:
> Hello Heikki,
> 
> On 6/18/26 12:56 PM, Heikki Krogerus wrote:
> > On Wed, Jun 17, 2026 at 10:03:04PM +0200, Ahmad Fatoum wrote:
> >> --- a/drivers/usb/typec/class.c
> >> +++ b/drivers/usb/typec/class.c
> >> @@ -20,6 +20,9 @@
> >>  #include "class.h"
> >>  #include "pd.h"
> >>  
> >> +#define CREATE_TRACE_POINTS
> >> +#include <trace/events/typec.h>
> > 
> > Those should probable go to drivers/usb/typec/trace.c and then you
> > need add something like this to drivers/usb/typec/Makefile:
> > 
> >  obj-$(CONFIG_TYPEC)            += typec.o
> >  typec-y                                := class.o mux.o bus.o pd.o retimer.o mode_selection.o
> >  typec-$(CONFIG_ACPI)           += port-mapper.o
> > +typec-$(CONFIG_TRACING)                += trace.o
> 
> Thanks for the suggestion. I will do that for v2.
> 
> I also saw there is Sashiko AI feedback on this patch[1], but I am not
> familiar enough with how the event headers are used outside the kernel
> to determine if that's actionable advice or if it can be ignored.
> 
> Do you have an opinion on that?
> 
> [1]:
> https://sashiko.dev/#/patchset/20260617-typec_set_mode-tracepoint-v1-1-bdfbb39cfccd%40pengutronix.de

It's correct. You need to use a private trace.h in this case, so just
move it here: drivers/usb/typec/trace.h

And also make sure you include everything needed in that header like
it's telling you.

Thanks,

-- 
heikki

  reply	other threads:[~2026-06-18 11:31 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-17 20:03 [PATCH] usb: typec: add trace point for typec_set_mode Ahmad Fatoum
2026-06-18 10:56 ` Heikki Krogerus
2026-06-18 11:00   ` Ahmad Fatoum
2026-06-18 11:31     ` Heikki Krogerus [this message]
2026-06-27  9:23       ` 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=ajPW9P6qZyhqtjvp@kuha \
    --to=heikki.krogerus@linux.intel.com \
    --cc=a.fatoum@pengutronix.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=kernel@pengutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mhiramat@kernel.org \
    --cc=rostedt@goodmis.org \
    /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.