Message ID | 20230201143431.863784-5-frieder@fris.de |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp317301wrn; Wed, 1 Feb 2023 06:44:29 -0800 (PST) X-Google-Smtp-Source: AK7set98m0aUWApfYq+nr2MN4/xEDyI+ngCCH1Ny1jcjEPvyK1ccxnMdSx1P1Kz4PNfcd3I54mOJ X-Received: by 2002:a17:90b:4d08:b0:229:932:a0f3 with SMTP id mw8-20020a17090b4d0800b002290932a0f3mr2456452pjb.27.1675262669144; Wed, 01 Feb 2023 06:44:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675262669; cv=none; d=google.com; s=arc-20160816; b=uA3VW8a4AU5Se0spzpjg2LFOTmzWEZDH/2RPBNr4mfRD5Ub2YmFng46SoBUwKgWaY4 I/HVULjJD+dhWJE3RmzsxkLMkW69bFWvElF7q6UkzGJsrcSMRYissYkG3s5fAUcb+7zC 0G5opSVoCcb7q5CjfVt43C7xLIB72Ox9J5F+sI+vPIBAEzvu/dPFPFByyPznABLmLzbk xBU0tb4pSDtSnp6IpJwsR22jLGwbArhfoXdj2F1Khl3wZQXiTfk+t6ZcJpef/aTE34Rq mwRaQFDydgiTgpnEc8cLudKgzEkBF2TGS/1MAws2oxNSfmm9QbOkRFpMXoZDe/y7JyY2 9L8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=lDLZ/xjvrtcN+1CWCH6iD2koCwn6Eb1LpwYqcz6QtGM=; b=PWOVGRFGtOq7fAZaSgjv0ZwzahqtSfVtvzDOkTK3x78HhQKorGYH3MgydYI4RBWALc 7SB294CuH46Eoh/r93TY6GfhX8yPgdYJ2DGIxh9kO70+HpuSTn9hrkg6yKFif2I9jiMh X/ukOl9LZ0ifnChg23cqnjSSVpH5LCcWgskJrcVovivbqTfzfyPKd56raQhvxHmVCCDd IxWMeDq6j1OvDlU3OZ/zGdRVVFq6bMZG90A9VFDv/epaoFm937qmxYPVPQ4p+WSb+oOA xeVGYdxjy/SpyPpoilkPY3JwtM/DS/GGPRSGtf0k6KR36LSanXBUhS2D4gAk46ZKAYTH F5fg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fris.de header.s=dkim header.b=bZ55zZJ5; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=fris.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 15-20020a17090a0f8f00b0022bb873fd4bsi1949545pjz.132.2023.02.01.06.44.17; Wed, 01 Feb 2023 06:44:29 -0800 (PST) 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=@fris.de header.s=dkim header.b=bZ55zZJ5; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=fris.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232625AbjBAOnX (ORCPT <rfc822;duw91626@gmail.com> + 99 others); Wed, 1 Feb 2023 09:43:23 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48814 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232449AbjBAOnK (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 1 Feb 2023 09:43:10 -0500 X-Greylist: delayed 488 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Wed, 01 Feb 2023 06:43:05 PST Received: from mail.fris.de (mail.fris.de [IPv6:2a01:4f8:c2c:390b::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3B6282E0D0; Wed, 1 Feb 2023 06:43:04 -0800 (PST) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 663D9C033A; Wed, 1 Feb 2023 15:35:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fris.de; s=dkim; t=1675262104; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=lDLZ/xjvrtcN+1CWCH6iD2koCwn6Eb1LpwYqcz6QtGM=; b=bZ55zZJ5eoXQhSN7w9SMB4VCaK51BKzgXkS33yOHee5bB2bhkPDekZpgtZ93c/YxCRE4lj ucP6wYBafqEQ4SNVYXa+DD8qqy3gnRx0R01rnQWNjyWybCCtgxv9zgv4i8Tf3tBUmv3lBP pFRu7HlgOucmf3Eb+CbBzy9BJLSWfwcbCA6r60JD0KySH1eEtuheqw9A4zQijH8Vq8t7k9 nQN+AWJYpWUnuilcqLkg7GvI4deowbc2IX/ABCe8mEG/QfFOrNopolv0QVTrPFn7dSpwBg Ppc3o7UfL9AtjanRkaLAay/rCZYwQW21UmgD0hn7VmgT1YuFneII41Cba86oAw== From: Frieder Schrempf <frieder@fris.de> To: Alessandro Zummo <a.zummo@towertech.it>, Alexandre Belloni <alexandre.belloni@bootlin.com>, devicetree@vger.kernel.org, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org, Rob Herring <robh+dt@kernel.org> Cc: Frieder Schrempf <frieder.schrempf@kontron.de> Subject: [PATCH 4/7] rtc: Move BSM defines to separate header for DT usage Date: Wed, 1 Feb 2023 15:34:26 +0100 Message-Id: <20230201143431.863784-5-frieder@fris.de> In-Reply-To: <20230201143431.863784-1-frieder@fris.de> References: <20230201143431.863784-1-frieder@fris.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Last-TLS-Session-Version: TLSv1.3 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 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1756640228513164454?= X-GMAIL-MSGID: =?utf-8?q?1756640228513164454?= |
Series |
Enable backup switch mode on RTCs via devicetree
|
|
Commit Message
Frieder Schrempf
Feb. 1, 2023, 2:34 p.m. UTC
From: Frieder Schrempf <frieder.schrempf@kontron.de> To be able to use the BSM defines in the devicetree, move the defines to a separate header within the dt-bindings directory. Signed-off-by: Frieder Schrempf <frieder.schrempf@kontron.de> --- include/dt-bindings/rtc/rtc.h | 11 +++++++++++ include/uapi/linux/rtc.h | 6 +----- 2 files changed, 12 insertions(+), 5 deletions(-) create mode 100644 include/dt-bindings/rtc/rtc.h
Comments
Hi Frieder,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on robh/for-next]
[also build test ERROR on arm/for-next arm/fixes arm64/for-next/core kvmarm/next rockchip/for-next shawnguo/for-next soc/for-next xilinx-xlnx/master linus/master v6.2-rc6]
[cannot apply to abelloni/rtc-next next-20230202]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Frieder-Schrempf/dt-bindings-rtc-Move-RV3028-to-separate-binding-file/20230201-224450
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
patch link: https://lore.kernel.org/r/20230201143431.863784-5-frieder%40fris.de
patch subject: [PATCH 4/7] rtc: Move BSM defines to separate header for DT usage
config: x86_64-randconfig-a004 (https://download.01.org/0day-ci/archive/20230203/202302030706.gBkl14ay-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-8) 11.3.0
reproduce (this is a W=1 build):
# https://github.com/intel-lab-lkp/linux/commit/2dfe054992e73c8da87d242a35a30d969d87b1a0
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Frieder-Schrempf/dt-bindings-rtc-Move-RV3028-to-separate-binding-file/20230201-224450
git checkout 2dfe054992e73c8da87d242a35a30d969d87b1a0
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=x86_64 olddefconfig
make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
In file included from <command-line>:
>> ./usr/include/linux/rtc.h:15:10: fatal error: dt-bindings/rtc/rtc.h: No such file or directory
15 | #include <dt-bindings/rtc/rtc.h>
| ^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
diff --git a/include/dt-bindings/rtc/rtc.h b/include/dt-bindings/rtc/rtc.h new file mode 100644 index 000000000000..b0cc06d368c0 --- /dev/null +++ b/include/dt-bindings/rtc/rtc.h @@ -0,0 +1,11 @@ +/* SPDX-License-Identifier: GPL-2.0 OR MIT */ + +#ifndef _DT_BINDINGS_RTC_H +#define _DT_BINDINGS_RTC_H + +#define RTC_BSM_DISABLED 0 +#define RTC_BSM_DIRECT 1 +#define RTC_BSM_LEVEL 2 +#define RTC_BSM_STANDBY 3 + +#endif /* _DT_BINDINGS_RTC_H */ diff --git a/include/uapi/linux/rtc.h b/include/uapi/linux/rtc.h index 97aca4503a6a..9e78c17b5733 100644 --- a/include/uapi/linux/rtc.h +++ b/include/uapi/linux/rtc.h @@ -12,6 +12,7 @@ #ifndef _UAPI_LINUX_RTC_H_ #define _UAPI_LINUX_RTC_H_ +#include <dt-bindings/rtc/rtc.h> #include <linux/const.h> #include <linux/ioctl.h> #include <linux/types.h> @@ -141,11 +142,6 @@ struct rtc_param { #define RTC_PARAM_CORRECTION 1 #define RTC_PARAM_BACKUP_SWITCH_MODE 2 -#define RTC_BSM_DISABLED 0 -#define RTC_BSM_DIRECT 1 -#define RTC_BSM_LEVEL 2 -#define RTC_BSM_STANDBY 3 - #define RTC_MAX_FREQ 8192