Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp5229292imm; Tue, 18 Sep 2018 06:24:23 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYptnQk9m6Dh9vQ3reQYl5T6TV8QLLLywJyGVeCtmRiMEhZoFYG/hwOHFhKtD70u6EvqJjK X-Received: by 2002:a62:1d54:: with SMTP id d81-v6mr31046318pfd.139.1537277063681; Tue, 18 Sep 2018 06:24:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537277063; cv=none; d=google.com; s=arc-20160816; b=UUPD+VP49NjQVPfDp06oFU3fHX1BPGrHafXz8MGaj7X/SsbMoPM9xbhZy8Cf8PWIZM zj9uSIMqPmowp5TQEzs87ZykF+Y3o2H2vdV/ROOn1ZE8hZQOm08p9leSZy+OSVmIYNYM /QH43NhMiyKURBu7kZlLch66/oSXFZtDScgCBIDWYs48HdxX3Mf6uKsI6Hn1Eip42rAP x5IrtIDJ35yLbQPfDx3AlQqKpBNtJY0xXQHwkRNgcTalCc9woW2S/rcbeNifzE7yhjvm YrtM+9tuG5fra5zQdBfCkwdN8P7o7VMPiZaQhTF5fu2ao+3KNPundkT0thbiHmYbH89+ no7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date; bh=S8+MyiMeaQ1mZr/AP4HXdDecUV8KTN4SxaLVEtGuGlE=; b=0uJ7Ume3T6l3iV14oHuREhIf3RAnL8Qdk278Ev2ze72FSogapzqRN9GIfYcAGQhJXK QJ5xtWvigQR1sLF1RRfqkLZcTXoRBXBGljzHTdQmbWRwjNH5teOOhZJCe4oinwK0Xjis YqjWGab45RQeJ2EMHR8UUU7540qEGYceoO1/PrHZlONoG6yztIVjx1zRxrYaJq4YY7y2 RAXqhbcUBOEsO/VvoDdKNUntvxi4E6XvDk5DS2ZEqpIF9wsIBuiNQ/Gii3qizBniBiAu kXVLUjN5vuBwif5dvk40KgBpSIt8OcNJ8Hg/P8M+1LzUbnIE/uU/TTSN/3RZCz09Lw5a dwSQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 12-v6si19515538plb.203.2018.09.18.06.24.07; Tue, 18 Sep 2018 06:24:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729587AbeIRS4B (ORCPT + 99 others); Tue, 18 Sep 2018 14:56:01 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:57723 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729249AbeIRS4B (ORCPT ); Tue, 18 Sep 2018 14:56:01 -0400 Received: from hsi-kbw-5-158-153-55.hsi19.kabel-badenwuerttemberg.de ([5.158.153.55] helo=nanos) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1g2FyH-0001ke-QE; Tue, 18 Sep 2018 15:23:18 +0200 Date: Tue, 18 Sep 2018 15:23:08 +0200 (CEST) From: Thomas Gleixner To: Peter Zijlstra cc: John Stultz , Andy Lutomirski , LKML , X86 ML , Matt Rickard , Stephen Boyd , Florian Weimer , "K. Y. Srinivasan" , Vitaly Kuznetsov , devel@linuxdriverproject.org, Linux Virtualization , Paolo Bonzini , Arnd Bergmann , Juergen Gross Subject: Re: [patch 09/11] x86/vdso: Simplify the invalid vclock case In-Reply-To: <20180918124800.GL24106@hirez.programming.kicks-ass.net> Message-ID: References: <20180914125006.349747096@linutronix.de> <20180914125118.909646643@linutronix.de> <20180918083055.GJ24106@hirez.programming.kicks-ass.net> <20180918124800.GL24106@hirez.programming.kicks-ass.net> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 18 Sep 2018, Peter Zijlstra wrote: > On Tue, Sep 18, 2018 at 12:41:57PM +0200, Thomas Gleixner wrote: > > I still have one of the machines which is affected by this. > > Are we sure this isn't a load vs rdtsc reorder? Because if I look at the > current code: The load order of last vs. rdtsc does not matter at all. CPU0 CPU1 .... now0 = rdtsc_ordered(); ... tk->cycle_last = now0; gtod->seq++; gtod->cycle_last = tk->cycle_last; ... gtod->seq++; seq_begin(gtod->seq); now1 = rdtsc_ordered(); So if the TSC on CPU1 is slightly behind the TSC on CPU0 then now1 can be smaller than cycle_last. The TSC sync stuff does not catch the small delta for unknown raisins. I'll go and find that machine and test that again. Thanks, tglx