Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp9254489ybi; Wed, 10 Jul 2019 07:13:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqwB9trj0OenD/eOCkyIy6d0CoXKpT248Nq2boNLLfn2VzkOwQwuGBONMIpchhncN1Be0nac X-Received: by 2002:a63:e54:: with SMTP id 20mr9914282pgo.244.1562768037677; Wed, 10 Jul 2019 07:13:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562768037; cv=none; d=google.com; s=arc-20160816; b=YzMwbTjqX25nwaSefc1M17bVhrFG9E0FTMdjtGq9Wl1Ol5wK11v1PWfjMllCKqzJL+ v+PKYmlJcn+5Fa1LI+a/IvGBngOSiFOdJRSUayXM558AEyyx3o2KrHhcdRxoA0MBvx14 Z+1I0//Eye2spqBuWuxoYupOO2XyN9qFpRKxtSZStnu0hoOZsiuGkdShOO4JSHxMBFo2 d7LHld5JtOWbRpwY4EFXC1KJCUMVaaMsvvJHTkApg+nsxAPC+8SIyyzPgDd7pSZeduLL VDbpyxk+L6L1F6G4mI0khpQddGAm7Pb4uVFCxipT0Jp7Nv4CKXUtbaVpxhRGU4ho/gOP CCuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature; bh=+kX+n3hyhZoLMZ3AyyBvfYkQJJMtdOnst/LvSxzqXpA=; b=EjrzebYcKbWcKTLGcpwdTbXLQtbGk0oGTy/ZAvAiPzzXGQRkbyNk4QW64uJJtxlIXj wPL9hiwpJcY+8d/Jm++cRcuiacqCpDkCRiucNyguWj2APBdxsODL2NUJmHqCpjVZreDw ouD/CsyzTsl6YxvQfi82Dr37jDJrMVFwzrfnYmuLWH71bZR1TFmuUB4LzXr4sU7TrIbh XJZ1rZNcILr6kHJwsYqufGoAN0IdKBRLAV/Jq/0dPx93LE195Hp8QNZ28t9AikKjvUe8 StAGFSZJpmWHn80qvR/5SxWWMuYkLhCK2G9Sg7V+g+NU1R9F2rTV/ulP+lF+gJA8l0Dh HxQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mengyan1223.wang header.s=mail header.b=mqTkj8cj; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mengyan1223.wang Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t15si2211534plo.360.2019.07.10.07.13.41; Wed, 10 Jul 2019 07:13:57 -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; dkim=pass header.i=@mengyan1223.wang header.s=mail header.b=mqTkj8cj; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mengyan1223.wang Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727210AbfGJNbo (ORCPT + 99 others); Wed, 10 Jul 2019 09:31:44 -0400 Received: from mengyan1223.wang ([89.208.246.23]:38742 "EHLO mengyan1223.wang" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725994AbfGJNbn (ORCPT ); Wed, 10 Jul 2019 09:31:43 -0400 Received: from xry111-laptop.lan (unknown [124.115.222.149]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: xry111@mengyan1223.wang) by mengyan1223.wang (Postfix) with ESMTPSA id 6FA9465B50; Wed, 10 Jul 2019 09:31:39 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mengyan1223.wang; s=mail; t=1562765502; bh=+kX+n3hyhZoLMZ3AyyBvfYkQJJMtdOnst/LvSxzqXpA=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=mqTkj8cjCJmnvx6exJv6Jpz9ro4dHyALrUSIGQySKxAAK7oXDazA9KzbOLauSQMMB 0W2qeRP2dxg1GG66cITqO2o+0b1cOJFAvl3CFRhQipG08u9LUa0B1OnV5wAOeVPs3+ MF4UV95XoZiUua8QoDJ/NjMogP9j4p8QwloD15BADBa5akXtZQRI9ONv5p+t0/+bJs M1Hy+GMkYv8bwtrWNBD3a8Kgbnq8m5/jUWhCIuoV/ICvmWx0ut4oK/s+hpC4LKlzNI RRe7LFprMh0bRG3g7bNhxZLAJDlKOshI9UowljkV8z7/QZ0WSoesbEcRkqLvQYgpIB sR5d0pIKH1Yzg== Message-ID: <4f0e830430f46c5f6b90656ec5d3b969d79fe6db.camel@mengyan1223.wang> Subject: Re: [GIT PULL] x86/topology changes for v5.3 From: Xi Ruoyao To: Jiri Kosina , Peter Zijlstra Cc: Thomas Gleixner , Kees Cook , Linus Torvalds , Ingo Molnar , Linux List Kernel Mailing , Borislav Petkov , Len Brown , Andrew Morton , "Rafael J. Wysocki" , Tony Luck , Bob Moore , Erik Schmauss , Josh Poimboeuf , Daniel Bristot de Oliveira Date: Wed, 10 Jul 2019 21:31:35 +0800 In-Reply-To: References: <201907091727.91CC6C72D8@keescook> <1ad2de95e694a29909801d022fe2d556df9a4bd5.camel@mengyan1223.wang> <20190710132144.GM3402@hirez.programming.kicks-ass.net> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.32.3 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2019-07-10 15:28 +0200, Jiri Kosina wrote: > On Wed, 10 Jul 2019, Jiri Kosina wrote: > > > > > BUG: unable to handle page fault for address: ffffffff9edc1598 > > > > > #PF: supervisor write access in kernel mode > > > > > #PF: error_code(0x0003) - permissions violation > > Hm, and it seems to explode on dereferencing the static_key* in %rsi > > ^^^ %rdi of > course > > > 21: 48 8b 37 mov (%rdi),%rsi > > 24: 83 e6 03 and $0x3,%esi > > 27: 48 09 c6 or %rax,%rsi > > 2a:* 48 89 37 mov %rsi,(%rdi) <-- trapping > > instruction > > > > which looks odd, as it derefenced it successfully just 3 instructions ago. It seems the MMU (I guess ?) allows to read it, but disallows to write it: "supervisor write access in kernel mode". -- Xi Ruoyao School of Aerospace Science and Technology, Xidian University