Linux-Amlogic Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Igor Velkov" <iav@iav.lv>
Cc: linux-rtc@vger.kernel.org, devicetree@vger.kernel.org,
	linux-amlogic@lists.infradead.org, robh@kernel.org,
	conor+dt@kernel.org, neil.armstrong@linaro.org,
	"Alexandre Belloni" <alexandre.belloni@bootlin.com>
Subject: Re: [PATCH v2 6/8] dt-bindings: rtc: Add linux,wakeup-states
Date: Mon, 16 Nov 2026 00:34:55 +0000	[thread overview]
Message-ID: <sashiko-outbox-215957@kernel.org> (raw)
In-Reply-To: <20261116-b4-alarmtimer-rtc-priority-v2-6-b2c69721e489@iav.lv>

Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] dt-bindings: rtc: OS-specific mem_sleep states in
  linux,wakeup-states
--

commit 37e39721822efb2f3ac3e76aaec271ff0edbe18b
Author: Igor Velkov <iav@iav.lv>

dt-bindings: rtc: Add linux,wakeup-states

This commit adds a linux,wakeup-states property to the generic RTC binding
schema to specify which suspend states an RTC alarm can wake the system
from, and allows the property in the Amlogic Meson VRTC and NXP PCF8563
bindings.

> diff --git a/Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml b/Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml
> index a89865fa676a6..51cce4b2a7ff3 100644
> --- a/Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml
> +++ b/Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml
> @@ -30,6 +30,8 @@ properties:
>    reg:
>      maxItems: 1
>  
> +  linux,wakeup-states: true
> +
>  required:
>    - compatible
>    - reg
> diff --git a/Documentation/devicetree/bindings/rtc/nxp,pcf8563.yaml b/Documentation/devicetree/bindings/rtc/nxp,pcf8563.yaml
> index 22909a96123e5..e464432e4690f 100644
> --- a/Documentation/devicetree/bindings/rtc/nxp,pcf8563.yaml
> +++ b/Documentation/devicetree/bindings/rtc/nxp,pcf8563.yaml
> @@ -32,6 +32,8 @@ properties:
>    interrupts:
>      maxItems: 1
>  
> +  linux,wakeup-states: true
> +
>    start-year: true
>    wakeup-source: true
>  
> diff --git a/Documentation/devicetree/bindings/rtc/rtc.yaml b/Documentation/devicetree/bindings/rtc/rtc.yaml
> index e46d50b1063e4..54f41858dda47 100644
> --- a/Documentation/devicetree/bindings/rtc/rtc.yaml
> +++ b/Documentation/devicetree/bindings/rtc/rtc.yaml
> @@ -26,6 +26,23 @@ properties:
>        0: not chargeable
>        1: chargeable
>  
> +  linux,wakeup-states:
> +    $ref: /schemas/types.yaml#/definitions/string-array
> +    description:
> +      Suspend states an alarm of this RTC wakes the system from, given
> +      the board and its firmware, named as in /sys/power/mem_sleep. none,
> +      given alone, means the alarm wakes the system from no suspend
> +      state. An RTC without this property is taken to wake the system
> +      from every suspend state.
> +    oneOf:
> +      - items:
> +          enum:
> +            - s2idle
> +            - shallow
> +            - deep
> +      - items:
> +          - const: none
> +
>    quartz-load-femtofarads:
>      description:
>        The capacitive load of the quartz(x-tal), expressed in femto

[Severity: Medium]
Does linux,wakeup-states encode Linux-specific /sys/power/mem_sleep labels
and information already deducible from the hardware description into the
Devicetree ABI?

In particular, s2idle is a Linux software freeze state where wakeup
capability is determined by whether the RTC has an OS interrupt wired via
interrupts, rather than a list of sysfs state names. For
amlogic,meson-vrtc, waking the system only from platform suspend is
inherent to the compatible string because the device is a scratch register
written during meson_vrtc_suspend() for the SCP firmware and has no OS
interrupt line. Finally, allowing none duplicates the absence of the
standard wakeup-source property and permits contradictory combinations such
as setting both wakeup-source and linux,wakeup-states = "none" on the same
node.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261116-b4-alarmtimer-rtc-priority-v2-0-b2c69721e489@iav.lv?part=6

_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

  reply	other threads:[~2026-11-16  0:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-16  0:24 [PATCH v2 0/8] alarmtimer: Pick the wakeup RTC per suspend state Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 1/8] alarmtimer: Replace alarmtimer_get_rtcdev() with alarmtimer_has_rtcdev() Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 2/8] alarmtimer: Move the wakeup state into struct rtc_wakeup Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 3/8] alarmtimer: Replace the freezer delta with per type expiry times Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 4/8] alarmtimer: Register the platform device without a parent Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 5/8] alarmtimer: Keep an RTC per suspend state Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 6/8] dt-bindings: rtc: Add linux,wakeup-states Igor Velkov via B4 Relay
2026-11-16  0:34   ` sashiko-bot [this message]
2026-11-16  0:25 ` [PATCH v2 7/8] alarmtimer: Read the wakeup states of an RTC from linux,wakeup-states Igor Velkov via B4 Relay
2026-11-16  0:25 ` [PATCH v2 8/8] arm64: dts: amlogic: meson-sm1-odroid-hc4: Describe which RTC wakes the board Igor Velkov via B4 Relay

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=sashiko-outbox-215957@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=alexandre.belloni@bootlin.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=iav@iav.lv \
    --cc=linux-amlogic@lists.infradead.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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