Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp706284pxm; Fri, 25 Feb 2022 17:50:36 -0800 (PST) X-Google-Smtp-Source: ABdhPJwqOHvzrKSiLTGh7GIQLn79UQSV8aHRwoLzH5kxNPwHvajp6W+MiJmFD1SuiXOVq02Wteti X-Received: by 2002:aa7:8882:0:b0:4e1:4531:e3c8 with SMTP id z2-20020aa78882000000b004e14531e3c8mr10469297pfe.76.1645840236425; Fri, 25 Feb 2022 17:50:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645840236; cv=none; d=google.com; s=arc-20160816; b=fLnz76cHJzMmzm5oyvCuMmMJLq/m5K/q6hLTKVjxB7pyC/+9Ej3KVGMJhkTp+MDJQT qEDE22ibIVgjxGtJddvyQEK90ULOj6l8gKrQhA4uzL4ZgGE+AqKlMl53skZbhyshVNlO x4DPhEdatbtY4WE51WdqM2ftskrhVKpSGOXNxJaPSP1hbaBsDHKYlk5SjA+MHO3D9Wlj 6o1DAWBsBx9VF0RH16C4gxWmgBW4expMhEU2jhNONMS8uXFNhWKrnSh5xiMPB7pH0Y4h DPyqvz6OMi349uJ4vc8SaZUdS8aqRD67K0bV+uBBFPqw1NSTMspCyzzz+WyUZTLwUFlf fTOA== 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=HGUXmDpRDjSSSovQwhGF/FGr2kg7ezLYTr/WItdJsF4=; b=YAjF0vK4Oi7uaNBfIkBNIpQRotq7FKE7x1mHbmCcM+RS3weUTRCBbkfjDOJQ+DjfkH 8Jicdp1He4mWuueYyN04OqpKS+rPij7yTkJg7Q96aqTz2f0nCuULBJzra0O4SpHNuk+b VZCqwdvEEApMvbFYPjsXYYws3eyQD4Lm9HfsG2qgGjl6IpO2K00uJ3ptqsD8Coec6JAC ZSeLNqP3lnOKUR8A5I1oaMGAAktxGgvNi447mxvmjVBQOUg0+DvGhsSD3awa2jBICrTQ yBFLbEWXz/QJR45NIfCqW0sWQ0jMoivBfu/h9QWiLhiobt6IwVtpBukXAL5lhqkn/bQF RyLw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@o2.pl header.s=1024a header.b=eIMxMvG4; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=o2.pl Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id b3-20020a170902d50300b0014d77eb167bsi3711647plg.113.2022.02.25.17.50.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Feb 2022 17:50:36 -0800 (PST) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@o2.pl header.s=1024a header.b=eIMxMvG4; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=o2.pl Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 89B69263901; Fri, 25 Feb 2022 17:37:48 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233658AbiBYVv2 (ORCPT + 99 others); Fri, 25 Feb 2022 16:51:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49174 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232900AbiBYVvY (ORCPT ); Fri, 25 Feb 2022 16:51:24 -0500 Received: from mx-out.tlen.pl (mx-out.tlen.pl [193.222.135.145]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ED2B01EF35C for ; Fri, 25 Feb 2022 13:50:51 -0800 (PST) Received: (wp-smtpd smtp.tlen.pl 22558 invoked from network); 25 Feb 2022 22:50:49 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=o2.pl; s=1024a; t=1645825849; bh=HGUXmDpRDjSSSovQwhGF/FGr2kg7ezLYTr/WItdJsF4=; h=From:To:Cc:Subject; b=eIMxMvG4qEngeLUlPqjo76VGQbsB56UGxjbM/uGwpyp6NcfPe6pIEWN+Aw9f1Yu0B bz0It+W3JJDS3YBunt44Ykf806KbaLrCJT10g8N1C+CdXxJLIAzMAyt0VWzGCv66tP ONl99M11Nm0bLpxiPtaYY4mV1FnO7G4NoWlk7Dhs= Received: from aaew227.neoplus.adsl.tpnet.pl (HELO localhost.localdomain) (mat.jonczyk@o2.pl@[83.4.126.227]) (envelope-sender ) by smtp.tlen.pl (WP-SMTPD) with SMTP for ; 25 Feb 2022 22:50:49 +0100 From: =?UTF-8?q?Mateusz=20Jo=C5=84czyk?= To: linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org Cc: =?UTF-8?q?Mateusz=20Jo=C5=84czyk?= , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" Subject: [PATCH 3/3] x86/rtc: rename mach_set_rtc_mmss Date: Fri, 25 Feb 2022 22:50:11 +0100 Message-Id: <20220225215011.861477-4-mat.jonczyk@o2.pl> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220225215011.861477-1-mat.jonczyk@o2.pl> References: <20220225215011.861477-1-mat.jonczyk@o2.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-WP-MailID: 247949ee4229b98e2f13ef1e9a6b6fe3 X-WP-AV: skaner antywirusowy Poczty o2 X-WP-SPAM: NO 0000000 [oeO0] X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Once upon a time, before commit 3195ef59cb42 ("x86: Do full rtc synchronization with ntp") in 2013, the function used to set only the minutes and seconds registers of the CMOS RTC. This is no longer true, so rename the function to mach_set_cmos_time. Signed-off-by: Mateusz Jończyk Cc: Thomas Gleixner Cc: Ingo Molnar Cc: Borislav Petkov Cc: Dave Hansen Cc: x86@kernel.org Cc: "H. Peter Anvin" --- arch/x86/include/asm/mc146818rtc.h | 2 +- arch/x86/kernel/rtc.c | 4 ++-- arch/x86/kernel/x86_init.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/x86/include/asm/mc146818rtc.h b/arch/x86/include/asm/mc146818rtc.h index 97198001e567..6115bb3d5795 100644 --- a/arch/x86/include/asm/mc146818rtc.h +++ b/arch/x86/include/asm/mc146818rtc.h @@ -95,7 +95,7 @@ static inline unsigned char current_lock_cmos_reg(void) unsigned char rtc_cmos_read(unsigned char addr); void rtc_cmos_write(unsigned char val, unsigned char addr); -extern int mach_set_rtc_mmss(const struct timespec64 *now); +extern int mach_set_cmos_time(const struct timespec64 *now); extern void mach_get_cmos_time(struct timespec64 *now); #define RTC_IRQ 8 diff --git a/arch/x86/kernel/rtc.c b/arch/x86/kernel/rtc.c index 9f251b65219f..24ca997a210e 100644 --- a/arch/x86/kernel/rtc.c +++ b/arch/x86/kernel/rtc.c @@ -27,13 +27,13 @@ DEFINE_SPINLOCK(rtc_lock); EXPORT_SYMBOL(rtc_lock); /* - * In order to set the CMOS clock precisely, set_rtc_mmss has to be + * In order to set the CMOS clock precisely, mach_set_cmos_time has to be * called 500 ms after the second nowtime has started, because when * nowtime is written into the registers of the CMOS clock, it will * jump to the next second precisely 500 ms later. Check the Motorola * MC146818A or Dallas DS12887 data sheet for details. */ -int mach_set_rtc_mmss(const struct timespec64 *now) +int mach_set_cmos_time(const struct timespec64 *now) { unsigned long long nowtime = now->tv_sec; struct rtc_time tm; diff --git a/arch/x86/kernel/x86_init.c b/arch/x86/kernel/x86_init.c index 7d20c1d34a3c..927924a319a7 100644 --- a/arch/x86/kernel/x86_init.c +++ b/arch/x86/kernel/x86_init.c @@ -133,7 +133,7 @@ struct x86_platform_ops x86_platform __ro_after_init = { .calibrate_cpu = native_calibrate_cpu_early, .calibrate_tsc = native_calibrate_tsc, .get_wallclock = mach_get_cmos_time, - .set_wallclock = mach_set_rtc_mmss, + .set_wallclock = mach_set_cmos_time, .iommu_shutdown = iommu_shutdown_noop, .is_untracked_pat_range = is_ISA_range, .nmi_init = default_nmi_init, -- 2.25.1