From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 12841C10F25 for ; Mon, 9 Mar 2020 21:13:10 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id CD7422146E for ; Mon, 9 Mar 2020 21:13:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Uo33X2KR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CD7422146E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 60E496B0005; Mon, 9 Mar 2020 17:13:09 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5BE2A6B0006; Mon, 9 Mar 2020 17:13:09 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4D41B6B0007; Mon, 9 Mar 2020 17:13:09 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0101.hostedemail.com [216.40.44.101]) by kanga.kvack.org (Postfix) with ESMTP id 373A36B0005 for ; Mon, 9 Mar 2020 17:13:09 -0400 (EDT) Received: from smtpin06.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 10E9A81D4 for ; Mon, 9 Mar 2020 21:13:09 +0000 (UTC) X-FDA: 76577074098.06.space95_38913c17a5207 X-HE-Tag: space95_38913c17a5207 X-Filterd-Recvd-Size: 4889 Received: from mail-oi1-f196.google.com (mail-oi1-f196.google.com [209.85.167.196]) by imf33.hostedemail.com (Postfix) with ESMTP for ; Mon, 9 Mar 2020 21:13:08 +0000 (UTC) Received: by mail-oi1-f196.google.com with SMTP id q81so11709982oig.0 for ; Mon, 09 Mar 2020 14:13:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=3z8EHLpMCQvcYpt6UukodjjMPaKQSfJoSvh+H1FwXpE=; b=Uo33X2KRJb36R+pDGYk+8RIeN85dKzwpgdLbDUPr+9B9BMZ85RveP6Gg4P9oyZxbm4 2K3e4tdKvGoGtgRpjcwgMiWQZt8UJb/UFNJHw5tLF0NOWHFrNFdyRXTkFSbkf5H4tsc6 IcpYpKYWqffJV6s2v90EZdhLsDqIKsO+RfndJ8vdAPvApbSRQC+o9evQVkA1fncfVn94 /r1A5ShhXUejgZgxKKIPCMr3s+3DprNyhVawLwBIFSWp9lSWYYnxpaTqXttawWDI94Z0 rwKxBj33qEtxur5xqGdRtakBXCrM+5cjMBQn/XmEncvVst15+znYnLuBqtLxKgb9OaTt ARPA== 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:content-transfer-encoding; bh=3z8EHLpMCQvcYpt6UukodjjMPaKQSfJoSvh+H1FwXpE=; b=MKRq7+cecxJL4SN1JQswm8yK4FGZA+4ami8exCVzp1sBT9+tDTN9i9aquWXIgT7CvC xTIbz85pGiF1KEPOsypUNIfWkH9Hi6JiV8yDJz7O+o1FVLXea6Hv2tXOv+nNrr/XuuZf 8U3I3HKq6C6nHc90GfJt52M2JCTRfs05PFcp7OoDcUWJ2g70Npctuh0WGmfwL9KelUen 9VaTNYMN/lWaHZymCvX2+b9VqEI+fAxMzz9/Sfn15tES6mqgKM16vT4p6ksJ5skmy2r7 9zOgjeT4dM6Bj4sruxzTvUISZsm4V/XM4G1uCLfbwljRmCPjt8ruw3nENLfrmmCysbfA VWWA== X-Gm-Message-State: ANhLgQ0890kzZnzwnxaByfPH9y/uhkiFd4NwnSUO6Oiy5lJGmW0pC+5U 8JBuAsANSW4kBb+DfyXK9owHQaQetEpf3jTau4U= X-Google-Smtp-Source: ADFU+vuIWAeuG6fp3KaR1L5/2IvghcQfrXPwsJh/m5EVZSNOWjVc3Evh0yp9ILZ/129trtK5JRkTF3lPbT5uuTXehkU= X-Received: by 2002:aca:aa12:: with SMTP id t18mr853523oie.95.1583788387706; Mon, 09 Mar 2020 14:13:07 -0700 (PDT) MIME-Version: 1.0 References: <0088001c-0b12-a7dc-ff2a-9d5c282fa36b@intel.com> In-Reply-To: <0088001c-0b12-a7dc-ff2a-9d5c282fa36b@intel.com> From: "H.J. Lu" Date: Mon, 9 Mar 2020 14:12:31 -0700 Message-ID: Subject: Re: [RFC PATCH v9 01/27] Documentation/x86: Add CET description To: Dave Hansen Cc: Andy Lutomirski , Yu-cheng Yu , "the arch/x86 maintainers" , "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , LKML , linux-doc@vger.kernel.org, Linux-MM , linux-arch , Linux API , Arnd Bergmann , Andy Lutomirski , Balbir Singh , Borislav Petkov , Cyrill Gorcunov , Dave Hansen , Eugene Syromiatnikov , Florian Weimer , Jann Horn , Jonathan Corbet , Kees Cook , Mike Kravetz , Nadav Amit , Oleg Nesterov , Pavel Machek , Peter Zijlstra , Randy Dunlap , "Ravi V. Shankar" , Vedvyas Shanbhogue , Dave Martin , x86-patch-review@intel.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, Mar 9, 2020 at 1:59 PM Dave Hansen wrote: > > On 3/9/20 1:54 PM, H.J. Lu wrote: > >> If a program with the magic ELF CET flags missing can=E2=80=99t make a > >> thread with IBT and/or SHSTK enabled, then I think we=E2=80=99ve made = an > >> error and should fix it. > >> > > A non-CET program can start a CET program and vice versa. > > Could we be specific here, please? > > HJ are you saying that: > * CET program can execve() a non-CET program, and > * a non-CET program can execve() a CET program > > ? Yes. > That's obvious. > > But what are the rules for clone()? Should there be rules for > mismatches for CET enabling between threads if a process (not child > processes)? What did you mean? A threaded application is either CET enabled or not CET enabled. A new thread from clone makes no difference. --=20 H.J.