mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "David Wang" <00107082@163.com>
To: "Geert Uytterhoeven" <geert+renesas@glider.be>
Cc: "Thomas Gleixner" <tglx@linutronix.de>,
	"Michael Ellerman" <mpe@ellerman.id.au>,
	"Nicholas Piggin" <npiggin@gmail.com>,
	"Christophe Leroy" <christophe.leroy@csgroup.eu>,
	"Naveen N Rao" <naveen@kernel.org>,
	"Madhavan Srinivasan" <maddy@linux.ibm.com>,
	"Marek Behún" <kabel@kernel.org>,
	"Bjorn Andersson" <andersson@kernel.org>,
	"Konrad Dybcio" <konradybcio@kernel.org>,
	linuxppc-dev@lists.ozlabs.org, linux-arm-msm@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re:[PATCH] genirq: Remove leading space from .irq_print_chip() callbacks
Date: Tue, 3 Dec 2024 23:33:45 +0800 (CST)	[thread overview]
Message-ID: <6392704d.c158.1938d27f38e.Coremail.00107082@163.com> (raw)
In-Reply-To: <a779f3f44c24716d783d782c935be9fe4f410bff.1733238060.git.geert+renesas@glider.be>

HI, 
At 2024-12-03 23:02:31, "Geert Uytterhoeven" <geert+renesas@glider.be> wrote:
>The space separator was factored out from the multiple chip name prints,
>but several irq_chip.irq_print_chip() callbacks still print a leading
>space.  Remove the superfluous double spaces.
>
>Fixes: 9d9f204bdf7243bf ("genirq/proc: Add missing space separator back")
>Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
>---
>Not even compile-tested...
>
>Feel free to fold this into the original, and fix the spelling
>s/previosuly/previously/ while at it.
>---
> arch/powerpc/sysdev/fsl_msi.c          | 2 +-
> drivers/bus/moxtet.c                   | 2 +-
> drivers/irqchip/irq-partition-percpu.c | 2 +-
> drivers/soc/qcom/smp2p.c               | 2 +-
> 4 files changed, 4 insertions(+), 4 deletions(-)
>
>diff --git a/arch/powerpc/sysdev/fsl_msi.c b/arch/powerpc/sysdev/fsl_msi.c
>index 1aa0cb097c9c9d7c..7b9a5ea9cad9d3c7 100644
>--- a/arch/powerpc/sysdev/fsl_msi.c
>+++ b/arch/powerpc/sysdev/fsl_msi.c
>@@ -75,7 +75,7 @@ static void fsl_msi_print_chip(struct irq_data *irqd, struct seq_file *p)
> 	srs = (hwirq >> msi_data->srs_shift) & MSI_SRS_MASK;
> 	cascade_virq = msi_data->cascade_array[srs]->virq;
> 
>-	seq_printf(p, " fsl-msi-%d", cascade_virq);
>+	seq_printf(p, "fsl-msi-%d", cascade_virq);
> }
> 
> 
>diff --git a/drivers/bus/moxtet.c b/drivers/bus/moxtet.c
>index 6276551d79680e85..1e57ebfb76229aa0 100644
>--- a/drivers/bus/moxtet.c
>+++ b/drivers/bus/moxtet.c
>@@ -657,7 +657,7 @@ static void moxtet_irq_print_chip(struct irq_data *d, struct seq_file *p)
> 
> 	id = moxtet->modules[pos->idx];
> 
>-	seq_printf(p, " moxtet-%s.%i#%i", mox_module_name(id), pos->idx,
>+	seq_printf(p, "moxtet-%s.%i#%i", mox_module_name(id), pos->idx,
> 		   pos->bit);
> }
> 
>diff --git a/drivers/irqchip/irq-partition-percpu.c b/drivers/irqchip/irq-partition-percpu.c
>index 8e76d2913e6bebbf..4441ffe149ea0d96 100644
>--- a/drivers/irqchip/irq-partition-percpu.c
>+++ b/drivers/irqchip/irq-partition-percpu.c
>@@ -98,7 +98,7 @@ static void partition_irq_print_chip(struct irq_data *d, struct seq_file *p)
> 	struct irq_chip *chip = irq_desc_get_chip(part->chained_desc);
> 	struct irq_data *data = irq_desc_get_irq_data(part->chained_desc);
> 
>-	seq_printf(p, " %5s-%lu", chip->name, data->hwirq);
>+	seq_printf(p, "%5s-%lu", chip->name, data->hwirq);
> }
> 
> static struct irq_chip partition_irq_chip = {
>diff --git a/drivers/soc/qcom/smp2p.c b/drivers/soc/qcom/smp2p.c
>index 4783ab1adb8d953b..a3e88ced328a91f1 100644
>--- a/drivers/soc/qcom/smp2p.c
>+++ b/drivers/soc/qcom/smp2p.c
>@@ -365,7 +365,7 @@ static void smp2p_irq_print_chip(struct irq_data *irqd, struct seq_file *p)
> {
> 	struct smp2p_entry *entry = irq_data_get_irq_chip_data(irqd);
> 
>-	seq_printf(p, " %8s", dev_name(entry->smp2p->dev));
>+	seq_printf(p, "%8s", dev_name(entry->smp2p->dev));
> }
> 
> static struct irq_chip smp2p_irq_chip = {
>-- 
>2.34.1

Match with my check result against .irq_print_chip implementation under drivers.
But I think "%8s" and "%5s-%lu" should be "%s" and "%s-%lu", otherwise there would still
be leading spaces when the device name string is short.


Thanks
David

  reply	other threads:[~2024-12-03 15:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-03 15:02 [PATCH] " Geert Uytterhoeven
2024-12-03 15:33 ` David Wang [this message]
2024-12-10 15:48   ` Geert Uytterhoeven

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=6392704d.c158.1938d27f38e.Coremail.00107082@163.com \
    --to=00107082@163.com \
    --cc=andersson@kernel.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=geert+renesas@glider.be \
    --cc=kabel@kernel.org \
    --cc=konradybcio@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=maddy@linux.ibm.com \
    --cc=mpe@ellerman.id.au \
    --cc=naveen@kernel.org \
    --cc=npiggin@gmail.com \
    --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

all inboxes | Powered by JetHome®