From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Lukas Wunner <lukas@wunner.de>
Cc: Mark Brown <broonie@kernel.org>,
Jarkko Nikula <jarkko.nikula@linux.intel.com>,
linux-spi@vger.kernel.org, Baruch Siach <baruch@tkos.co.il>,
Serge Semin <Sergey.Semin@baikalelectronics.ru>,
Tsuchiya Yuto <kitakar@gmail.com>,
Daniel Mack <daniel@zonque.org>,
Haojian Zhuang <haojian.zhuang@gmail.com>,
Robert Jarzmik <robert.jarzmik@free.fr>
Subject: Re: [PATCH 0/3] Intel SPI unbind fixes
Date: Mon, 25 May 2020 16:23:29 +0300 [thread overview]
Message-ID: <20200525132329.GY1634618@smile.fi.intel.com> (raw)
In-Reply-To: <cover.1590408496.git.lukas@wunner.de>
On Mon, May 25, 2020 at 02:25:00PM +0200, Lukas Wunner wrote:
> Fix unbind ordering issues in the Designware and PXA2xx SPI controllers
> built into Intel SoCs.
>
> To test, you'll also need the following commit:
> https://git.kernel.org/broonie/spi/c/84855678add8
>
> This is compile-tested only, so please review and test thoroughly.
>
> Pay particular attention to the IRQ handlers dw_spi_irq() and ssp_int():
> Both drivers request the interrupt with IRQF_SHARED, so the IRQ handler
> may run even though the SPI controller itself hasn't signalled an
> interrupt. The IRQ is requested before registering the controller and
> freed after unregistering the controller. Thus, the IRQ handler should
> immediately bail out if the controller is not yet or no longer registered,
> e.g. by checking in the controller's registers whether an interrupt is
> actually pending. The drivers may need to disable interrupts in the
> controllers' registers upon unbinding and they need to make sure that
> the registers are accessible until the IRQ is freed.
>
> I don't have a datasheet for these SPI controllers but I hope someone
> who is more familiar with them will be able to check for correctness
> of the IRQ handling.
Thank you for this!
I reviewed all three, but I have no means to reliably test it. From the
description and logic point of view this sounds correct. So, let's wait for
Tsuchiya Yuto to test and confirm that it's right way to go.
>
> Lukas Wunner (3):
> spi: dw: Fix controller unregister order
> spi: pxa2xx: Fix controller unregister order
> spi: pxa2xx: Fix runtime PM ref imbalance on probe error
>
> drivers/spi/spi-dw.c | 4 +++-
> drivers/spi/spi-pxa2xx.c | 5 +++--
> 2 files changed, 6 insertions(+), 3 deletions(-)
>
> --
> 2.25.0
>
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2020-05-25 13:23 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-25 12:25 [PATCH 0/3] Intel SPI unbind fixes Lukas Wunner
2020-05-25 12:25 ` [PATCH 1/3] spi: dw: Fix controller unregister order Lukas Wunner
2020-05-25 13:15 ` Andy Shevchenko
2020-05-25 12:25 ` [PATCH 2/3] spi: pxa2xx: " Lukas Wunner
2020-05-25 13:21 ` Andy Shevchenko
2020-05-26 7:39 ` Lukas Wunner
2020-05-26 8:22 ` Andy Shevchenko
2020-05-27 12:09 ` Tsuchiya Yuto
2020-05-27 12:27 ` Andy Shevchenko
2020-05-27 13:14 ` Tsuchiya Yuto
2020-05-28 7:02 ` Tsuchiya Yuto
2020-05-28 8:41 ` Andy Shevchenko
2020-05-28 9:31 ` Lukas Wunner
2020-05-29 13:54 ` Tsuchiya Yuto
2020-05-25 12:25 ` [PATCH 3/3] spi: pxa2xx: Fix runtime PM ref imbalance on probe error Lukas Wunner
2020-05-25 13:12 ` Andy Shevchenko
2020-05-26 8:46 ` Jarkko Nikula
2020-05-25 13:23 ` Andy Shevchenko [this message]
2020-05-26 16:46 ` [PATCH 0/3] Intel SPI unbind fixes Mark Brown
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=20200525132329.GY1634618@smile.fi.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=Sergey.Semin@baikalelectronics.ru \
--cc=baruch@tkos.co.il \
--cc=broonie@kernel.org \
--cc=daniel@zonque.org \
--cc=haojian.zhuang@gmail.com \
--cc=jarkko.nikula@linux.intel.com \
--cc=kitakar@gmail.com \
--cc=linux-spi@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=robert.jarzmik@free.fr \
/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).