From patchwork Mon Nov 14 11:43:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Slaby X-Patchwork-Id: 19767 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp2098440wru; Mon, 14 Nov 2022 03:50:00 -0800 (PST) X-Google-Smtp-Source: AA0mqf5EPGVv6fioHFosSbiyKt+uVnYj28cCXvGfZfV6Noisgmi9idcckL5YpNoCo5rzI85pv4a0 X-Received: by 2002:a17:907:9618:b0:78e:17ad:ba62 with SMTP id gb24-20020a170907961800b0078e17adba62mr9846766ejc.719.1668426600631; Mon, 14 Nov 2022 03:50:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668426600; cv=none; d=google.com; s=arc-20160816; b=0n+jLkqJYYGpvWautMJQHws1fGIryJ+ueD7UJSIfnoOUJ4X6dTHxpwFOSH37aQrAvk Awkr3E+ltZG0rVyq7nnwvBzPTOUXNlGXihYMtM12pVhBgrH+skrbzKh5qSylKId+v1n9 XbvMzJlgeZqN817683Ivlm68zGGqoZpU/Eobb7TIZ7bq4zqmLIv6eO+A8JKGw056NYLi mKOoLNVzaR6v4ys4ccwURup7/tf8oYdKAK2kXaQWbc+l5jUMwzgMg/CqHrwUCAuacz0C 1uPS0aXjySy5KqrweIoUo6XYeFokcm1G3Ae5kPRYJytLRRRikdM6qG+7WHYaQO5Pdxzp ekdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=hfW68vlzImJ9VWw36gGP8kKR4M7g53GIW7BTkc56XY4=; b=wrLYl2LQms91t1pSK1P74c4pM8kaxGaKjRNDRwLtrFtG2ffAMK//hPxyS/k6affHlw CbF8HUTGjkQAGZk4OgDPdxjftOOAuhd79oTxvXU9vUTNaIFVysiorLakcFKlm3LBa3XK 1oz6CJ+nNfudlsPHGgOCKl5PWbbfj/JSJDh2lA1HQPXNSghR3rq6m8L6HpwgS1NMpddg wRpSmxmQF6soKXWq/onCnLGCXt0OHLOsGQisqoR3cBpIULdCy+5eumPTeZVpy4qGRAzD JWN8A1I4vwxWgUIj0DoyvFjIZj50D+ALqphtEDENmy7W4K99caSQolMXKIM95n6UziyH kYgA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lKwgXStS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p21-20020a056402075500b0046168e49e6fsi8289715edy.80.2022.11.14.03.49.35; Mon, 14 Nov 2022 03:50:00 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lKwgXStS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236819AbiKNLsr (ORCPT + 99 others); Mon, 14 Nov 2022 06:48:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41432 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236804AbiKNLsE (ORCPT ); Mon, 14 Nov 2022 06:48:04 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 735442252F; Mon, 14 Nov 2022 03:45:35 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 10D0D61045; Mon, 14 Nov 2022 11:45:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2416DC433C1; Mon, 14 Nov 2022 11:45:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1668426334; bh=E5uKKkSwNTVS2fkyiUTAmxhhGrPiE6X9sXCDPf3qXro=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lKwgXStSf5BKGYokF2vP5wwXHZ8kyH6GC/7CZR735e0tt2uwibnhyjRwidpNrhuRE 7wuYoAIM8NIoLhYgNKKhSlEpLOC/wLxgTmxgY8cwmO7xq+/ybN6O7NLZPiuWVMnCQ8 n4+5Kt1SqPDbdFIdpVt6Jo7l8QuHjozrEkB2L0nO5sylYBZasNhS4FMUoWA5OV687r 7PENiN1LQelH6MSTfsfI+cV9z3s3l/tJn1FdHWODV5Ho42JMu8/L6I0LAn55fU2a/f PKdOKJM1aAPdAnxda4OdISiVeDjVBHrkOyOMeuiHuD661PbY2u5nzkadl/hRLPd3dM mVTEojYb5NrqQ== From: "Jiri Slaby (SUSE)" To: linux-kernel@vger.kernel.org Cc: Andi Kleen , Josh Poimboeuf , Jiri Kosina , Miroslav Benes , Petr Mladek , Joe Lawrence , live-patching@vger.kernel.org, Andi Kleen , Martin Liska , Jiri Slaby Subject: [PATCH 40/46] x86/livepatch, lto: Disable live patching with gcc LTO Date: Mon, 14 Nov 2022 12:43:38 +0100 Message-Id: <20221114114344.18650-41-jirislaby@kernel.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221114114344.18650-1-jirislaby@kernel.org> References: <20221114114344.18650-1-jirislaby@kernel.org> MIME-Version: 1.0 X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749472091468848274?= X-GMAIL-MSGID: =?utf-8?q?1749472091468848274?= From: Andi Kleen It is not supported by gcc 12 so far, so it causes compiler "sorry" messages. Other than the compiler support, there shouldn't be any barriers for live patching LTOed kernels, although it might be more difficult to create patches for larger functions. Cc: Josh Poimboeuf Cc: Jiri Kosina Cc: Miroslav Benes Cc: Petr Mladek Cc: Joe Lawrence Cc: live-patching@vger.kernel.org Signed-off-by: Andi Kleen Signed-off-by: Martin Liska Signed-off-by: Jiri Slaby --- kernel/livepatch/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/livepatch/Kconfig b/kernel/livepatch/Kconfig index 53d51ed619a3..22699adc39a6 100644 --- a/kernel/livepatch/Kconfig +++ b/kernel/livepatch/Kconfig @@ -12,6 +12,7 @@ config LIVEPATCH depends on KALLSYMS_ALL depends on HAVE_LIVEPATCH depends on !TRIM_UNUSED_KSYMS + depends on !LTO_GCC # not supported in gcc help Say Y here if you want to support kernel live patching. This option has no runtime impact until a kernel "patch"