From nobody Tue Feb 10 04:02:29 2026 Received: from mail-yx1-f47.google.com (mail-yx1-f47.google.com [74.125.224.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1810933FE04 for ; Fri, 14 Nov 2025 15:54:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.224.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763135657; cv=none; b=ewbxaWLWZYRxHnZ8pjRmr3igXUe7RxG+pU9tZQxfq7QhvC9uumkDGqpa9O6qAF+Sx2n0ffEB8vFNEs3EeOeXiXLQirFDWbV1DLp5LvIEQAby7yOR4q2TUHkCYyL9f4Ukb0RCK51EKj4uWe1B/0yvWsknCTr2XCCv/mrnKEC35Jk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763135657; c=relaxed/simple; bh=irEd8dNRzXTz3ItIhrktkMYklah6PA9Xwqom90lqlW4=; h=From:To:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=RCfTs7+viI5vjqPDE278n5rF9/+lBKOMYox3qbjr61xKiJ95+T/miIv8v8myAYhxgiYFnPO65hIVMt/uFTqGyJHQLUYCaxWGjmQD6oBWk4rFdfBXaBFToceTutaHmlDfaIrrP8EzEsQPNmb/2v+yJfGPiW0TIpgcYSEZ8DEDza0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=soleen.com; spf=pass smtp.mailfrom=soleen.com; dkim=pass (2048-bit key) header.d=soleen.com header.i=@soleen.com header.b=er6V7C9R; arc=none smtp.client-ip=74.125.224.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=soleen.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=soleen.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=soleen.com header.i=@soleen.com header.b="er6V7C9R" Received: by mail-yx1-f47.google.com with SMTP id 956f58d0204a3-640c857ce02so2009307d50.0 for ; Fri, 14 Nov 2025 07:54:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=soleen.com; s=google; t=1763135655; x=1763740455; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=iTGqBwhVIw9stl5AxN+42Iq44gONjHHbYM4Z4BBnC/g=; b=er6V7C9RWq+YO9u8XS5UHkphGCT9MjG9RLID+7AV6kMn5FEVbXR7OOYvOHRx8T30nq peNx5BJ9bYwB9VSiBYvf4sx5e5bK5n3cp4ExYmQ+jhzQN8RqAx8G6YwcHDyrRp3BChS3 ijPLTQf3XTVKaAbmkbn9982ZH+3S0xmjwLqawOsa5F9LBwQvr1mkPuJB56AdLcOFWdJS jT5+nS95dZ2w58acGwxRmdhx1QiiLcIFQPLCmADQRoOgye97DN1yqxEsrMa7CjF7nPAA 09nEWADQfPKgg31MUfSwuuKM+ucVXdAGDM+JeYB8HHQW+g7XiUFPovEhUFu0uFZ8w2sq V6lw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763135655; x=1763740455; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=iTGqBwhVIw9stl5AxN+42Iq44gONjHHbYM4Z4BBnC/g=; b=AGnH/Mz7PyZqi2cfasNeKiiJmxallbgj6ZjySKbJfZjE8a3b7/2j62UmrPzUvd5hqV vhksLshVd99NSLIDRTSZLWAxfis2RGPRkhFoGwso0jODzGafNNECROEKoPh6qVMhNkuo HDn7coUKq5XcbkVQDvNbLeZkfEENIa/+39zUKZOHv3tTtmQzN5zT00hL42p7iXTM5xff L/iFppQbzPftxIOWTPuKVuMDLZ0tBV+/pXdfFjN0ul0ntZEG5ay526DpWgALm7wYaH+O YmBB4cM9th2Dw+5j9jVvjZBgIN8jG/KMs79Qed01M1hZhIrI5P/TI+ymIDzGlt76GXDq O4fg== X-Forwarded-Encrypted: i=1; AJvYcCXavTwo4FDhHL6WVQKLTDoGfag9yaz4mQAU0M9D68qzlnztr9KxDqCRd657IRT1Hj8dzU9ovY6GhGmXAEA=@vger.kernel.org X-Gm-Message-State: AOJu0YwdlFv0nutJAdjhTofcx5maq702J5iuUa0Qsd5icB19JfM2bXnm hfFt9tKmyBSyunzOsGa3H2DRC4rZu0UNbn3LGeoFNn1Agn+iJcSnrGYcaPG079FEhbQ= X-Gm-Gg: ASbGnctJW9wb+Di4E4ekcn3cWY/rFVTeeiENnoFeE874jhyVEngAZWufg90TfEGoU/q KIju/ydAHxKgC4CqLEJz299mFQK0/OmgfB3FTa5Qtl2xi8DW7MFbrMr25NL/7UW9FWiIv7wOkOk XUbKIqNzjPeBnnXrl8XZ3lHxahJc51Yf+cWg/cwFgNGnxMz51FJns1klc0X5SUkNFKUz0xwhPJ6 7A48JMcdDAaBnBT0uSNx1ZFJ3wiuLTmV7FA7dIi2EvjqMVA0a0zpsl6xZJQdLC3bDI0mt4bS6+7 6sPfIoTA1LCsSK6j4Yoi1dujEIirmcCYwlGHbrEf5icFXQhpGqnw5nmLj5XD/6DYttz7ICpEKKH c8dmR27MFcg4M1xZ68ISoTYmLkyMVniWa+I/jstdduv48Fj4/70pBFVyFGZCfscV3JXQmUyLRxF hImSzJfN03Yxibe/dICTFnB/Phphjy/n2tW1eSfLvWwGFfBhylfcQgVWHpcN3JVqkpKzCwwdPpZ K0/8f8= X-Google-Smtp-Source: AGHT+IG4mQw8nEL1m3idlNaAXf7Kc5783jAJw1K5t9cvJ10mUhr5v9D0Cg51BzHrwu9IlD9mh5aUEA== X-Received: by 2002:a53:d058:0:20b0:640:db91:33d6 with SMTP id 956f58d0204a3-641e74dc5d1mr2579255d50.8.1763135655068; Fri, 14 Nov 2025 07:54:15 -0800 (PST) Received: from soleen.c.googlers.com.com (182.221.85.34.bc.googleusercontent.com. [34.85.221.182]) by smtp.gmail.com with ESMTPSA id 00721157ae682-78822125317sm16468577b3.37.2025.11.14.07.54.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Nov 2025 07:54:14 -0800 (PST) From: Pasha Tatashin To: akpm@linux-foundation.org, bhe@redhat.com, pasha.tatashin@soleen.com, rppt@kernel.org, jasonmiu@google.com, arnd@arndb.de, coxu@redhat.com, dave@vasilevsky.ca, ebiggers@google.com, graf@amazon.com, kees@kernel.org, linux-kernel@vger.kernel.org, kexec@lists.infradead.org, linux-mm@kvack.org Subject: [PATCH v1 12/13] kho: Add Kconfig option to enable KHO by default Date: Fri, 14 Nov 2025 10:53:57 -0500 Message-ID: <20251114155358.2884014-13-pasha.tatashin@soleen.com> X-Mailer: git-send-email 2.52.0.rc1.455.g30608eb744-goog In-Reply-To: <20251114155358.2884014-1-pasha.tatashin@soleen.com> References: <20251114155358.2884014-1-pasha.tatashin@soleen.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Currently, Kexec Handover must be explicitly enabled via the kernel command line parameter `kho=3Don`. For workloads that rely on KHO as a foundational requirement (such as the upcoming Live Update Orchestrator), requiring an explicit boot parameter adds redundant configuration steps. Introduce CONFIG_KEXEC_HANDOVER_ENABLE_DEFAULT. When selected, KHO defaults to enabled. This is equivalent to passing kho=3Don at boot. The behavior can still be disabled at runtime by passing kho=3Doff. Signed-off-by: Pasha Tatashin Reviewed-by: Pratyush Yadav --- kernel/liveupdate/Kconfig | 14 ++++++++++++++ kernel/liveupdate/kexec_handover.c | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/kernel/liveupdate/Kconfig b/kernel/liveupdate/Kconfig index eae428309332..a973a54447de 100644 --- a/kernel/liveupdate/Kconfig +++ b/kernel/liveupdate/Kconfig @@ -37,4 +37,18 @@ config KEXEC_HANDOVER_DEBUGFS Also, enables inspecting the KHO fdt trees with the debugfs binary blobs. =20 +config KEXEC_HANDOVER_ENABLE_DEFAULT + bool "Enable kexec handover by default" + depends on KEXEC_HANDOVER + help + Enable Kexec Handover by default. This avoids the need to + explicitly pass 'kho=3Don' on the kernel command line. + + This is useful for systems where KHO is a prerequisite for other + features, such as Live Update, ensuring the mechanism is always + active. + + The default behavior can still be overridden at boot time by + passing 'kho=3Doff'. + endmenu diff --git a/kernel/liveupdate/kexec_handover.c b/kernel/liveupdate/kexec_h= andover.c index 87e9b488237d..a905bccf5f65 100644 --- a/kernel/liveupdate/kexec_handover.c +++ b/kernel/liveupdate/kexec_handover.c @@ -50,7 +50,7 @@ union kho_page_info { =20 static_assert(sizeof(union kho_page_info) =3D=3D sizeof(((struct page *)0)= ->private)); =20 -static bool kho_enable __ro_after_init; +static bool kho_enable __ro_after_init =3D IS_ENABLED(CONFIG_KEXEC_HANDOVE= R_ENABLE_DEFAULT); =20 bool kho_is_enabled(void) { --=20 2.52.0.rc1.455.g30608eb744-goog