From: Sean Young <sean@mess.org>
To: linux-media@vger.kernel.org, Sean Young <sean@mess.org>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Zhangfei Gao <zhangfei.gao@linaro.org>,
Guoxiong Yan <yanguoxiong@huawei.com>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH 7/7] media: ir-hix5hd2: Ensure rdev is setup before interrupts are enabled
Date: Fri, 10 Jul 2026 09:53:35 +0100 [thread overview]
Message-ID: <81c6f7a6243bbe73fbac2d9bd763b0e40b400125.1783673420.git.sean@mess.org> (raw)
In-Reply-To: <cover.1783673420.git.sean@mess.org>
Once the interrupt handler is enabled, priv->rdev can be used. Ensure
it is setup correctly so there is no race condition.
Fixes: a84fcdaa9058 ("[media] rc: Introduce hix5hd2 IR transmitter driver")
Signed-off-by: Sean Young <sean@mess.org>
---
drivers/media/rc/ir-hix5hd2.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/media/rc/ir-hix5hd2.c b/drivers/media/rc/ir-hix5hd2.c
index 1b061e4a3dcf..aa3de4d57a58 100644
--- a/drivers/media/rc/ir-hix5hd2.c
+++ b/drivers/media/rc/ir-hix5hd2.c
@@ -316,6 +316,9 @@ static int hix5hd2_ir_probe(struct platform_device *pdev)
if (ret < 0)
goto clkerr;
+ priv->rdev = rdev;
+ priv->dev = dev;
+
if (devm_request_irq(dev, priv->irq, hix5hd2_ir_rx_interrupt,
0, pdev->name, priv) < 0) {
dev_err(dev, "IRQ %d register failed\n", priv->irq);
@@ -323,8 +326,6 @@ static int hix5hd2_ir_probe(struct platform_device *pdev)
goto regerr;
}
- priv->rdev = rdev;
- priv->dev = dev;
platform_set_drvdata(pdev, priv);
return ret;
--
2.55.0
prev parent reply other threads:[~2026-07-10 8:53 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1783673420.git.sean@mess.org>
2026-07-10 8:53 ` [PATCH 1/7] media: streamzap: Add missing rc_unregister_device() Sean Young
2026-07-10 8:53 ` [PATCH 2/7] media: redrat3: Ensure rc device is freed if enable_detector() fails Sean Young
2026-07-10 8:53 ` [PATCH 3/7] media: redrat3: Ensure we don't read beyond the end of the packet Sean Young
2026-07-10 8:53 ` [PATCH 4/7] media: sunxi-cir: Ensure no more interrupts can occur before free Sean Young
2026-07-10 8:53 ` [PATCH 5/7] media: meson-ir-tx: Ensure clock is disabled on unbind Sean Young
2026-07-12 13:26 ` Martin Blumenstingl
2026-07-10 8:53 ` [PATCH 6/7] media: meson-ir-tx: Ensure rc_free_device() is called " Sean Young
2026-07-12 13:23 ` Martin Blumenstingl
2026-07-10 8:53 ` Sean Young [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=81c6f7a6243bbe73fbac2d9bd763b0e40b400125.1783673420.git.sean@mess.org \
--to=sean@mess.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=yanguoxiong@huawei.com \
--cc=zhangfei.gao@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 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®