From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755515AbcFTSsw (ORCPT ); Mon, 20 Jun 2016 14:48:52 -0400 Received: from mail-ob0-f194.google.com ([209.85.214.194]:34003 "EHLO mail-ob0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752337AbcFTSsL (ORCPT ); Mon, 20 Jun 2016 14:48:11 -0400 MIME-Version: 1.0 In-Reply-To: <2816580.laIl5zA8fL@vostro.rjw.lan> References: <20160617105435.GB15997@pd.tnic> <20160617161247.GB3912@pd.tnic> <2816580.laIl5zA8fL@vostro.rjw.lan> From: Linus Torvalds Date: Mon, 20 Jun 2016 11:29:47 -0700 X-Google-Sender-Auth: SXy8RQrRAvhdD7JYtL9AgKl_pZ0 Message-ID: Subject: Re: ktime_get_ts64() splat during resume To: "Rafael J. Wysocki" Cc: Borislav Petkov , Logan Gunthorpe , Kees Cook , "Rafael J. Wysocki" , Thomas Gleixner , Ingo Molnar , Peter Zijlstra , lkml , John Stultz , "Rafael J. Wysocki" , Stable , Andy Lutomirski , Brian Gerst , Denys Vlasenko , "H. Peter Anvin" , Linux PM list , Stephen Smalley Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 20, 2016 at 7:38 AM, Rafael J. Wysocki wrote: > > Overall, we seem to be heading towards the "really weird" territory here. So the whole commit that Boris bisected down to is weird to me. Why isn't the temporary text mapping just set up unconditionally in the temp_level4_pgt? Why does it have that insane "let's leave the temp_level4_pgt alone until we actually switch to it, and save away restore_pgd_addr and the restore_pgd, to then be set up at restore time"? All the other temporary mappings are set up statically in the temp_level4_pgt, why not that one? I suspect whatever corruption happens boils down to the same issue that made people do that odd decision in the first place. And regardless, those games are too ugly to live. So I would suggest that that original commit should just be considered broken, and reverted (or just removed - I'm not sure if it's in a stable branch or not) and the fix be rethought so that the code mapping can be done once and for all and *without* the extra games. Linus