From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751378AbdBWQEv (ORCPT ); Thu, 23 Feb 2017 11:04:51 -0500 Received: from mail.skyhub.de ([5.9.137.197]:47826 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750916AbdBWQEt (ORCPT ); Thu, 23 Feb 2017 11:04:49 -0500 Date: Thu, 23 Feb 2017 17:03:49 +0100 From: Borislav Petkov To: hpa@zytor.com Cc: Peter Zijlstra , Thomas Gleixner , Ingo Molnar , linux-kernel@vger.kernel.org, torvalds@linux-foundation.org, arjan@linux.intel.com, jpoimboe@redhat.com, richard.weinberger@gmail.com Subject: Re: [PATCH] x86: Implement __WARN using UD0 Message-ID: <20170223160349.6f2245ie4bumrd7k@pd.tnic> References: <20170223132813.GB6515@twins.programming.kicks-ass.net> <20170223140929.GU6536@twins.programming.kicks-ass.net> <69617B03-BF08-4C25-9A82-6F01ABAB48DE@zytor.com> <20170223152309.GF6515@twins.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 23, 2017 at 07:32:07AM -0800, hpa@zytor.com wrote: > Well, once you are using invalid instructions, it depends not on > what the CPU decodes but what your own handler expects. Consider > Microsoft's use of C4 C4 /ib as a meta-instruction (called BOP, "BIOS > operation")... that format has nothing to do with the CPU, but if you > want to disassemble the resulting code you need to know about how they > encode BOP. How do they use that? They rely on the fact that C4 C4 is going to #UD as it is an invalid VEX insn? The second C4 selecting the 100b map which is reserved? Or? -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.