Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1040704iob; Fri, 13 May 2022 20:43:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwWqes3rIsenPgxL0YD0I8QQ6CWCNq7sqZ9JgT/cOXQMejR1S3nQ2npAcS5I3jaO65ExcnI X-Received: by 2002:a5d:5251:0:b0:20c:d4d4:42ee with SMTP id k17-20020a5d5251000000b0020cd4d442eemr6180303wrc.382.1652499804975; Fri, 13 May 2022 20:43:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652499804; cv=none; d=google.com; s=arc-20160816; b=NvNe0v1EBBHUBOdCFHGrYzPOS+LUVGJ3x5qZNX2WKTlS9AHhxRRneuAg1jE4Hnd9Mh iHeLGTO69FUxoh/hoi7LnZcdMpbkstenQE5bJTldkKeLLa2+dBzlO9dUYZkTRSvGAiWL +k0mcU2ATXzNsWWiVRJJqyNzYH3pGB4TRVeU2uJTt3j+cCLavPGsl3okGKTvEm2ca/CT 7cz2VOv2zW+zL4jA+XmG6L6gYNSq/bzhPVN/qRm+pSM0qgr5kW7ie+WaLnzf7zt83C+5 BKZwk6nrbCVbAJXLWsVjSj5PaCKxbaFCUcGQIPLcqbIQJtnXLOpDV/QFOSHYjnq1aqsP dCdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:references:mime-version :message-id:in-reply-to:date:dkim-signature; bh=PfUOUCtWYZGmp8CXclCTWw0GE2v5WPFVxnxla7QB7vw=; b=kN7nK3IFcHt/00h2BhwnDHfRm0dMX5CrSJmzERFJPy7XMTc1idruVKVyEl+wyNFqTs qG9jaPYz6QXFsQf5K0lWY1+0ejWkacZFcS235cbbUQ/mMJbvNCGT4SyB6vmBCC/CMtVp xap+ojVIQ6ZGatwagXY23NdZKGlKLtOiPgneRnNokVeSTimWH2VVSsVBnyxnwFXa2UFt +oLZade+7K3syr+Z8VEOz+busnXFsknyd7+xOQLcyk5Ss4txzXKAsk594yGvQbkxbrsk RbyQvWfPsGkmFElGVqhmdAC2bet/Ek+bItv6veA48u/2Cxxx0jDlFH+q8MyWo5Rr5skp nFoQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=nCubo4qm; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id p26-20020a1c545a000000b003905e7f5d82si9099224wmi.154.2022.05.13.20.43.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 20:43:24 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=nCubo4qm; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id A162811455; Fri, 13 May 2022 17:17:56 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1384243AbiEMUXc (ORCPT + 99 others); Fri, 13 May 2022 16:23:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44556 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1384184AbiEMUWs (ORCPT ); Fri, 13 May 2022 16:22:48 -0400 Received: from mail-yw1-x114a.google.com (mail-yw1-x114a.google.com [IPv6:2607:f8b0:4864:20::114a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3EDE15E604 for ; Fri, 13 May 2022 13:22:43 -0700 (PDT) Received: by mail-yw1-x114a.google.com with SMTP id 00721157ae682-2fec016ade1so16369937b3.6 for ; Fri, 13 May 2022 13:22:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=PfUOUCtWYZGmp8CXclCTWw0GE2v5WPFVxnxla7QB7vw=; b=nCubo4qm3EWLu8ph4cU0J48klMHpfNRcdDDHvRk87yHuzwBoIBJ/AU7Zj01a7RdZIF t6ik+RXGU61svm9iFsdm0UO6eotpCIPJMowDcoGi43HtZioBN2GSc7Bb/24mH+Y1XxI/ H2UqwryguqTCBR6WTNv/1J0rrcU4SgUpj/DCVM+I43JCXI9PY0ZuqC6e3pyWT8kxLHXz aypLH1zJKclQCdpSo+hy/cCSzYH+emciZNSjzDJjmkCQGnRGZTqaCMDjwLCQp7F7hD8B lNK/pR0WZNB0QYRB2IObpdQwuIcXVOFy3fveUYDJmRy2HB/sObRtwd1nPyaJGlvjuvKx 1jew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=PfUOUCtWYZGmp8CXclCTWw0GE2v5WPFVxnxla7QB7vw=; b=bLEW6n9HiOnXdfWEURiEftrvabm8Op/DC7varsgAJEPhSpR71CcG5mX2AzDy7M4ZjA 6RSrkCmqU/xRvuF4RoqPA2hmIqlDw5PlRIAVEkKYGQMlR2hjX169NPKBVfnPyh7bNV4E mKES0zhAD6q31mX3lbcf3ngyaWJyEeWqoEKyaIkhQWRBkcoVS3OpurI/PiF5vhqP54At UqkgeRrjHvp7CbuAc2UZHLTcIhfQkowiGaMnFgWs2mFtrUAysX6kr0cY2885789y+9bx +5eNE0ESHURy0nfv0E1HbItR6ABvb1PHurnH14vIr2ALNXDV4Iu8eIg98ACopEBAdyvX aW6w== X-Gm-Message-State: AOAM5330SqlCXMgBHEmH7PhKTNQbNVacEGyUNzphHzE8VEDdRd4AsEEB How509cOysSkdQczRgQUKqqyp8Oz/hYuATyoJXVUo506365/Obtojp9amBmgDhDEw0L3awW37gm uLl4S7kDJEn9E+lKxQqu+Ib4gumamF1uqGyhyUfsQSgL1Q6x5yKzy2q90dPjv1aKjk9364L270+ mhifGsZ78aGg== X-Received: from samitolvanen1.mtv.corp.google.com ([2620:15c:201:2:e0:c17e:c2dc:13eb]) (user=samitolvanen job=sendgmr) by 2002:a25:8c03:0:b0:649:c7f8:1fc9 with SMTP id k3-20020a258c03000000b00649c7f81fc9mr6802241ybl.587.1652473363438; Fri, 13 May 2022 13:22:43 -0700 (PDT) Date: Fri, 13 May 2022 13:21:56 -0700 In-Reply-To: <20220513202159.1550547-1-samitolvanen@google.com> Message-Id: <20220513202159.1550547-19-samitolvanen@google.com> Mime-Version: 1.0 References: <20220513202159.1550547-1-samitolvanen@google.com> X-Developer-Key: i=samitolvanen@google.com; a=openpgp; fpr=35CCFB63B283D6D3AEB783944CB5F6848BBC56EE X-Developer-Signature: v=1; a=openpgp-sha256; l=867; h=from:subject; bh=1zGkTRBFsYQeOh1nY0Ftktys2F76fLo0aIs4c+r3/F0=; b=owEB7QES/pANAwAKAUy19oSLvFbuAcsmYgBifr3lqAwmlxBUGYGrHtGRBycX29CVlKsWO3WkULXp 4RXxZyyJAbMEAAEKAB0WIQQ1zPtjsoPW0663g5RMtfaEi7xW7gUCYn695QAKCRBMtfaEi7xW7iRJC/ 40aO3dHx7HRqL5IBxJl4LEnss6Sben7NjXL1WF89h7qFltZ5dAJeU01SJQLXBbFrGMVwlJ6QXAdGEj 635LhB+9rvz3J3LtnqvUssb7EF73SxuPBnb6OMm+qYoJRX6x4QzHFUBMSpT7nQgeSRXxgqGzkDSRup vh3xGCK6gB9qpNMP6tfQC0arD6MlBlA6GdKe9mp1HvtqGMQB7swpv2WD9cOCfE9KLcH0y91ynQ6g4U UZPiaQZWKDZYiQPJldKSe7moKZrikR0U0Qo5Q553qfQPjeadJ5XvtghpEAkLCafukyveKh4N09VV1w S5uP5cVYPc1iWKtXKqmCRwCpMMwF7IuEhjpg+hVIGDfAoBFfQZc7B4mxMlOChIzO8+9ddE4OTx6XxB YRAfx/UF3uy7/M0r/sDjqemuUQ62BUUmbl2fY3WLz7xKDa+6xiPI1E+yb9szaxBwq3DbFWH1ubyPnI mSllpHUKTR62DNzA8dewcd7rUu26o+Zb8p+isVc2xVeb0= X-Mailer: git-send-email 2.36.0.550.gb090851708-goog Subject: [RFC PATCH v2 18/21] x86/purgatory: Disable CFI From: Sami Tolvanen To: linux-kernel@vger.kernel.org Cc: Kees Cook , Josh Poimboeuf , Peter Zijlstra , x86@kernel.org, Catalin Marinas , Will Deacon , Mark Rutland , Nathan Chancellor , Nick Desaulniers , Joao Moreira , Sedat Dilek , Steven Rostedt , linux-hardening@vger.kernel.org, linux-arm-kernel@lists.infradead.org, llvm@lists.linux.dev, Sami Tolvanen Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.5 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE, USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Disable CONFIG_CFI_CLANG for the stand-alone purgatory.ro. Signed-off-by: Sami Tolvanen Reviewed-by: Nick Desaulniers Tested-by: Nick Desaulniers Tested-by: Sedat Dilek --- arch/x86/purgatory/Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/x86/purgatory/Makefile b/arch/x86/purgatory/Makefile index ae53d54d7959..b3fa947fa38b 100644 --- a/arch/x86/purgatory/Makefile +++ b/arch/x86/purgatory/Makefile @@ -55,6 +55,10 @@ ifdef CONFIG_RETPOLINE PURGATORY_CFLAGS_REMOVE += $(RETPOLINE_CFLAGS) endif +ifdef CONFIG_CFI_CLANG +PURGATORY_CFLAGS_REMOVE += $(CC_FLAGS_CFI) +endif + CFLAGS_REMOVE_purgatory.o += $(PURGATORY_CFLAGS_REMOVE) CFLAGS_purgatory.o += $(PURGATORY_CFLAGS) -- 2.36.0.550.gb090851708-goog