From: sashiko-bot@kernel.org
To: "Koichiro Den" <den@valinux.co.jp>
Cc: dmaengine@vger.kernel.org, linux-pci@vger.kernel.org,
vkoul@kernel.org, Frank.Li@kernel.org
Subject: Re: [PATCH v6 5/5] dmaengine: dw-edma: Add trace support
Date: Fri, 30 Oct 2026 15:17:13 +0000 [thread overview]
Message-ID: <sashiko-outbox-191148@kernel.org> (raw)
In-Reply-To: <20261030150742.2586776-6-den@valinux.co.jp>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] dmaengine: dw-edma: tracepoints use edma_ prefix instead of dw_edma_
--
commit 8d4bbe2d0d3de12559142ae2213cc91782526216
Author: Frank Li <Frank.Li@nxp.com>
dmaengine: dw-edma: Add trace support
This commit adds tracepoints for linked-list publication, descriptor append
and completion, and doorbells in the dw-edma driver to help diagnose stalls.
> diff --git a/drivers/dma/dw-edma/dw-edma-trace.h b/drivers/dma/dw-edma/dw-edma-trace.h
> new file mode 100644
> index 0000000000000..653b36acff158
> --- /dev/null
> +++ b/drivers/dma/dw-edma/dw-edma-trace.h
> @@ -0,0 +1,117 @@
> +/* SPDX-License-Identifier: GPL-2.0-or-later */
> +/*
> + * Copyright 2023 NXP.
> + */
> +
> +#undef TRACE_SYSTEM
> +#define TRACE_SYSTEM dw_edma
> +
> +#if !defined(__LINUX_DW_EDMA_TRACE) || defined(TRACE_HEADER_MULTI_READ)
> +#define __LINUX_DW_EDMA_TRACE
> +
> +#include <linux/types.h>
> +#include <linux/tracepoint.h>
> +
> +DECLARE_EVENT_CLASS(edma_desc_info,
> + TP_PROTO(struct dw_edma_desc *desc),
> + TP_ARGS(desc),
> + TP_STRUCT__entry(
> + __field(size_t, nburst)
> + __field(size_t, start_burst)
> + __field(dma_cookie_t, cookie)
> + __field(u32, id)
> + __field(u8, dir)
> + ),
> + TP_fast_assign(
> + __entry->nburst = desc->nburst;
> + __entry->start_burst = desc->start_burst;
> + __entry->id = desc->chan->id;
> + __entry->dir = desc->chan->dir;
> + __entry->cookie = desc->vd.tx.cookie;
> + ),
> + TP_printk("chan %u%c desc %d nburst %zu start_burst %zu",
> + __entry->id,
> + __entry->dir ? 'R' : 'W',
> + __entry->cookie,
> + __entry->nburst,
> + __entry->start_burst)
> +);
> +
> +DEFINE_EVENT(edma_desc_info, edma_append_desc,
> + TP_PROTO(struct dw_edma_desc *desc),
> + TP_ARGS(desc)
> +);
> +
> +DEFINE_EVENT(edma_desc_info, edma_complete_desc,
> + TP_PROTO(struct dw_edma_desc *desc),
> + TP_ARGS(desc)
> +);
> +
> +TRACE_EVENT(edma_doorbell,
> + TP_PROTO(struct dw_edma_chan *chan),
> + TP_ARGS(chan),
> + TP_STRUCT__entry(
> + __field(u32, id)
> + __field(u8, dir)
> + __field(u32, done)
> + __field(u32, head)
> + ),
> + TP_fast_assign(
> + __entry->id = chan->id;
> + __entry->dir = chan->dir;
> + __entry->done = chan->ll_done;
> + __entry->head = chan->ll_head;
> + ),
> + TP_printk("chan %u%c done %u head %u",
> + __entry->id,
> + __entry->dir ? 'R' : 'W',
> + __entry->done,
> + __entry->head)
> +);
> +
> +TRACE_EVENT(edma_fill_ll,
> + TP_PROTO(struct dw_edma_chan *chan, u32 idx, dma_cookie_t cookie, u64 src,
> + u64 dest, u32 sz, bool flag),
> + TP_ARGS(chan, idx, cookie, src, dest, sz, flag),
[Severity: Low]
This isn't a bug, but since TRACE_SYSTEM in drivers/dma/dw-edma/dw-edma-trace.h
is defined as dw_edma, should the event class and tracepoints follow the
subsystem_event naming convention and use the dw_edma_ prefix instead of
edma_?
Specifically, edma_desc_info, edma_append_desc, edma_complete_desc,
edma_doorbell, and edma_fill_ll export global tracepoint symbols under the
generic edma_ prefix (which is also used by drivers/dma/fsl-edma-trace.h)
and are invoked in drivers/dma/dw-edma/dw-edma-core.c from
dw_edma_ll_consume(), dw_edma_core_ll_start(), dw_edma_start_transfer(),
and dw_edma_core_ch_doorbell().
Renaming them to dw_edma_desc_info, dw_edma_append_desc,
dw_edma_complete_desc, dw_edma_doorbell, and dw_edma_fill_ll (along with
their callers in dw-edma-core.c) would match the TRACE_SYSTEM name and avoid
generic edma_ symbol names.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261030150742.2586776-1-den@valinux.co.jp?part=5
prev parent reply other threads:[~2026-10-30 15:17 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-30 15:07 [PATCH v6 0/5] dmaengine: dw-edma: Support dynamic LL appends Koichiro Den
2026-10-30 15:07 ` [PATCH v6 1/5] dmaengine: dw-edma: Add a channel transfer size operation Koichiro Den
2026-10-30 16:18 ` Frank Li
2026-10-30 15:07 ` [PATCH v6 2/5] dmaengine: dw-edma: Reclaim LL entries from hardware progress Koichiro Den
2026-10-30 15:39 ` sashiko-bot
2026-10-30 16:21 ` Frank Li
2026-10-31 14:28 ` Koichiro Den
2026-10-30 16:54 ` Frank Li
2026-10-31 15:00 ` Koichiro Den
2026-10-30 15:07 ` [PATCH v6 3/5] dmaengine: dw-edma: Use HDMA watermark interrupts as LL progress Koichiro Den
2026-10-30 15:21 ` sashiko-bot
2026-10-31 16:10 ` Koichiro Den
2026-10-30 15:07 ` [PATCH v6 4/5] dmaengine: dw-edma: Dynamically append requests while running Koichiro Den
2026-10-30 15:07 ` [PATCH v6 5/5] dmaengine: dw-edma: Add trace support Koichiro Den
2026-10-30 15:17 ` sashiko-bot [this message]
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=sashiko-outbox-191148@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=den@valinux.co.jp \
--cc=dmaengine@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=vkoul@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox