[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/2] x86/time: use relative counts in calibration loops


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Wed, 12 Jan 2022 11:18:19 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=MVVzIEZJ7nGtCbr4qtZ4tFdsPCecFgSJRYeur6mmDBc=; b=C5hnJQgXiLIKrfr5iUazOBKj6ZodHREmpJP1Gia0T8Vp0FpJ0Z+ryte+dkfGHxZdOQ+Mc7od59ygukpFuL7ZtgZBhOfDYp48jhp6zdmFJ5ilqtTQRGK3eTUpMbgKto1ZJ7DYlDyDaZSvtm5+YNuZgXSDolya1h2PEsuO19SaRxrLD7HlldGS3TzYFe6SgC+kzxkPtxmN7eFvGfl+A0kGPBRVsJT82SaUNyFlkQDLoLV1EEyW4Bguavf/DD1vw3ltXI33SHZFyRCrOD0RPABWjBxL0F0XblpWqFK+CuQKMcxG94zH/0tfz5FAcNC1d9qKSq0VIp8IdW0dm0qPPpqiZw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NjBGu167EeI4QidVfQLk3hHXrSjvcTk7GwD6h4kZZzmjXClFpsXER9fzzCe2jqjMSSGtVngk9JbjBiXtaZytLJWZKac4iDIqKYYfGOyFh7/vuQE/4NIlr4gE6YjV5nYrHK2N95ZILxSolUAPgSj2cFszvhQT6RgQ70bnWo7cIhFB6ledJIuafXrP8no9bJ8eH9jbNvAsxOZnK7R5gvIzNooMZEi9j5f6KVeBgXBzaQhrvssQQl25Yas9iyliTsChIRNv0NfcUU3Yw8Zwoi3pEyG6IbhLQDRuwSsEUFfjOXgKee30e3veQ2hIb0CxqCNJ2wtIKpqp62phoV+7rFTnaA==
  • Authentication-results: esa1.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, "Andrew Cooper" <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Wed, 12 Jan 2022 10:18:50 +0000
  • Ironport-data: A9a23:UF2v7KNKBneH9NzvrR1DkMFynXyQoLVcMsEvi/4bfWQNrUp00GZTz 2cZXTuFPP6CZzP3fY9/bNzkoBkHv8XXndJiSAto+SlhQUwRpJueD7x1DKtR0wB+jCHnZBg6h ynLQoCYdKjYdpJYz/uUGuCJQUNUjMlkfZKhTr6UUsxNbVU8En150Es5w7dRbrNA2rBVPSvc4 bsenOWHULOV82Yc3rU8sv/rRLtH5ZweiRtA1rAMTakjUGz2zhH5OKk3N6CpR0YUd6EPdgKMq 0Qv+5nilo/R109F5tpICd8XeGVSKlLZFVDmZna7x8FOK/WNz8A/+v9TCRYSVatYo2TTpOB4+ OpPjJaLVEApYKLtutokXBYNRkmSPYUekFPGCX22sMjVxEzaaXr8hf5pCSnaP6VBpLwxWzsXs 6VFdnZdNXhvhMrvqF6/YvNrick5atHiIasUu216zCGfBvEjKXzGa/uQv4UChmxv7ixINbGGf M4DZTl3UC//IDhuMXIrMLAPl8790xETdBUH8QnI9MLb+VP70whZwLXrdt3PdbSiVchT20qVu G/C12D4GQ0BcsySzyKf9XChjfOJmjn0MKoQHrCl8v9hgHWI23ceThYRUDOGTeKR0xDkHYgFc gpNp3Ro/fNaGFGXosfVDkeDkHe0gRwlUeFNVO1k5yCv9JPb7FPMboQbdQJpZNsjvc4wYDUl0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Y+rIouP3iJxA7N22pxwGIHAIGsNdBkVCe32m+yVNNXh77PECZe OhD6R81l2dkSN9VLXEOpBJZZmIm/T70LbdJTIWDR8u7weDyRuu9b7BChCdmjMTSSlGz7sO+X XM11WR3NTuj9iLjjvnk0PD5ZVfn9XsjvNFGcy3k8AQbhHhkByhaohNU6CL+Bo1vOaswlA3l8 SkmWZsA+1Dr1fqOk2lqxrk3AftlB4o9n/Z0FedxUDupMToLQhKQvZptMZ8SF/0+kAgtNZz3O ZgxGSCradaChvGgWDU+8XIfwsCrDv0nVMS1cooy1BPW4oXb7Fc6aYF+llOLZsGFCXmrKg6De hVCt3G7vo+SyLVU5nghBgt/DWQZAVwIv/fKXJy//B9kgIm00yR9nFohPD2xRw7hdYAo5ot3Z WzDk0nrsAIciYsV9MOOA42e7rBNoX8e2O+DIusGyWTKEgmAQOEl3el2sR/2AmVEKZ4uKfa3q 6xFm9liQ==
  • Ironport-sdr: LjZW5b+8WJh1LlYCCAy5WxL3iCXNmYscL30ajkGnqMBHIkj7rv30Gd2x8Sfvsr3CLG8wxi3Gt0 pYzcXxienmu2268Z9EP4oWNtWHZ8W9p5CoxsU/kMrqJZsGBPpA0D2WKgWV29SraLhyyQuzbnW6 b1XxxWr5huoip0FibaazHCAWFOMdWaE4gtdmW/YkRVLqm2g3GgRxL8gqzgyEPY992KwMwsz7dU ZJNypUehvXF0Q4zNzwrbO99cN/USnmwdEpHEvMvfZUqZ2GUv4UP+wGK3U2tl3amzn3RA1uAu9m A2Auu+qeKRzOIvq9haVB1pwN
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Wed, Jan 12, 2022 at 09:55:17AM +0100, Jan Beulich wrote:
> Looping until reaching/exceeding a certain value is error prone: If the
> target value is close enough to the wrapping point, the loop may not
> terminate at all. Switch to using delta values, which then allows to
> fold the two loops each into just one.
> 
> Fixes: 93340297802b ("x86/time: calibrate TSC against platform timer")
> Reported-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>

Reviewed-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>

Thanks, Roger.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.