Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1079068iob; Wed, 4 May 2022 14:13:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwQt7xv56q1qn1llzViUIxX+8IsizR5BDl7ynQlzTnCUUDvrmGC85gURcHGI2/7pWUEdivS X-Received: by 2002:a17:907:a422:b0:6ef:da5e:e2ee with SMTP id sg34-20020a170907a42200b006efda5ee2eemr21505128ejc.306.1651698828304; Wed, 04 May 2022 14:13:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651698828; cv=none; d=google.com; s=arc-20160816; b=vlbwDJzxO78d9z3+TBNPk5R9q4TYj1Zs7f9ysbC1njo13wbUsGnKuLU0Yw8ipfgOeW ieCRHfHUDdHwBG6REJOFguQkZeljHTCOkMTDh3tSZT1afZ4B/J75Q/7xDMEZQAciQfzu v5vdHKGtyrXxi616k8AKhb0PJSLuJlTOnrUS9PUQRrClyI8EZW4tt5Jv96By2cHjsQw1 fy3xdV4aWJDSrGLZqLkIpx4xxwd4RBWyHgj61rtp3XYRTZO9P0Ij9o2NWFYnUHCRM2EQ r0ckrv2lFFzX+phFTkhIXzflwLG3srM+uU6IdQBy9luE0zefORVnTkGmHfYy867uieHs qXYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=+hUwQLI04KRlF0eu0GKC8X4hwLKHloFuBKJTjH0IlCc=; b=qNWVnvPwOi3vgdzB9j3bnYls2HeUt1alHOiG+fcO/w8TwnW8gp59yc8Wus58eCZ46E d/8Q7pxxJpnWDpSxOMZzL4MSYZ9MH35I5lgWU+zMksbv9SYQjHqIGh94mCMhb2Y9mRPy Zrr5PUq2x4ygq+MGYWa76zqXksHTPaoQ1GTHswztiriTdf99YNOOX+j6QwlzCAAfJALX mqtZDbD5j+9tmYFqDpmz/DFJr/iENo402ar6lYSNS6M+Einj+LMAHFyLTTB57mt2+1Q+ T2ZzLwcyioHlVXmse5tONYeDG6qslxS6SPjwISz9RJaAEFo4JwFEcBoiscNryMyQF+Yv 1REA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=fqvBj59Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z4-20020a05640240c400b00427d85e06f1si6807282edb.366.2022.05.04.14.13.13; Wed, 04 May 2022 14:13:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=fqvBj59Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355691AbiEDUbe (ORCPT + 99 others); Wed, 4 May 2022 16:31:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36658 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229703AbiEDUb2 (ORCPT ); Wed, 4 May 2022 16:31:28 -0400 Received: from relay8-d.mail.gandi.net (relay8-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::228]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7DB404F9CB; Wed, 4 May 2022 13:27:50 -0700 (PDT) Received: (Authenticated sender: alexandre.belloni@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id 3E3B01BF205; Wed, 4 May 2022 20:27:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1651696069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=+hUwQLI04KRlF0eu0GKC8X4hwLKHloFuBKJTjH0IlCc=; b=fqvBj59ZoYRwrHWryJr471246MpSLAYY4m41aJ6HilGtIRQMWbqhO4hmBKkhHwBBvF2lTV Jt91bcWKFse6faQY3nlsQQ7xmv8CUWvhkFoTd8objUhzv8KlNljP5hTbi+zRk72j+9PpgP nuH9ZziWeuOSsCz1jvLoNyE+PToIiocvRcWuPPaG7lWSU5cF1eOM5fg6UwaB1baMV3GMdC no8PHNvic3bFE6ynZBW0/aY5s7wYX4HLY62AOd0mRURakV8OSg9WopjsPzmj2MTSIYIg87 9iOIuqog9D3C3zbA1szY1klVwOD62J7lbtrBCwOCHeEeGeYshsiRJVOMco7BxQ== Date: Wed, 4 May 2022 22:27:47 +0200 From: Alexandre Belloni To: Valentin Caron Cc: Alessandro Zummo , Rob Herring , Krzysztof Kozlowski , Alexandre Torgue , Gabriel Fernandez , Amelie Delaunay , linux-rtc@vger.kernel.org, devicetree@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/6] dt-bindings: rtc: stm32: add alarm A out property to select output Message-ID: References: <20220504130233.330983-1-valentin.caron@foss.st.com> <20220504130617.331290-1-valentin.caron@foss.st.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220504130617.331290-1-valentin.caron@foss.st.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, On 04/05/2022 15:06:13+0200, Valentin Caron wrote: > STM32 RTC can pulse some SOC pins when an alarm of RTC expires. > > This patch adds property to activate alarm A output. The pulse can > output on three pins RTC_OUT1, RTC_OUT2, RTC_OUT2_RMP > (PC13, PB2, PI8 on stm32mp15) (PC13, PB2, PI1 on stm32mp13). > > Signed-off-by: Valentin Caron > --- > .../devicetree/bindings/rtc/st,stm32-rtc.yaml | 19 ++++++++++++++++++- > 1 file changed, 18 insertions(+), 1 deletion(-) > > diff --git a/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml b/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > index 56d46ea35c5d..71e02604e8de 100644 > --- a/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > +++ b/Documentation/devicetree/bindings/rtc/st,stm32-rtc.yaml > @@ -59,6 +59,13 @@ properties: > Refer to for the supported values. > Pinctrl state named "default" may be defined to reserve pin for RTC output. > > + st,alarm: > + $ref: "/schemas/types.yaml#/definitions/uint32" > + description: | > + To select and enable RTC Alarm A output. > + Refer to for the supported values. > + Pinctrl state named "default" may be defined to reserve pin for RTC output. > + > allOf: > - if: > properties: > @@ -75,6 +82,9 @@ allOf: > st,lsco: > maxItems: 0 > > + st,alarm: > + maxItems: 0 > + > clock-names: false > > required: > @@ -95,6 +105,9 @@ allOf: > st,lsco: > maxItems: 0 > > + st,alarm: > + maxItems: 0 > + > required: > - clock-names > - st,syscfg > @@ -117,6 +130,9 @@ allOf: > st,lsco: > maxItems: 1 > > + st,alarm: > + maxItems: 1 > + > required: > - clock-names > > @@ -153,8 +169,9 @@ examples: > clocks = <&rcc RTCAPB>, <&rcc RTC>; > clock-names = "pclk", "rtc_ck"; > interrupts = ; > + st,alarm = ; > st,lsco = ; Shouldn't that be exactly the opposite? You have two pins that can output different functions. The property should be the pin and the value the function. I'd go even further and I would say this is actually pinmuxing. -- Alexandre Belloni, co-owner and COO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com