Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2173446yba; Mon, 15 Apr 2019 06:31:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqz+tZ6jyWqvLrobvj6OIA7KIE+K8rXnXGw6uA38tZbAduTbnTVZAcIVQqFJ5c1NM1sbghKX X-Received: by 2002:a17:902:9a85:: with SMTP id w5mr33268309plp.157.1555335073551; Mon, 15 Apr 2019 06:31:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555335073; cv=none; d=google.com; s=arc-20160816; b=qJBwTdqszWQMbqOnwZnJSSnMZWvfOprzxx65FBe+jPN+kDsDTeKfQ+kzUJRDvy5ECK TSqAohGE3vbUV4r+QyZ80bWwxdchU05DYYLXNqKKoyH4NDYJH/RlfpLscwnHSj6MDmlh +XXS66L3WebUQHZgaaybiT1e8quXcpgHJ+kbY9+Fc/4h7y/u5eQTSS2aW3tvmtneOBsr YTqo3Mk4IxHifmoydQt/dndb2DD+z0aZAqLfCk8lenIMMj+dMt3GUYcZxmyp575UAIOP KcpFmkrdcuqBG+OtW3XM95nQeh9AR6oalONOX0LHm0IK8X9AdD0mV88Z92C2Qv4YqJfR misQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=8h7akc6WABuYvP0fi14Ch7Vu3kVcFO8o7C66TUjfmUQ=; b=pbINYJHBjOJinGg1ridt5zHBsV92I9XO8qu9fBmBCrkZggS2SvIkGRC2CifvEprXnR QyXc8t69pT6OcQGfNXQpUzk598e81A7Uf2iGO+0jUjDjNVeaxAPMmxErlpLtn9mIqiZ3 7kqRiFHssF54Dp5modXPz3uaIjp2B0GdN0KrIEJoe7fgoXOgBV4gtIMEVyBSui9kHS5K /T+f4CXH1iTdphjXDy/MEyvthCQYps3F2PLIAt/aN7VVA1zCL1QLvld5TymLUoAyQFht xhxLnCC1MKTEVJAly5+LSg9xH/8/3GRacnPgHemYq0A1av551s+3DKptn05ACo46ko+8 67IA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=A3rkSbKP; 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=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p6si10599718plo.185.2019.04.15.06.30.56; Mon, 15 Apr 2019 06:31:13 -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=@linaro.org header.s=google header.b=A3rkSbKP; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727335AbfDONaW (ORCPT + 99 others); Mon, 15 Apr 2019 09:30:22 -0400 Received: from mail-ot1-f52.google.com ([209.85.210.52]:35005 "EHLO mail-ot1-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727025AbfDONaV (ORCPT ); Mon, 15 Apr 2019 09:30:21 -0400 Received: by mail-ot1-f52.google.com with SMTP id m10so14424878otp.2 for ; Mon, 15 Apr 2019 06:30:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=8h7akc6WABuYvP0fi14Ch7Vu3kVcFO8o7C66TUjfmUQ=; b=A3rkSbKPlJiqUefePph18SPFX6fjNrzQoblx9iL7VQns6gMdbfloeBP8FEh2yc4928 fmv6Cf82L8ReiGhreKN72At26md2n8jf8+HNHWfo3072z6nDRfHr1Xh3zTIMiW/IeD43 Qa6POuONJ8P6HmWMZ4f/6f19O49qhjvSIYaIOptp1ailay0pRH8KH04USAgG4M8vYUa/ yXwmyCHNXiXJB9SqokSjRB8br0fcFQ2MmoPFtsuQTKs5KpMJW7y4ccfE5Rn+P7E1LU/Q 4Up5nv+cEawlIQ+onHcSwxNG4XlIbhmmzCe/jyw18YqiXeFuaTPyANwxMICYphM96VCY HQyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=8h7akc6WABuYvP0fi14Ch7Vu3kVcFO8o7C66TUjfmUQ=; b=gUcvjxMK5aTsT7CWdlTL7+EIigcQs/8ANopxXbwuo1T4rIyreJjceoAh5TFSzK6mAA rJkX1lSPBMDci2RCctlz3z28jN1/hz17hq6JC7V8f2Um4bbBvqIkWWNJmOGNoSpwHTR+ tmeG6tVgHwHHT/yjx9wwEkO2dkFURQUj2rMIuR59N5D+kTABnxdv0g9TT9SkCNAZb81V 0+79bCwDnzkxUoYYJLtMzihsgt03+SlmV6QYRBRGi0K8BBirfQqYU+N2g1zoMw1lvn5C PWcmXPSWN5+S+JAnyCgRhwuBDxwNHZjPw18Wr+YBYpmTIeDapKFs1WioAhVI5sccQch7 6Qzw== X-Gm-Message-State: APjAAAVBbR1xEQgQNyhXITZDYMgS5HXpP2qB2lMU4ssy8pyfYbUqMb7/ nEtPeAKKeyA2ZUVl5Cbo73LVMCXWwEwYHRmU0UgjUg== X-Received: by 2002:a05:6830:1044:: with SMTP id b4mr48626160otp.274.1555335020971; Mon, 15 Apr 2019 06:30:20 -0700 (PDT) MIME-Version: 1.0 References: <1050734985.2625.1554838340011.JavaMail.zimbra@efficios.com> <1933578130.3292.1554928159928.JavaMail.zimbra@efficios.com> <20190411164219.GE29081@fuggles.cambridge.arm.com> <1469455003.811.1555005112414.JavaMail.zimbra@efficios.com> <936773156.261.1555333890988.JavaMail.zimbra@efficios.com> In-Reply-To: <936773156.261.1555333890988.JavaMail.zimbra@efficios.com> From: Peter Maydell Date: Mon, 15 Apr 2019 14:30:09 +0100 Message-ID: Subject: Re: rseq/arm32: choosing rseq code signature To: Mathieu Desnoyers Cc: Will Deacon , libc-alpha , linux-kernel , carlos , richard earnshaw Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 15 Apr 2019 at 14:11, Mathieu Desnoyers wrote: > > ----- On Apr 11, 2019, at 3:55 PM, peter maydell peter.maydell@linaro.org wrote: > > > On Thu, 11 Apr 2019 at 18:51, Mathieu Desnoyers > > wrote: > >> * This translates to the following instruction pattern in the T16 instruction > >> * set: > >> * > >> * little endian: > >> * def3 udf #243 ; 0xf3 > >> * e7f5 b.n <7f5> > >> * > >> * big endian: > >> * e7f5 b.n <7f5> > >> * def3 udf #243 ; 0xf3 > > > > Do we really care about big-endian instruction-ordering for Thumb? > > It requires (AIUI) either an ARMv7R CPU which implements and sets > > SCTLR.IE to 1, or a v6-or-earlier CPU using BE32, and it's going to > > be even rarer than normal BE8 big-endian... > > I don't think we care enough about it to look for a trick to > turn the branch into something else (which would not branch away from the > udf instruction), but considering this signature will be ABI, it's good to > be thorough documentation-wise and cover all existing cases. I think if you want to document it it would be helpful to readers to make it clear that this is the ultra-rare big-endian-instruction-order "big endian Thumb", not the only moderately-rare little-endian-instructions-big-endian-data "big endian Thumb". thanks -- PMM