From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: linux-kernel@vger.kernel.org,
Bartosz Golaszewski <bgolaszewski@baylibre.com>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
stable@vger.kernel.org
Subject: Re: [PATCH v4.9..v4.19] rtc: rx8010: don't modify the global rtc ops
Date: Tue, 3 Nov 2020 19:48:23 +0100 [thread overview]
Message-ID: <20201103184823.GA173459@kroah.com> (raw)
In-Reply-To: <20201103172901.18231-1-brgl@bgdev.pl>
On Tue, Nov 03, 2020 at 06:29:01PM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
>
> The way the driver is implemented is buggy for the (admittedly unlikely)
> use case where there are two RTCs with one having an interrupt configured
> and the second not. This is caused by the fact that we use a global
> rtc_class_ops struct which we modify depending on whether the irq number
> is present or not.
>
> Fix it by using two const ops structs with and without alarm operations.
> While at it: not being able to request a configured interrupt is an error
> so don't ignore it and bail out of probe().
>
> Fixes: ed13d89b08e3 ("rtc: Add Epson RX8010SJ RTC driver")
> Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
> Cc: stable@vger.kernel.org
> Link: https://lore.kernel.org/r/20200914154601.32245-2-brgl@bgdev.pl
> ---
> drivers/rtc/rtc-rx8010.c | 24 +++++++++++++++++-------
> 1 file changed, 17 insertions(+), 7 deletions(-)
Now queued up, thanks!
greg k-h
prev parent reply other threads:[~2020-11-03 18:48 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-03 17:29 [PATCH v4.9..v4.19] rtc: rx8010: don't modify the global rtc ops Bartosz Golaszewski
2020-11-03 18:48 ` Greg Kroah-Hartman [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=20201103184823.GA173459@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=alexandre.belloni@bootlin.com \
--cc=bgolaszewski@baylibre.com \
--cc=brgl@bgdev.pl \
--cc=linux-kernel@vger.kernel.org \
--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