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 A03913EF0B7 for ; Thu, 22 Jan 2026 15:45:03 +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=1769096703; cv=none; b=dfeKeOKKJ8cWn3eIlF9l9sEHL20qn0gWPCC2zxWoRcXIbyl0xd/igdIxV1Uiw0trVXy1woZT5OocNoAxkIRObg+40d5GtaU2uV+w6BkzFtgCvLIUoSaSQtFMFU86o6jaueMp/RIsGd+kkGaK38xtV9hj2OFBImHxwXqKPuDb2dc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769096703; c=relaxed/simple; bh=52XMBjtg9ukz4aelwXz5NWLALBx3/KQUBQRuzd6rRXQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Oa3QkBb+2YYf4bZ7ZPC0dwlS0dUQevCIGTV8A4WnhEXOilEVOR3ywuE0cLoh8SSSHE4WUGgY2z9/dZpYCxwB8sMf1Er6iLpmY+EiITgur+LvMr/Ox5U1zwroe+4aASFjhtzIICogygOyWRs9oD99WdzK83nYvKZUiZlyjeUcS8c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Evfn9Bbf; 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="Evfn9Bbf" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48B3AC116C6; Thu, 22 Jan 2026 15:44:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1769096702; bh=52XMBjtg9ukz4aelwXz5NWLALBx3/KQUBQRuzd6rRXQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Evfn9BbfvpGnIvAvt8Oqgd2YaoDCSTDUhz5V42CGfCouBunHnAWaffYOwFoq00iGt AbBFy6MAnqXp7gH99YT888MmuofDK29O9ulFFUNTZsLZckD1JQiZ7KHeGaqlL2joDs MvPpgNnH1Nxega7/W2TEiI6yjFkQSdhfkN/frrRIkiRqN9YuOPuxP8C7SwgN4LgTfu 5yl+MM49NL1ZCh9dHZ4AMReiorkUkEpmJOnjL7jH3YjNurTBchTlTLAQdGn/s7rfum MTnyDXRLNkc5vNJGmceIijGi7uB3e6s5W3GGNNhRGm4BQzL/hg9L/yH1OHk4e7i1tx OYs6Gl+XVcUuA== Date: Thu, 22 Jan 2026 17:44:56 +0200 From: Mike Rapoport To: Pratyush Yadav Cc: Hugh Dickins , Baolin Wang , Andrew Morton , Pasha Tatashin , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] memfd: export alloc_file() Message-ID: References: <20260122151842.4069702-1-pratyush@kernel.org> <20260122151842.4069702-2-pratyush@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260122151842.4069702-2-pratyush@kernel.org> On Thu, Jan 22, 2026 at 04:18:39PM +0100, Pratyush Yadav wrote: > From: "Pratyush Yadav (Google)" > > The Live Update Orchestrator's (LUO) memfd preservation works by > preserving all the folios of a memfd, re-creating an empty memfd on the > next boot, and then inserting back the preserved folios. > > Currently it creates the file by directly calling shmem_file_setup(). > This leaves out other work done by alloc_file() like setting up the file > mode, flags, or calling the security hooks. > > Export alloc_file() to let memfd_luo use it. Rename it to > memfd_alloc_file() since it is no longer private and thus needs a > subsystem prefix. > > Signed-off-by: Pratyush Yadav (Google) Reviewed-by: Mike Rapoport (Microsoft) -- Sincerely yours, Mike.