Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1042591yba; Tue, 2 Apr 2019 00:43:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqx+BwzskDmcS/gEkq8vW4lrRgjnilCM2NkgeVPLxp3YtHDLSnJLp3XRdg9o8E+U7mhDuff5 X-Received: by 2002:a62:1a06:: with SMTP id a6mr66167902pfa.18.1554191033920; Tue, 02 Apr 2019 00:43:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554191033; cv=none; d=google.com; s=arc-20160816; b=vvlGpqtJ1lVnfz056vlxkJuxVJtDuVgmRs2ZKqCE9fftheZxUY/t5MCUCHB3UWP9v+ Wt/cSRYS/LHMvL5X9E9/k4ZkSchT9BCKxO12EF034QzGGg/jIDfL+GERdjTr0HLz7LYO tuOvCBP7wcvX3DEzmyS+Q+Jw6W/iIoAybc4ZA7cXUCVzmIDnSVUt5KXXPGLny+yzWJ8W nAH7hZRrKyDGSXZgh6zuyFuPvxJavXCoHaCl0OlWf+AHbIwAYgux+Slg4mPcM+wspx4X +rWhjU9mKDxzZJ5uVICSsKBFY6lDNFyZgUDQhoTA2v1lg03TnU9deBnUZ7CWp7yYTl30 12tA== 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:message-id :in-reply-to:date:references:subject:cc:to:from; bh=UJ6rWvMjjhT8PC3zKBMX9B8FjaH1hl7AYGXO2oHT2OQ=; b=HaeHNhANmLCwnxZTjk4mNyNlJiwXT+b9L0j5BHnD31qDFoIyz8EL/vftEd3gq6jQYH ryM23UpU7kZjZu8KrcMSuq0wxPSCDxPMpwiz8mDswBs1tF2W2oe/boq8TvljiAsFQ8VR 3z4frmpi5ANsWY3yEPjWAuRfxLAt69G+MeTz1w657Ye2C79Smh9IGtThSFYp24G+uEwM QptgexBKkmjlkLAwQJT5TKZHh/t0irLoKt650REVlkOwPykej6W+O3z+9Hp+xW3fYxn3 SWhsf0mPGybYWScU2IhQ0hakwBAkWUNsXkuDemNDLZjRESaFzxAjEYooYni5zH2Xeumq iWaw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 21si10486409pgt.128.2019.04.02.00.43.37; Tue, 02 Apr 2019 00:43:53 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729161AbfDBHIT (ORCPT + 99 others); Tue, 2 Apr 2019 03:08:19 -0400 Received: from mx1.redhat.com ([209.132.183.28]:43190 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725920AbfDBHIQ (ORCPT ); Tue, 2 Apr 2019 03:08:16 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 10F79309267E; Tue, 2 Apr 2019 07:08:15 +0000 (UTC) Received: from oldenburg2.str.redhat.com (ovpn-116-38.ams2.redhat.com [10.36.116.38]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B02211001DDA; Tue, 2 Apr 2019 07:08:06 +0000 (UTC) From: Florian Weimer To: Michael Ellerman Cc: Mathieu Desnoyers , Carlos O'Donell , Paul Burton , Will Deacon , Boqun Feng , Heiko Carstens , Vasily Gorbik , Martin Schwidefsky , Russell King , Benjamin Herrenschmidt , Paul Mackerras , carlos , Joseph Myers , Szabolcs Nagy , libc-alpha , Thomas Gleixner , Ben Maurer , Peter Zijlstra , "Paul E. McKenney" , Dave Watson , Paul Turner , Rich Felker , linux-kernel , linux-api Subject: Re: [PATCH 1/4] glibc: Perform rseq(2) registration at C startup and thread creation (v7) References: <20190212194253.1951-1-mathieu.desnoyers@efficios.com> <20190212194253.1951-2-mathieu.desnoyers@efficios.com> <5166fbe9-cfe0-8554-abc7-4fc844cf2765@redhat.com> <1965431879.7576.1553529272844.JavaMail.zimbra@efficios.com> <87lg0tosfz.fsf@concordia.ellerman.id.au> Date: Tue, 02 Apr 2019 09:08:04 +0200 In-Reply-To: <87lg0tosfz.fsf@concordia.ellerman.id.au> (Michael Ellerman's message of "Tue, 02 Apr 2019 17:02:40 +1100") Message-ID: <87pnq4zxyj.fsf@oldenburg2.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Tue, 02 Apr 2019 07:08:16 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Michael Ellerman: > I'm a bit vague on what we're trying to do here. > > But it seems like you want some sort of "eye catcher" prior to the branch? > > That value is a valid instruction on current CPUs (rlwimi. > r5,r24,6,1,9), and even if it wasn't it could become one in future. > > If you change it to 0x8053530 that is both a valid instruction and is a > nop (conditional trap immediate but with no conditions set). I think we need something that is very unlikely to appear in the instruction stream. It's just a marker. The instruction will never be executed, and it does not have to be a trap, either (I believe that a standard trap instruction would be a bad choice). Thanks, Florian