Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp618201iog; Fri, 24 Jun 2022 10:19:02 -0700 (PDT) X-Google-Smtp-Source: AGRyM1v2ic0DKjohms4N3zmjOyBNPAKeYQZE5/ybf2UUxBfzRjEPa0aGLFGKs0fHBA/Oy3FCBFUb X-Received: by 2002:a63:6c81:0:b0:3fd:4be3:8ee9 with SMTP id h123-20020a636c81000000b003fd4be38ee9mr12484414pgc.188.1656091141978; Fri, 24 Jun 2022 10:19:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656091141; cv=none; d=google.com; s=arc-20160816; b=PCeOTHyiFGwzM/adHVU1h8NB4d9Ohb5y8oiG/eTJ+9okBPBr9oGUhfBgY4H12g/l9a yR/nzMz9hPbZQmQugMCueD8Bm++DZeNdQXx00WN28fmEFbuFDR0gbiNms29UTzlqZn9h JWBmqZDFaHgtIkQn/v01Bxg94KBcPee9BN4krocDgis+CAtMgX8p5RpsZiBzopoLggH6 d6jksSG99iyFJ9j1+T4gqLmv+yi8/gBRn/II47R3/nbkK9risCrQfv9fcjkwQZyhXNRr FEnFpME2WeoxhLe6u2v+snb//EJ7ChpZRNfZro+fNHHK73qJL4AZmCgPILrXkKiHnydE rh+A== 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=8Yof9puEZCThqdywnFFBZccm9TUQN0Wk2gtyzAn9V20=; b=XHMzC4oLEEB9yR8R8Hov6xY+VwBxcyJ1n0xGDFf0cIygSQqVEWG79WESXJuIfiqcX5 mTic8a+NEp/OaE+luzd3fmrvOP35DqGY5wgNo2oxiay01yJNqA4nza1O7GcH++xuJCZT zZ7ohjLXcG+tVG+zpnNIOHitPCDCIpg+yiNRH8weFxvOLC2lkAOZl1k4UiKnU/Tg/oB3 3cW0b9/IXWK3IEWcDvZdarwnM53hqOhU/VlTnUKf/QVouJKPVgNYvaQnz32qVL2o1+MH pKexDfYOYq/0w9fCN4euwks0ZQNvac7RWXkdYQI8WBYpIJOHStKHHRd8Aoa82kO+BKlj cUOQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Dq3lTFyx; 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 v202-20020a6361d3000000b003fc2d55e661si3723909pgb.484.2022.06.24.10.18.28; Fri, 24 Jun 2022 10:19:01 -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=Dq3lTFyx; 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 S229783AbiFXQpT (ORCPT + 99 others); Fri, 24 Jun 2022 12:45:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41584 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229595AbiFXQpS (ORCPT ); Fri, 24 Jun 2022 12:45:18 -0400 Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [217.70.183.198]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 344BB47549; Fri, 24 Jun 2022 09:45:17 -0700 (PDT) Received: (Authenticated sender: alexandre.belloni@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id C54ADC0005; Fri, 24 Jun 2022 16:45:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1656089116; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8Yof9puEZCThqdywnFFBZccm9TUQN0Wk2gtyzAn9V20=; b=Dq3lTFyxOWlCEqKtGGlOdH/oGnRRx6pLTtK3ckpNEeDpz8bQ7AR3+HheTeWQHWj9Mem0ww wtchoEsWAYGFIYyrHBy5yFhrg63uiB2f0j+aU2png94/hFmMxLXau2vCAzTQfpBPKEjA9P 9itAYU6jFeI7z5rbr9NXan+23pNdgvNZXMuITmkwe6fk0HqDy82x/jqM4/14QaZnrM3E4v OPPfzFB/ncQJ7DoHNA6iNISJd+hga9Tw6hnJa4Iy3SqEDQnj4LjI+VzAgqghK3ZYgYqFwE NAd0IoqTrzWSW6D1E5/O9FXmBdRKH8PGtlGdbZ3u0cS13ZiiCJPswDt3Y5ng+g== From: alexandre.belloni@bootlin.com To: linux-kernel@vger.kernel.org, mat.jonczyk@o2.pl, linux-rtc@vger.kernel.org Cc: Alexandre Belloni , bp@alien8.de, hpa@zytor.com, x86@kernel.org, dave.hansen@linux.intel.com, a.zummo@towertech.it, tglx@linutronix.de, mingo@redhat.com Subject: Re: (subset) [PATCH 1/3] rtc-mc146818-lib: reduce RTC_UIP polling period Date: Fri, 24 Jun 2022 18:45:11 +0200 Message-Id: <165608905386.24026.1966178825029089110.b4-ty@bootlin.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220225215011.861477-2-mat.jonczyk@o2.pl> References: <20220225215011.861477-1-mat.jonczyk@o2.pl> <20220225215011.861477-2-mat.jonczyk@o2.pl> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,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 From: Alexandre Belloni On Fri, 25 Feb 2022 22:50:09 +0100, Mateusz Jończyk wrote: > Waiting 1ms every time is not necessary, for example on some AMD boxes > the RTC_UIP bit is documented as being high for around 270 microseconds > in some cases [1], which agreed with experiments on an SB710 > southbridge. So 100us seems optimal. > > This in preparation for mach_get_cmos_time() refactoring. > The functions mc146818_get_time() and mach_get_cmos_time() in > arch/x86/kernel/rtc.c perform the same function and the code is > duplicated. mach_get_cmos_time() is busy waiting for the RTC_UIP > bit to clear, so make mc146818_get_time() more similar to it by reducing > the polling period. > > [...] Applied, thanks! [1/3] rtc-mc146818-lib: reduce RTC_UIP polling period commit: 4b94a798e1ca59f4614f5ff6b94fe0c287412b9b Best regards, -- Alexandre Belloni