From: "Winiarska, Iwona" <iwona.winiarska@intel.com>
To: "runyu.xiao@seu.edu.cn" <runyu.xiao@seu.edu.cn>
Cc: "jianhao.xu@seu.edu.cn" <jianhao.xu@seu.edu.cn>,
"joel@jms.id.au" <joel@jms.id.au>,
"andrew@codeconstruct.com.au" <andrew@codeconstruct.com.au>,
"linux-aspeed@lists.ozlabs.org" <linux-aspeed@lists.ozlabs.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"Chen, Ryan" <ryan_chen@aspeedtech.com>,
"stable@vger.kernel.org" <stable@vger.kernel.org>,
"billy_tsai@aspeedtech.com" <billy_tsai@aspeedtech.com>,
"openbmc@lists.ozlabs.org" <openbmc@lists.ozlabs.org>
Subject: Re: [PATCH] peci: aspeed: Initialize state before requesting IRQ
Date: Thu, 17 Sep 2026 20:55:23 +0000 [thread overview]
Message-ID: <94b5b07248606ddfa02b189442dc81beef423d5b.camel@intel.com> (raw)
In-Reply-To: <20260902142600.3580382-1-runyu.xiao@seu.edu.cn>
On Wed, 2026-09-02 at 22:26 +0800, Runyu Xiao wrote:
> The PECI interrupt handler uses the lock and completion object as soon as
> the interrupt is delivered. Initialize both before registering the
> handler so an early interrupt cannot access uninitialized state.
>
> Fixes: a85e4c52086c ("peci: Add peci-aspeed controller driver")
> Cc: stable@vger.kernel.org
> Assisted-by: Codex:GPT-5
> Signed-off-by: Runyu Xiao <runyu.xiao@seu.edu.cn>
Reviewed-by: Iwona Winiarska <iwona.winiarska@intel.com>
Thanks
-Iwona
> ---
> drivers/peci/controller/peci-aspeed.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/peci/controller/peci-aspeed.c
> b/drivers/peci/controller/peci-aspeed.c
> index a0c99ecf7..5d7f4f8fd 100644
> --- a/drivers/peci/controller/peci-aspeed.c
> +++ b/drivers/peci/controller/peci-aspeed.c
> @@ -529,14 +529,14 @@ static int aspeed_peci_probe(struct platform_device
> *pdev)
> if (priv->irq < 0)
> return priv->irq;
>
> + init_completion(&priv->xfer_complete);
> + spin_lock_init(&priv->lock);
> +
> ret = devm_request_irq(&pdev->dev, priv->irq,
> aspeed_peci_irq_handler,
> 0, "peci-aspeed", priv);
> if (ret)
> return ret;
>
> - init_completion(&priv->xfer_complete);
> - spin_lock_init(&priv->lock);
> -
> priv->rst = devm_reset_control_get(&pdev->dev, NULL);
> if (IS_ERR(priv->rst))
> return dev_err_probe(priv->dev, PTR_ERR(priv->rst),
prev parent reply other threads:[~2026-09-17 20:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-02 14:26 Runyu Xiao
2026-09-17 20:55 ` Winiarska, Iwona [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=94b5b07248606ddfa02b189442dc81beef423d5b.camel@intel.com \
--to=iwona.winiarska@intel.com \
--cc=andrew@codeconstruct.com.au \
--cc=billy_tsai@aspeedtech.com \
--cc=jianhao.xu@seu.edu.cn \
--cc=joel@jms.id.au \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-aspeed@lists.ozlabs.org \
--cc=linux-kernel@vger.kernel.org \
--cc=openbmc@lists.ozlabs.org \
--cc=runyu.xiao@seu.edu.cn \
--cc=ryan_chen@aspeedtech.com \
--cc=stable@vger.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®