From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 771C7C282C8 for ; Mon, 28 Jan 2019 20:20:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 473E22171F for ; Mon, 28 Jan 2019 20:20:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726997AbfA1UUN (ORCPT ); Mon, 28 Jan 2019 15:20:13 -0500 Received: from mga09.intel.com ([134.134.136.24]:56774 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726792AbfA1UUN (ORCPT ); Mon, 28 Jan 2019 15:20:13 -0500 X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Jan 2019 12:20:10 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,534,1539673200"; d="scan'208";a="110491051" Received: from sjchrist-coffee.jf.intel.com (HELO linux.intel.com) ([10.54.74.14]) by orsmga007.jf.intel.com with ESMTP; 28 Jan 2019 12:20:10 -0800 Date: Mon, 28 Jan 2019 12:20:10 -0800 From: Sean Christopherson To: Sasha Levin Cc: Thomas Lindroth , kvm@vger.kernel.org, stable@vger.kernel.org Subject: Re: Regression in v4.14.94 by "x86,kvm: move qemu/guest FPU switching out to vcpu_run" Message-ID: <20190128202010.GA21909@linux.intel.com> References: <457d0666-1951-1b7c-f7e8-18c67763e6c3@gmail.com> <20190128201453.GM3973@sasha-vm> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190128201453.GM3973@sasha-vm> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org On Mon, Jan 28, 2019 at 03:14:53PM -0500, Sasha Levin wrote: > On Mon, Jan 28, 2019 at 08:25:20PM +0100, Thomas Lindroth wrote: > >I run a qemu/kvm VM with debian and I've started getting segfaults and failing checksums on > >downloaded files. The failures are undeterministic and similar to the failures you get with > >bad ram. I tried to diagnose the problem with various testing tools and found that > >"stress-ng --verify --cpu 1" always give an error. Stress-ng give one of these errors > >usually within 60 sec: > > > > stress-ng-cpu: Newton-Rapshon sqrt not accurate enough > > stress-ng-cpu: prime error detected, number of primes between 0 and 1000000 miscalculated > > > >Nothing relevant has changed recently in the VM but the host kernel was upgraded from > >4.14.93 to 4.14.96. I can't reproduce the stress-ng error with a 4.14.93 host kernel. There > >is only one kvm related change in that range so I tried to revert that one. > > > >By reverting commit 4124a4cff344abbf8187775eb643d9827830e715 > >"x86,kvm: move qemu/guest FPU switching out to vcpu_run" on kernel 4.14.96 I can't reproduce > >the stress-ng error and I have no segfault or other problems with the guest. [...] > Interesting, thank you for the report. > > Could you confirm whether this issue reproduces on a newer kernel that > has that patch (4.19.18 for example)? The bug is specific to 4.14, two dependent commits were applied in the wrong order and introduced the bug. I have a patch, in the process of typing up the changelog.