All of lore.kernel.org
 help / color / mirror / Atom feed
From: Esben Haabendal <esben@geanix.com>
To: Alexandre Belloni <alexandre.belloni@bootlin.com>
Cc: linux-rtc@vger.kernel.org,  linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,  stable@vger.kernel.org,
	 Patrice Chotard <patrice.chotard@foss.st.com>
Subject: Re: [PATCH 0/6] rtc: Fix problems with missing UIE irqs
Date: Wed, 04 Dec 2024 09:09:19 +0100	[thread overview]
Message-ID: <87cyi798eo.fsf@geanix.com> (raw)
In-Reply-To: <20241203-rtc-uie-irq-fixes-v1-0-01286ecd9f3f@geanix.com> (Esben Haabendal's message of "Tue, 03 Dec 2024 11:45:30 +0100")

Esben Haabendal <esben@geanix.com> writes:

> This fixes a couple of different problems, that can cause RTC (alarm)
> irqs to be missing when generating UIE interrupts.
>
> The first commit fixes a long-standing problem, which has been
> documented in a comment since 2010. This fixes a race that could cause
> UIE irqs to stop being generated, which was easily reproduced by
> timing the use of RTC_UIE_ON ioctl with the seconds tick in the RTC.
>
> The last commit ensures that RTC (alarm) irqs are enabled whenever
> RTC_UIE_ON ioctl is used.
>
> The driver specific commits avoids kernel warnings about unbalanced
> enable_irq/disable_irq, which gets triggered on first RTC_UIE_ON with
> the last commit. Before this series, the same warning should be seen
> on initial RTC_AIE_ON with those drivers.

I don't have access to hardware using cpcap, st-lpc or tps6586x rtc
drivers, so I have not been able to test those 3 patches.

/Esben

> Signed-off-by: Esben Haabendal <esben@geanix.com>
> ---
> Esben Haabendal (6):
>       rtc: interface: Fix long-standing race when setting alarm
>       rtc: isl12022: Fix initial enable_irq/disable_irq balance
>       rtc: cpcap: Fix initial enable_irq/disable_irq balance
>       rtc: st-lpc: Fix initial enable_irq/disable_irq balance
>       rtc: tps6586x: Fix initial enable_irq/disable_irq balance
>       rtc: interface: Ensure alarm irq is enabled when UIE is enabled
>
>  drivers/rtc/interface.c    | 27 +++++++++++++++++++++++++++
>  drivers/rtc/rtc-cpcap.c    |  1 +
>  drivers/rtc/rtc-isl12022.c |  1 +
>  drivers/rtc/rtc-st-lpc.c   |  1 +
>  drivers/rtc/rtc-tps6586x.c |  1 +
>  5 files changed, 31 insertions(+)
> ---
> base-commit: 40384c840ea1944d7c5a392e8975ed088ecf0b37
> change-id: 20241203-rtc-uie-irq-fixes-f2838782d0f8
>
> Best regards,


      parent reply	other threads:[~2024-12-04  8:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-03 10:45 [PATCH 0/6] rtc: Fix problems with missing UIE irqs Esben Haabendal
2024-12-03 10:45 ` [PATCH 1/6] rtc: interface: Fix long-standing race when setting alarm Esben Haabendal
2024-12-03 10:45 ` [PATCH 2/6] rtc: isl12022: Fix initial enable_irq/disable_irq balance Esben Haabendal
2024-12-03 10:45 ` [PATCH 3/6] rtc: cpcap: " Esben Haabendal
2024-12-03 10:45 ` [PATCH 4/6] rtc: st-lpc: " Esben Haabendal
2024-12-03 13:25   ` Alexandre Belloni
2024-12-03 13:37     ` Esben Haabendal
2024-12-03 10:45 ` [PATCH 5/6] rtc: tps6586x: " Esben Haabendal
2024-12-03 10:45 ` [PATCH 6/6] rtc: interface: Ensure alarm irq is enabled when UIE is enabled Esben Haabendal
2024-12-04  8:09 ` Esben Haabendal [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=87cyi798eo.fsf@geanix.com \
    --to=esben@geanix.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=patrice.chotard@foss.st.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.