* [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output
@ 2026-09-21 15:13 Sebastian Andrzej Siewior
2026-09-21 15:16 ` sashiko-bot
2026-09-21 16:03 ` Frank Li
0 siblings, 2 replies; 4+ messages in thread
From: Sebastian Andrzej Siewior @ 2026-09-21 15:13 UTC (permalink / raw)
To: Frank Li; +Cc: dmaengine, Binbin Zhou, Vinod Koul, Frank Li
The %pK format modifier was meant for /proc kind of output, not general
printk output. Since commit ad67b74d2469d ("printk: hash addresses
printed with %p") pointers are hashed by default and the behaviour can
be controller by `hash_pointers' boot argument.
The policy on %p is to not introduce new ones.
The output in loongson2_cmc_dma_issue_pending() is the only dev_dbg()
output in the driver and is only output once the transfer is started.
There is no output issued by the driver if the transfer is completed, if
a follow-up transfer is started or if any of the other callbacks (such
as loongson2_cmc_dma_tx_status()) are invoked. This output does not look
essential.
Instead removing just the %pK output, remove the complete dev_dbg()
output from the driver.
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
On 2026-09-18 16:44:59 [-0500], Frank Li wrote:
>
> please careful,
>
> remove whole dev_dbg() when vchan_issue_pending() failure.
>
> commit messesge should show why it is okay to remove dev_dbg() here.
Is the arguing now reasonable?
> Frank
v2…v3: https://lore.kernel.org/all/20260918201714.eFNI3VMq@linutronix.de/
- Reword part of the commit message.
v1…v2: https://lore.kernel.org/all/20260918103409.UV4g2ON7@linutronix.de/
- Update subject line (it is removed, not replaced).
drivers/dma/loongson/loongson2-apb-cmc-dma.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/dma/loongson/loongson2-apb-cmc-dma.c b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
index 1c9a542edc859..27f8f7a5738d9 100644
--- a/drivers/dma/loongson/loongson2-apb-cmc-dma.c
+++ b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
@@ -337,7 +337,6 @@ static void loongson2_cmc_dma_issue_pending(struct dma_chan *chan)
guard(spinlock_irqsave)(&lchan->vchan.lock);
if (vchan_issue_pending(&lchan->vchan) && !lchan->desc) {
- dev_dbg(chan2dev(lchan), "vchan %pK: issued\n", &lchan->vchan);
loongson2_cmc_dma_start_transfer(lchan);
}
}
--
2.55.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output
2026-09-21 15:13 [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output Sebastian Andrzej Siewior
@ 2026-09-21 15:16 ` sashiko-bot
2026-09-21 16:04 ` Frank Li
2026-09-21 16:03 ` Frank Li
1 sibling, 1 reply; 4+ messages in thread
From: sashiko-bot @ 2026-09-21 15:16 UTC (permalink / raw)
To: Sebastian Andrzej Siewior; +Cc: dmaengine, vkoul, Frank.Li
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] dmaengine: loongson: unnecessary curly braces around single statement
--
commit 800bb056df0405c03d12921052d730f7cccef7be
Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
dmaengine: loongson: Remove the dev_dbg() output
This commit removes the dev_dbg() output from
loongson2_cmc_dma_issue_pending() since the %pK format modifier is not
appropriate for general printk output. The debug statement was deemed
non-essential and is completely removed.
> diff --git a/drivers/dma/loongson/loongson2-apb-cmc-dma.c b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> index 1c9a542edc859..27f8f7a5738d9 100644
> --- a/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> +++ b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> @@ -337,7 +337,6 @@ static void loongson2_cmc_dma_issue_pending(struct dma_chan *chan)
> guard(spinlock_irqsave)(&lchan->vchan.lock);
>
> if (vchan_issue_pending(&lchan->vchan) && !lchan->desc) {
> - dev_dbg(chan2dev(lchan), "vchan %pK: issued\n", &lchan->vchan);
> loongson2_cmc_dma_start_transfer(lchan);
> }
[Severity: Low]
This isn't a bug, but with the removal of the dev_dbg() statement, this if
block now contains only a single statement. Should the curly braces be
removed to adhere to the kernel coding style guidelines?
> }
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260921151312.I8Q8NLnx@linutronix.de?part=1
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output
2026-09-21 15:13 [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output Sebastian Andrzej Siewior
2026-09-21 15:16 ` sashiko-bot
@ 2026-09-21 16:03 ` Frank Li
1 sibling, 0 replies; 4+ messages in thread
From: Frank Li @ 2026-09-21 16:03 UTC (permalink / raw)
To: Sebastian Andrzej Siewior; +Cc: dmaengine, Binbin Zhou, Vinod Koul, Frank Li
On Mon, Sep 21, 2026 at 05:13:12PM +0200, Sebastian Andrzej Siewior wrote:
> The %pK format modifier was meant for /proc kind of output, not general
> printk output. Since commit ad67b74d2469d ("printk: hash addresses
> printed with %p") pointers are hashed by default and the behaviour can
> be controller by `hash_pointers' boot argument.
> The policy on %p is to not introduce new ones.
>
> The output in loongson2_cmc_dma_issue_pending() is the only dev_dbg()
> output in the driver and is only output once the transfer is started.
> There is no output issued by the driver if the transfer is completed, if
> a follow-up transfer is started or if any of the other callbacks (such
> as loongson2_cmc_dma_tx_status()) are invoked. This output does not look
> essential.
>
> Instead removing just the %pK output, remove the complete dev_dbg()
> output from the driver.
>
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
> ---
Reviewed-by: Frank Li <Frank.Li@nxp.com>
> On 2026-09-18 16:44:59 [-0500], Frank Li wrote:
> >
> > please careful,
> >
> > remove whole dev_dbg() when vchan_issue_pending() failure.
> >
> > commit messesge should show why it is okay to remove dev_dbg() here.
>
> Is the arguing now reasonable?
>
> > Frank
>
> v2…v3: https://lore.kernel.org/all/20260918201714.eFNI3VMq@linutronix.de/
> - Reword part of the commit message.
>
> v1…v2: https://lore.kernel.org/all/20260918103409.UV4g2ON7@linutronix.de/
> - Update subject line (it is removed, not replaced).
>
> drivers/dma/loongson/loongson2-apb-cmc-dma.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/dma/loongson/loongson2-apb-cmc-dma.c b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> index 1c9a542edc859..27f8f7a5738d9 100644
> --- a/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> +++ b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> @@ -337,7 +337,6 @@ static void loongson2_cmc_dma_issue_pending(struct dma_chan *chan)
> guard(spinlock_irqsave)(&lchan->vchan.lock);
>
> if (vchan_issue_pending(&lchan->vchan) && !lchan->desc) {
> - dev_dbg(chan2dev(lchan), "vchan %pK: issued\n", &lchan->vchan);
> loongson2_cmc_dma_start_transfer(lchan);
> }
> }
> --
> 2.55.0
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output
2026-09-21 15:16 ` sashiko-bot
@ 2026-09-21 16:04 ` Frank Li
0 siblings, 0 replies; 4+ messages in thread
From: Frank Li @ 2026-09-21 16:04 UTC (permalink / raw)
To: sashiko-reviews; +Cc: Sebastian Andrzej Siewior, dmaengine, vkoul, Frank.Li
On Mon, Sep 21, 2026 at 03:16:14PM +0000, sashiko-bot@kernel.org wrote:
> Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
> - [Low] dmaengine: loongson: unnecessary curly braces around single statement
> --
>
> commit 800bb056df0405c03d12921052d730f7cccef7be
> Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
>
> dmaengine: loongson: Remove the dev_dbg() output
>
> This commit removes the dev_dbg() output from
> loongson2_cmc_dma_issue_pending() since the %pK format modifier is not
> appropriate for general printk output. The debug statement was deemed
> non-essential and is completely removed.
>
> > diff --git a/drivers/dma/loongson/loongson2-apb-cmc-dma.c b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> > index 1c9a542edc859..27f8f7a5738d9 100644
> > --- a/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> > +++ b/drivers/dma/loongson/loongson2-apb-cmc-dma.c
> > @@ -337,7 +337,6 @@ static void loongson2_cmc_dma_issue_pending(struct dma_chan *chan)
> > guard(spinlock_irqsave)(&lchan->vchan.lock);
> >
> > if (vchan_issue_pending(&lchan->vchan) && !lchan->desc) {
> > - dev_dbg(chan2dev(lchan), "vchan %pK: issued\n", &lchan->vchan);
> > loongson2_cmc_dma_start_transfer(lchan);
> > }
>
> [Severity: Low]
> This isn't a bug, but with the removal of the dev_dbg() statement, this if
> block now contains only a single statement. Should the curly braces be
> removed to adhere to the kernel coding style guidelines?
Please fix this also.
Frank
>
> > }
>
> --
> Sashiko AI review · https://sashiko.dev/#/patchset/20260921151312.I8Q8NLnx@linutronix.de?part=1
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-09-21 16:05 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-21 15:13 [PATCH v3] dmaengine: loongson: Remove the dev_dbg() output Sebastian Andrzej Siewior
2026-09-21 15:16 ` sashiko-bot
2026-09-21 16:04 ` Frank Li
2026-09-21 16:03 ` Frank Li
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox