From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=193.175.24.41 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796470554; b=FOIkCOJUJH0ZFyzIDhx728Dh8YrXJv23eoX3jGlcVH5ehJQAGTynwsvcsa3kzHpNEJJl aJnMzaz4qnWNBXH+hLcP8R1cBAI2LFmof/iSqO5q8nUFFajc5PGt1IWNzDgs8lRZJvLwy PECbbLnnvJ2bW9OUwBpavGDt+3190SnUAcTpctpWtOTcjbNrOihZizvZSMEySsDNwJWRP R9w6c3T30HAcoOdtmbFQivWzcvKn2rhzQKtnyPy1AsQq7ziTlQbUYf8xQ2lyldvbxKvxp 6btRFQCZTH2mq5iQxKqNDnuY35ls2N+Olz/oxAAdf8OLHAGFQxCIDojWLQAyytsFsQQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796470554; h=DMARC-Filter:Received:Received:Date:From:To:Cc:Subject:Message-ID: References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To; bh=e1twW752L6fVS2fT/HZCyFjj/GpxXHf5ZsGIXlUdU/Q=; b=Ms+2u+D41wKcNVrJ4z4lIT7im0CUR7IS7/EPVukzIs/Ti5I8KSm8SMvAcdcRlKaSPwdn ma8kRZcLgEmFy3FvI34BGL05UsTP06nvKefqmD7prX/sEjnhSHhR/ZvbPX+P9nTGWdrWi 7AqO9m2U5ZojVtIYKwV+ajgVBkl0s9ELQsVEW6swjSldA97g+VXThCULY+wdqySf3jGdf Q9JHBfXD61gXb482Kg6CyaaCEv2MdTd7H7itSuCgICf5VCUjff656Rta2uZJs0YH35ksd HYnk33WnWtWkAKKGIgmbkTsDtGI21LDewwxZ9Dvcg/ZC+usWGMdtWbywFcUjeEkyC3A== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=alpha.franken.de; spf=pass smtp.mailfrom=alpha.franken.de; arc=none smtp.remote-ip=193.175.24.41 Received: from elvis.franken.de (elvis.franken.de [193.175.24.41]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 55A84606A322; Sat, 5 Dec 2026 11:35:53 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 55A84606A322 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=alpha.franken.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=alpha.franken.de Received: by elvis.franken.de (Postfix, from userid 10) id 2338D100458; Sat, 5 Dec 2026 12:35:51 +0100 (CET) Received: by alpha.franken.de (Postfix, from userid 1000) id A8941C0838; Sat, 5 Dec 2026 12:29:47 +0100 (CET) Date: Sat, 5 Dec 2026 12:29:47 +0100 From: Thomas Bogendoerfer To: Imre Kaloz Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] MIPS: SGI-IP22: Retry the third timer calibration sample on zero Message-ID: References: <20261128154452.28694-1-kaloz@kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20261128154452.28694-1-kaloz@kernel.org> On Sat, Nov 28, 2026 at 04:44:52PM +0100, Imre Kaloz wrote: > The third calibration sample can be 0 and is then averaged in, which > sets the Count rate to two thirds of its real value. Loop until it > is non-zero, as for the first two. > > Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2") > Signed-off-by: Imre Kaloz > --- > arch/mips/sgi-ip22/ip22-time.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/arch/mips/sgi-ip22/ip22-time.c b/arch/mips/sgi-ip22/ip22-time.c > index 045aa89f28d8..e911bc03f1dd 100644 > --- a/arch/mips/sgi-ip22/ip22-time.c > +++ b/arch/mips/sgi-ip22/ip22-time.c > @@ -93,7 +93,9 @@ __init void plat_time_init(void) > > if (r4k_ticks[0] != r4k_ticks[1]) { > printk("warning: timer counts differ, retrying... "); > - r4k_ticks[2] = dosample(); > + do { > + r4k_ticks[2] = dosample(); > + } while (!r4k_ticks[2]); > if (r4k_ticks[2] == r4k_ticks[0] > || r4k_ticks[2] == r4k_ticks[1]) > r4k_tick = r4k_ticks[2]; > > base-commit: aebb7274476403040d582c61478df8f4a7bf9cd3 > -- > 2.47.3 applied to mips-next Thomas. -- Crap can work. Given enough thrust pigs will fly, but it's not necessarily a good idea. [ RFC1925, 2.3 ]