From patchwork Tue Dec 20 22:05:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Ribalda X-Patchwork-Id: 35200 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp3205619wrn; Tue, 20 Dec 2022 14:08:45 -0800 (PST) X-Google-Smtp-Source: AA0mqf4ruUsTe+dxfStzY4J8odK9MyL5A3RIfWomOaK/D06rp5kCDYdakBEc9JBpkezu39vKjTdC X-Received: by 2002:a17:906:c0c4:b0:78d:f455:b4d5 with SMTP id bn4-20020a170906c0c400b0078df455b4d5mr32523591ejb.60.1671574125394; Tue, 20 Dec 2022 14:08:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671574125; cv=none; d=google.com; s=arc-20160816; b=w1hWxieTki9O+KTe47tTLCUw/a+KLkx8x5Q2a6JvdE4ifr0Fw6JViGuOmqvnPCWuO9 yhgW2R3yaoCfwmOpIqWB5vWSDh6f7vcIkuFeM+0Uoly9vE7XULUl6KMBN9L6exRKQ/Io ds4zozFd3pq/z7CA8n5OyjgjEoSp8kdbNmFpaR9yKubVzCIrcZO21/3MZ3Mz7aQ3yrCI B74SBJWykL6LormoM7/JgwZtMQTdKA1Lfn1ZaGuHGYGsYbAyzvr47X+A5o6oQW4Fq8sA vff26SxxuTr9dyGzrYMGfVcNmPf0/zYPHAwGp1IZ+cVi8r8kPeSwO0yGmc4P5djlBNr5 3xfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=xv7lgqcsWR7csyQW/ua9GbEMjmdKQM2eL6DIBrKZNHc=; b=m6wtFkz1or1nILz6wKiOp8pBHJbHz0CkffxPvcSRrcxQhrFDjeW3/a/lf014iQ8peQ D8Sh+9wWUQBVpTjGUZuNU/CHqOzeLzdP5RJZSIkAxRhZxnBiGYucYqLQDLS99E4fihIu 99IviWiGTQoPhncyB4jwwLNGWaHsgMjQgLQcphBryWwzJlg41HVv0rb9oxFT7+LEXYTO jm7hZPDWe3ca82UpSuRb3z06wh+pMTPiWx9BmFp1Pk0EvWZdMY37+HXeIf0W/SzBXQrC jmTWU9WYzDUAMIQ4UcS0JfitoiA/BPgjHxdMILWhGWk+qinZNT6yIy5Nilz7qcVoR+hl 9rVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=QZyYvSYS; 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=chromium.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m7-20020a170906848700b00787c0e9818csi10782619ejx.568.2022.12.20.14.08.22; Tue, 20 Dec 2022 14:08:45 -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=@chromium.org header.s=google header.b=QZyYvSYS; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234149AbiLTWGQ (ORCPT + 99 others); Tue, 20 Dec 2022 17:06:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33422 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234134AbiLTWGK (ORCPT ); Tue, 20 Dec 2022 17:06:10 -0500 Received: from mail-ej1-x631.google.com (mail-ej1-x631.google.com [IPv6:2a00:1450:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ED1661838A for ; Tue, 20 Dec 2022 14:06:07 -0800 (PST) Received: by mail-ej1-x631.google.com with SMTP id x22so32494715ejs.11 for ; Tue, 20 Dec 2022 14:06:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=xv7lgqcsWR7csyQW/ua9GbEMjmdKQM2eL6DIBrKZNHc=; b=QZyYvSYS/5R/0vxSGWLo/6TrG71If7NC5DtCubDinMXdIvsAOTSsTYPjceSC5lhJec BXd6ndGzKfOPGsXk7IAnWkD2+Jg9cIRiiS2AMo0PWk/H6f73e5vb/qkVYFuzoPnK9/Es mlmynVTyGNzumcJRS3bL1ypHkrfyanKKrHzs4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xv7lgqcsWR7csyQW/ua9GbEMjmdKQM2eL6DIBrKZNHc=; b=hGjsjC6xg6lZNgohp9i6N2NEmxch3FN7ST/+3K9GV45PHrqBbWn43WqP2oRRu8pcox LBQ9dnwZHBy4nxb3WPnEeSbNwBc13nfXm3Pt6MqOjWXSZUIdvwKNOyaN1rlGrJbSEnvf pRbD+EOU/cp6QU317yGeUG6yEwKmBX2/nhJRITpHg5mFsXsieve68EBIVAkhSHODDybh fPi45qp2ynJ8WV7hTeZC3ZcK3ordYZiiLoztsCOz/R1/vuV0eVOZAE8+vKW44XsNxO6g z9pXuUGYHnYCP3aG7l9rO2OjxWVJCXGToDWWWvdXMQU1MZUeguKivkIqvQxe5Ov2PoJF 7ppw== X-Gm-Message-State: ANoB5plRMbm5MOhGGmaEIz4PYlRknZpNYyPApBDQ6PsM8z7CvwyXDUVR MNpxbEC3Tk4v/hrc1EI4NQY/4w== X-Received: by 2002:a17:906:f6d7:b0:7c0:bf7c:19f4 with SMTP id jo23-20020a170906f6d700b007c0bf7c19f4mr40561370ejb.74.1671573966509; Tue, 20 Dec 2022 14:06:06 -0800 (PST) Received: from alco.roam.corp.google.com (80.71.134.83.ipv4.parknet.dk. [80.71.134.83]) by smtp.gmail.com with ESMTPSA id ku13-20020a170907788d00b00837ac146a53sm1175492ejc.23.2022.12.20.14.06.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Dec 2022 14:06:06 -0800 (PST) From: Ricardo Ribalda Date: Tue, 20 Dec 2022 23:05:43 +0100 Subject: [PATCH v3 1/3] Documentation: sysctl: Correct kexec_load_disabled MIME-Version: 1.0 Message-Id: <20221114-disable-kexec-reset-v3-1-4ef4e929adf6@chromium.org> References: <20221114-disable-kexec-reset-v3-0-4ef4e929adf6@chromium.org> In-Reply-To: <20221114-disable-kexec-reset-v3-0-4ef4e929adf6@chromium.org> To: Philipp Rudo , Eric Biederman , Jonathan Corbet , "Guilherme G. Piccoli" Cc: linux-doc@vger.kernel.org, Sergey Senozhatsky , Steven Rostedt , linux-kernel@vger.kernel.org, "Joel Fernandes (Google)" , Ricardo Ribalda , Ross Zwisler , kexec@lists.infradead.org X-Mailer: b4 0.11.0-dev-696ae X-Developer-Signature: v=1; a=openpgp-sha256; l=1258; i=ribalda@chromium.org; h=from:subject:message-id; bh=U6cVA0f3MVv7jTHbprLKEENRfx9C5MeH7N8/eIFjhzo=; b=owEBbQKS/ZANAwAKAdE30T7POsSIAcsmYgBjojHIpdmcVeMVxZ7UQR/ZxrK0wjocsFOqbUXV1Pzf kKjKvmWJAjMEAAEKAB0WIQREDzjr+/4oCDLSsx7RN9E+zzrEiAUCY6IxyAAKCRDRN9E+zzrEiFfID/ 9z8ZdKo6lWAEJ3T0FZH9P5dUY7+G8f57r2NUYkbXfSZyBnKZrzNJO/zzg6qs0zVpVhq0Q6tya9Lr5n i9pKqqZzciEhZ5dxXjxdUSdA+bnNgCHYoV19PtdKclGJWT3ZlunTNW6b+m2ecsEEwry0nzYTY8tfmX 0Z2upPGKphHkKHuehW+ZatYoiD9ryoeqcsUa/ISkFK3J2H5tlKeqTK2uJwxEAyYJewvSydZUCPvHAv 8ZUh4us+RWedvK9hUg+79yijwSID58bKxu7aAsRdhMef+vRkERdD4hYDEHoCFVoO0BytlMagDtbC55 7p2OA6GEjZ2rjT41K6fO1h9gZcScdk3oYi4mdeAFZz81BpO237UWXl3ONMimGUS8nOhYkULDJ/gL+i PRRgDg3X/pcbA/EwQCjr0sjvCIFH7+kUYsG5ugtmyoWYS3v6xyIsgwkcN1vapyrWDtiwqQvZgZAnO+ zaiPo0WMlJ8U16DM2A0hxHsvqQVtUq4/3ZOti2PXiwSjbF9Hkcs+huWx6+r9ZIpDU4cS6DRcpi6JWj GXAjtzK3OYQmK4Tfy91pBoGNKL15xLeJ7zbR+t9Llz1b4P5Yr7pbW0Niku63bJ8EhyWZqUSwSEUey1 Z8QP37ORLoJzuJVT/YNbvtLZOzvKP3bWpLxPZ6Ax6fx4bMYhgraJntD8MAJA== X-Developer-Key: i=ribalda@chromium.org; a=openpgp; fpr=9EC3BB66E2FC129A6F90B39556A0D81F9F782DA9 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, 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?1752772510051427852?= X-GMAIL-MSGID: =?utf-8?q?1752772510051427852?= kexec_load_disabled affects both ``kexec_load`` and ``kexec_file_load`` syscalls. Make it explicit. Signed-off-by: Ricardo Ribalda --- Documentation/admin-guide/sysctl/kernel.rst | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Documentation/admin-guide/sysctl/kernel.rst b/Documentation/admin-guide/sysctl/kernel.rst index 98d1b198b2b4..97394bd9d065 100644 --- a/Documentation/admin-guide/sysctl/kernel.rst +++ b/Documentation/admin-guide/sysctl/kernel.rst @@ -450,9 +450,10 @@ this allows system administrators to override the kexec_load_disabled =================== -A toggle indicating if the ``kexec_load`` syscall has been disabled. -This value defaults to 0 (false: ``kexec_load`` enabled), but can be -set to 1 (true: ``kexec_load`` disabled). +A toggle indicating if the syscalls ``kexec_load`` and +``kexec_file_load`` have been disabled. +This value defaults to 0 (false: ``kexec_*load`` enabled), but can be +set to 1 (true: ``kexec_*load`` disabled). Once true, kexec can no longer be used, and the toggle cannot be set back to false. This allows a kexec image to be loaded before disabling the syscall,