All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Hans Zhang <18255117159@163.com>,
	Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Cc: kw@linux.com, kwilczynski@kernel.org, bhelgaas@google.com,
	cassel@kernel.org, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] genirq/msi: Add the address and data that show MSI/MSIX
Date: Fri, 28 Feb 2025 19:14:04 +0100	[thread overview]
Message-ID: <87v7suc4yb.ffs@tglx> (raw)
In-Reply-To: <86d23e69-e6e5-476b-9582-28352852ea94@163.com>

On Fri, Feb 28 2025 at 23:17, Hans Zhang wrote:
> I'm very sorry that I didn't understand what you meant at the
> beginning.

No problem.

>
> +static void msi_domain_debug_show(struct seq_file *m, struct irq_domain *d,
> +                                 struct irq_data *irqd, int ind)
> +{
> +       struct msi_desc *desc;
> +       bool is_msix;
> +
> +       desc = irq_get_msi_desc(irqd->irq);
> +       if (!desc)
> +               return;
> +
> +       is_msix = desc->pci.msi_attrib.is_msix;
> +       seq_printf(m, "%*s%s:", ind, "", is_msix ? "msix" : "msi");
> +       seq_printf(m, "\n%*saddress_hi: 0x%08x", ind + 1, "",
> +                  desc->msg.address_hi);

No need for these line breaks. You have 100 characters available.

> +       seq_printf(m, "\n%*saddress_lo: 0x%08x", ind + 1, "",
> +                  desc->msg.address_lo);
> +       seq_printf(m, "\n%*smsg_data:   0x%08x\n", ind + 1, "",
> +                  desc->msg.data);
> +}
> +
>   static const struct irq_domain_ops msi_domain_ops = {
>          .alloc          = msi_domain_alloc,
>          .free           = msi_domain_free,
>          .activate       = msi_domain_activate,
>          .deactivate     = msi_domain_deactivate,
>          .translate      = msi_domain_translate,
> +       .debug_show     = msi_domain_debug_show,
>   };

Looks about right.

Thanks,

        tglx

  reply	other threads:[~2025-02-28 18:14 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-27 16:28 [PATCH] genirq/msi: Add the address and data that show MSI/MSIX Hans Zhang
2025-02-27 16:39 ` Manivannan Sadhasivam
2025-02-27 16:49   ` Hans Zhang
2025-02-27 18:03     ` Frank Li
2025-02-28  9:00       ` Hans Zhang
2025-02-27 17:51   ` Thomas Gleixner
2025-02-28  9:04     ` Hans Zhang
2025-02-28 11:26       ` Thomas Gleixner
2025-02-28 15:17         ` Hans Zhang
2025-02-28 18:14           ` Thomas Gleixner [this message]
2025-03-01 12:33             ` Hans Zhang

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=87v7suc4yb.ffs@tglx \
    --to=tglx@linutronix.de \
    --cc=18255117159@163.com \
    --cc=bhelgaas@google.com \
    --cc=cassel@kernel.org \
    --cc=kw@linux.com \
    --cc=kwilczynski@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=manivannan.sadhasivam@linaro.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.