From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 08E1B22424C for ; Fri, 2 Jan 2026 20:17:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767385056; cv=none; b=EYv3JKR/fGhB8ncFMcZV2s0x2H6q0C7hQ1n5nyG326LMRstgHT44wOHebth+5sLHMoCkNK+JPagu0UP0bPTrRmzaWhyhgte3ZQFpvvipPK3EKT9JzML+agXFtxJYAmtfD5K5caZlJ0zRc+I0+Onrhgtt5fjm1fOHQe9CpUJzdC4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767385056; c=relaxed/simple; bh=y+x3jWafn0ySZoOf7SO1BpFsnu5XwS14IRNA2tA5RQc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=Tkzxg+guWFeah0fZa7zr+460fJ8PubLgC+b4invjOijuzPT/6A4E6Dl0YNvQR5zTrQt6BOJyx0j76Mz+cNj1avG6LaQgWlDYjaOFfTb4ob2Ntk8vtxW/nPmBZUrzkxmjONJQah5bLRzi/dtjryIoMWii1EmT6CwkR6LQZFCXAIE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=RyfEeod2; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="RyfEeod2" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C0BB1C116B1; Fri, 2 Jan 2026 20:17:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1767385055; bh=y+x3jWafn0ySZoOf7SO1BpFsnu5XwS14IRNA2tA5RQc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=RyfEeod24/yZKCI7D+ni5GF12w0rIvHvu7Zs02atNyZbktGxXgW3DVO3n3l4K5k8+ ncwOjqZ6tPJjlJZ4FYteSFrzIcV4VLhljCGBJZUcRi0bmPZpoxldXzI0N7GBO3I8Xw 8+SJPE27uWSTXEomzX7o709uNxXWH1aF7mfAQORru7cIv34/gwVsawVxwLHfBeEDSA vf2x0q6d5TfIJU7MATctmxT0fjERG0+PcU79NmvH5cnV9MQi58XyeD95HBz2RzMkOk cS9VvQnArGi2uDfRNahvHvUdgEWgjPh0INnV2au9NzYMDtMQCOsZsEtpPhP6FR8mAm Nb0Ifm8fMT8UQ== From: Pratyush Yadav To: Breno Leitao Cc: Alexander Graf , Mike Rapoport , Pasha Tatashin , Pratyush Yadav , linux-kernel@vger.kernel.org, kexec@lists.infradead.org, linux-mm@kvack.org, usamaarif642@gmail.com, rmikey@meta.com, clm@fb.com, riel@surriel.com, kernel-team@meta.com Subject: Re: [PATCH v2 1/2] kexec: history: track previous kernel version In-Reply-To: <20260102-kho-v2-1-1747b1a3a1d6@debian.org> (Breno Leitao's message of "Fri, 02 Jan 2026 06:53:23 -0800") References: <20260102-kho-v2-0-1747b1a3a1d6@debian.org> <20260102-kho-v2-1-1747b1a3a1d6@debian.org> Date: Fri, 02 Jan 2026 21:17:27 +0100 Message-ID: <86secn7ors.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain > Subject: [PATCH v2 1/2] kexec: history: track previous kernel version Nit: please use the prefix "kho: " for KHO patches. On Fri, Jan 02 2026, Breno Leitao wrote: > Add CONFIG_KEXEC_HISTORY to store and display the kernel version from > the previous kexec boot. > > When enabled, the current kernel's release string is saved to the > "previous-release" property in the KHO device tree before kexec. On > the next boot, if this property exists, the previous kernel version > is retrieved and printed during early boot. > > This helps diagnose bugs that only manifest when kexecing from > specific kernel versions, making it easier to correlate crashes with > the kernel that initiated the kexec. Why can't you use journalctl to figure out which kernel was running previously? For example, you can do: $ journalctl --list-boots -2 a1d93be939b64ac4b7b26aa003bfdb93 Wed 2025-12-24 21:34:22 CET Thu 2025-12-25 02:04:07 CET -1 dbbedcf8fff54d5990c6f2a6399cfce1 Fri 2025-12-26 11:46:23 CET Fri 2025-12-26 11:46:54 CET 0 d002d51c28e748d9a7c6c8cdd391aa73 Fri 2025-12-26 17:40:52 CET Fri 2026-01-02 21:12:09 CET [...] $ journalctl -k -b -1 This will show you the full logs of the previous boot, or the one before, and so on. And when you're debugging, you'd likely want to view previous boot logs anyway. Everything you add to the KHO FDT is ABI. While we do have some flexibility in changing the ABI, I'd rather not add something that can easily be queried by existing userspace tools. > > Disabled by default to avoid overhead for users who don't need this > information. > > Signed-off-by: Breno Leitao [...] -- Regards, Pratyush Yadav