From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 32A7B44607C for ; Fri, 24 Jul 2026 16:45:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784911555; cv=none; b=p4x2j49M5JJsfE/rWEwjsYOxL8IEjIA/nQTaOeuWd8SZm0tF7uDUjX+ypvHyuyuR3FVLCcZzmHAiYO9IrPqXvtDF+7ensUMj3CX3YdaL7lPl5ewPKPvUocvsQGA1jA9bzz9TY3mKkZjodlyVnW3U6G02NUef2+O5zZX5pRLePNo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784911555; c=relaxed/simple; bh=BJs5Jl1W/NpDihy+Q+iVmkR+ttgmBWqRjUvB25osRc0=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=XmJI7rR6RH5KsZlv5qWf+Dg1xN/bBvPHtXUuCqoslza0plguRcbAlkUmkcE5MTY7q9ChMvb0G1wNmnLO5wp+8mGGb7Hn7gcDOqkG/6e7FT5DoEAd0RP4NfTfb6Iiw+Dafwz25VT7MwqBLnlufggkSxMcg9PIiq+hzOtA/fI4Z8c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=oBmJQ1r5; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="oBmJQ1r5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 113D11F000E9; Fri, 24 Jul 2026 16:45:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1784911553; bh=GkpDhp8VBPqI8hSRT9Mbj+h0fN5D/FDUMTkVMZamhDA=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=oBmJQ1r5odw77YxBFbXOhrNSqncb51aVfrP6sjGnmxKA3dGrkLb8j9UiJUtE39I23 su3F0AF5cF3LEtk190eRP9gbWvgXoe0ztuzda3vX6XTRL+jpzZEy6o48nvj5NWnwKV StsTlJ2ztUbZXhz6Fu734svC8GWjmQqYX1WUoKo6Dhpf6DxHllvKNTBiCBkc2nTyfC xWWWjfbct9acr0HVc6d+M5oCSk8TE2Vk+0yHaW47waiJ8BrYrDZc16zQKvThOBWKcF 7NpGdzrrgLGsjpsMWwszuj0nlJxMG276KVmJEMWpuNOFvZNiDG0MX3wWmF2N1e3oEv qgAuC53iR4cfA== From: Pratyush Yadav To: Mike Rapoport Cc: Pratyush Yadav , Pasha Tatashin , Alexander Graf , Muchun Song , Oscar Salvador , David Hildenbrand , Andrew Morton , Jason Miu , Jork Loeser , kexec@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 04/21] kho: return virtual address of mem_map In-Reply-To: <178410811938.820181.15709073379301681705.b4-review@b4> (Mike Rapoport's message of "Wed, 15 Jul 2026 12:35:19 +0300") References: <20260709173821.429921-1-pratyush@kernel.org> <20260709173821.429921-5-pratyush@kernel.org> <178410811938.820181.15709073379301681705.b4-review@b4> Date: Fri, 24 Jul 2026 18:45:49 +0200 Message-ID: <2vxzse58gwua.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, Jul 15 2026, Mike Rapoport wrote: >> kho: return virtual address of mem_map > > It's not really clear from where ... > >> Currently it is only used by kho_populate(), which doesn't care whether > > ... and where it is used ;-) Here's what I changed the whole thing to: kho: return virtual address of mem_map from kho_get_mem_map() Currently the preserved memory map address is returned by kho_get_mem_map_phys(). It is only used by kho_populate(). kho_populate() doesn't use the actual value. It only cares that the address exists and is valid. In coming patches, more callers will be added, all of which will need the virtual address of the preserved memory map. Since kho_populate() doesn't care about the actual value and only cares about validity, it can also use the virtual address returned by kho_get_mem_map(). It only needs to make sure the returned value is not NULL. Rename kho_get_mem_map_phys() to kho_get_mem_map() and return the virtual address of the preserved memory map. -- Regards, Pratyush Yadav