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 3E44B3859EE for ; Fri, 30 Jan 2026 18:56:31 +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=1769799391; cv=none; b=Cfx/BoNuR9jwd7kcnzF/BE0X/dZ9/gYrzIco6LNhPBynXXirrZvbOQMp9iU52kHZI63ZUFhyI4jQMKdlkuuD1jJpBxDQmu5wOCKnNh/GqiBw+4g2hK5lNL9rhHIOrB29l2mozb58gZdPqUnag4gFMBSY7Bw3yqJQeyzhSl7w9yw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769799391; c=relaxed/simple; bh=sHgckGubDtoCbqMzmS2cfNdgZ8H+jjry4xZuPT2UdrM=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=XY45+YmvFmdoWKGLQdytufWeevPQio2LkHVNACvTeLGWIZKIei1T0Czp+bwa2JGBsQnVTlcro5hXa+4klY/rwJzbIU01EM7L2UcTc9sb6E3yQwHNuenbbv66PdgR+LBeR9OcZ7Kye8sIUG0l8BGQzzRCqwNFLplMCAe+7Bqbm2I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=bIYUD9PM; 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="bIYUD9PM" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C1A9BC4CEF7; Fri, 30 Jan 2026 18:56:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1769799390; bh=sHgckGubDtoCbqMzmS2cfNdgZ8H+jjry4xZuPT2UdrM=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=bIYUD9PM2teLHx4VLL3zKEsY+b1LPIBR+NNf3PfkybehvNHziBZHHF9gTBavsWA// SyxQwV+zcbb2iclPptFffFB3ztXJSO1xS+RCu4n3Xl+gpucPxKH4jpx5em3pXK6ZV8 7fZO9CTWGvmdBTyJu/hlyQcHNmfKcX5DHu5RffyDQ2VGdh/JSpevrBAPTuaLG3xAHm Z9XRFgIg+5XurL+9N8XY4YbVtx3Tl4Q/jPWrFNXF1bd2O+CrcNBzJc25FkkoSX50OB ORJz8nobqZFbnZJvETxXU2FnuKJOZbivb7xm0tdXN/T6mc226mKrjc1WnbThfwiIt9 g/5kwIjyvLuyw== From: Pratyush Yadav To: Mike Rapoport Cc: Pratyush Yadav , Pasha Tatashin , Andrew Morton , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH 1/2] liveupdate: luo_file: do not clear serialized_data on unfreeze In-Reply-To: (Mike Rapoport's message of "Wed, 28 Jan 2026 13:19:26 +0200") References: <20260126230302.2936817-1-pratyush@kernel.org> <20260126230302.2936817-2-pratyush@kernel.org> Date: Fri, 30 Jan 2026 19:56:28 +0100 Message-ID: <2vxzv7gj7wv7.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 On Wed, Jan 28 2026, Mike Rapoport wrote: > On Tue, Jan 27, 2026 at 12:02:52AM +0100, Pratyush Yadav wrote: >> From: "Pratyush Yadav (Google)" >> >> The unfreeze operation is supposed to undo the effects of the freeze >> operation. serialized_data is not set by freeze, but by preserve. >> Consequently, the unpreserve operation needs to access serialized_data >> to undo the effects of the preserve operation. This includes freeing >> the serialized data structures for example. >> >> If a freeze callback fails, unfreeze is called for all frozen files. >> This would clear serialized_data for them. Since live update has failed, >> it can be expected that userspace aborts, releasing all sessions. When >> the sessions are released, unpreserve will be called for all files. The >> unfrozen files will see 0 in their serialized_data. This is not expected >> by file handlers, and they might either fail, leaking data and state, or >> might even crash or cause invalid memory access. >> >> Do not clear serialized_data on unfreeze so it gets passed on to >> unpreserve. There is no need to clear it on unpreserve since luo_file >> will be freed immediately after. >> >> Fixes: 7c722a7f44e0 ("liveupdate: luo_file: implement file systems callbacks") >> Signed-off-by: Pratyush Yadav (Google) > > Reviewed-by: Mike Rapoport (Microsoft) Thanks. Andrew, do you mind taking this patch in v6.19-rc8/v6.19 hotfixes? The second patch needs a re-roll and I don't think I would be able to do it this week. This is an independent fix and I see no reason to block this waiting for the other one. [...] -- Regards, Pratyush Yadav