From: "hasegawa-hitomi@fujitsu.com" <hasegawa-hitomi@fujitsu.com>
To: Jiri Slaby <jirislaby@kernel.org>
Cc: "arnd@arndb.de" <arnd@arndb.de>,
"olof@lixom.net" <olof@lixom.net>,
"catalin.marinas@arm.com" <catalin.marinas@arm.com>,
"will@kernel.org" <will@kernel.org>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"jason.wessel@windriver.com" <jason.wessel@windriver.com>,
"daniel.thompson@linaro.org" <daniel.thompson@linaro.org>,
"dianders@chromium.org" <dianders@chromium.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kgdb-bugreport@lists.sourceforge.net"
<kgdb-bugreport@lists.sourceforge.net>,
"peterz@infradead.org" <peterz@infradead.org>,
"sumit.garg@linaro.org" <sumit.garg@linaro.org>,
"linux-serial@vger.kernel.org" <linux-serial@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"soc@kernel.org" <soc@kernel.org>
Subject: Re: [PATCH v4 1/1] soc: fujitsu: Add A64FX diagnostic interrupt driver
Date: Tue, 17 May 2022 09:53:57 +0000 [thread overview]
Message-ID: <OSZPR01MB7050C926426AF82B7ADE86B8EBCE9@OSZPR01MB7050.jpnprd01.prod.outlook.com> (raw)
In-Reply-To: <48cfa0b3-0424-81bd-ac6a-d631184b71b7@kernel.org>
Hi Jiri,
> I'm not sure why you cc linux-serial, but anyway, comments below :).
I used sysrq until the last version, so I still included kernel-serial in
the destination. I am not planning to use sysrq now, so I will remove it
from the destination from the next version.
Thank you for your comment.
> > +struct a64fx_diag_priv {
> > + int irq;
> > + void __iomem *mmsc_reg_base;
> > + bool has_nmi;
>
> There are unnecessary holes in the struct. If you reorder it, you drop some
> alignment. Like: pointer, int, bool.
> > + u32 mmsc;
> > + void __iomem *diag_status_reg_addr;
>
> I'm not sure what soc/ maintainers prefer, but inverted xmas tree would look/read
> better.
> > + priv = devm_kzalloc(dev, sizeof(struct a64fx_diag_priv),
> > +GFP_KERNEL);
>
> Don't we prefer sizeof(*priv)?
> > + ret = request_irq(priv->irq, &a64fx_diag_handler_irq,
> > + irq_flags, "a64fx_diag_irq", NULL);
> > + if (ret) {
> > + dev_err(dev, "cannot register IRQ %d\n", ret);
>
> No a64fx_diag_interrupt_disable()?
> > + priv->has_nmi = false;
>
> No need to set zeroed priv member to zero.
I understand. I will fix it as per your comment. Thank you.
> > + enable_nmi(priv->irq);
>
> Provided the above, I don't immediatelly see, what's the purpose of
> IRQF_NO_AUTOEN then?
It seems that request_nmi() requires IRQF_NO_AUTOEN.
> > +static int __exit a64fx_diag_remove(struct platform_device *pdev)
>
> Is __exit appropriate here at all -- I doubt that.
I will remove __exit as it seems unnecessary as you suggested.
Also, I will correct BMC_DIAG_INTERRUPT_STATUS_OFFSET
and BMC_DIAG_INTERRUPT_ENABLE_OFFSET.
Thank you.
Hitomi Hasegawa
next prev parent reply other threads:[~2022-05-17 9:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-11 6:21 [PATCH v4 0/1] " Hitomi Hasegawa
2022-05-11 6:21 ` [PATCH v4 1/1] " Hitomi Hasegawa
2022-05-11 6:47 ` Jiri Slaby
2022-05-17 9:53 ` hasegawa-hitomi [this message]
2022-05-11 6:51 ` Jiri Slaby
[not found] ` <Yntcn4esjJRS50Am@kroah.com>
2022-05-13 10:13 ` Arnd Bergmann
2022-05-17 9:54 ` hasegawa-hitomi
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=OSZPR01MB7050C926426AF82B7ADE86B8EBCE9@OSZPR01MB7050.jpnprd01.prod.outlook.com \
--to=hasegawa-hitomi@fujitsu.com \
--cc=arnd@arndb.de \
--cc=catalin.marinas@arm.com \
--cc=daniel.thompson@linaro.org \
--cc=dianders@chromium.org \
--cc=gregkh@linuxfoundation.org \
--cc=jason.wessel@windriver.com \
--cc=jirislaby@kernel.org \
--cc=kgdb-bugreport@lists.sourceforge.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=olof@lixom.net \
--cc=peterz@infradead.org \
--cc=soc@kernel.org \
--cc=sumit.garg@linaro.org \
--cc=will@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
all inboxes | Powered by JetHome®