From: Fabio Estevam <festevam@gmail.com>
To: Marco Felsch <m.felsch@pengutronix.de>
Cc: Igor Plyatov <plyatov@gmail.com>, Zhang Rui <rui.zhang@intel.com>,
Eduardo Valentin <edubezval@gmail.com>,
Daniel Lezcano <daniel.lezcano@linaro.org>,
Amit Kucheria <amit.kucheria@verdurent.com>,
Shawn Guo <shawnguo@kernel.org>,
Sascha Hauer <s.hauer@pengutronix.de>,
Pengutronix Kernel Team <kernel@pengutronix.de>,
NXP Linux Team <linux-imx@nxp.com>,
linux-pm@vger.kernel.org,
"moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE"
<linux-arm-kernel@lists.infradead.org>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: Issue with imx_get_temp()
Date: Tue, 3 Dec 2019 10:13:11 -0300 [thread overview]
Message-ID: <CAOMZO5BniszDhWKkoWY=P62kv9cY160r9P=pjpbSOZasxJvdBA@mail.gmail.com> (raw)
In-Reply-To: <CAOMZO5Cn993y9VeFN6hPO3-cfNnUKiuFd_rqAZ8htz=dO6t6ig@mail.gmail.com>
On Tue, Dec 3, 2019 at 9:04 AM Fabio Estevam <festevam@gmail.com> wrote:
>
> Hi Marco,
>
> On Tue, Dec 3, 2019 at 7:15 AM Marco Felsch <m.felsch@pengutronix.de> wrote:
>
> > Mh.. it seems that the irq gets enabled before a irq-handler is
> > registered. As your backlog shows the thermal_zone_device_register()
> > triggers a imx_get_temp() and during boot the irq_enabled is false and
> > it seems that your temperature is below the alarm_temp. So in such a
> > case the enable_irq() is executed. I don't know what happens if we
> > enable a irq without a irq-handler.
>
> I think your analysis makes sense.
>
> Should we move the ' data->irq_enabled = true' just prior to calling
> thermal_zone_device_register()?
Or maybe we could call thermal_zone_device_register() later?
Igor,
Does the following patch help?
http://code.bulix.org/l3rz2e-982595
next prev parent reply other threads:[~2019-12-03 13:13 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-02 13:45 Issue with imx_get_temp() Igor Plyatov
2019-12-03 10:15 ` Marco Felsch
2019-12-03 12:04 ` Fabio Estevam
2019-12-03 13:13 ` Fabio Estevam [this message]
2019-12-03 14:36 ` Igor Plyatov
2019-12-10 12:19 ` Fabio Estevam
2020-01-09 12:17 ` Fabio Estevam
[not found] <de442143-568d-5fbf-ed0c-d169e33e5d66@gmail.com>
2019-12-02 13:49 ` Fabio Estevam
2019-12-03 14:34 ` Igor Plyatov
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='CAOMZO5BniszDhWKkoWY=P62kv9cY160r9P=pjpbSOZasxJvdBA@mail.gmail.com' \
--to=festevam@gmail.com \
--cc=amit.kucheria@verdurent.com \
--cc=daniel.lezcano@linaro.org \
--cc=edubezval@gmail.com \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=m.felsch@pengutronix.de \
--cc=plyatov@gmail.com \
--cc=rui.zhang@intel.com \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@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;
as well as URLs for NNTP newsgroup(s).