On 16/12/2024 15:28, Carlo Nonato wrote:
>
>
> Hi Michal,
>
> On Mon, Dec 16, 2024 at 2:56 PM Michal Orzel <michal.or...@amd.com> wrote:
>>
>> On 13/12/2024 17:28, Carlo Nonato wrote:
>>>
>>> Xen image is relocated to a new colored physical space. Some relocation
>>> functionalities must be brought back:
>>> - the virtual address of the new space is taken from 0c18fb76323b
>>> ("xen/arm: Remove unused BOOT_RELOC_VIRT_START").
>>> - relocate_xen() and get_xen_paddr() are taken from f60658c6ae47
>>> ("xen/arm: Stop relocating Xen").
>>>
>>> setup_pagetables() must be adapted for coloring and for relocation. Runtime
>>> page tables are used to map the colored space, but they are also linked in
>>> boot tables so that the new space is temporarily available for relocation.
>>> This implies that Xen protection must happen after the copy.
>>>
>>> Finally, since the alternative framework needs to remap the Xen text and
>>> inittext sections, this operation must be done in a coloring-aware way.
>>> The function xen_remap_colored() is introduced for that.
>>>
>>> Signed-off-by: Carlo Nonato <carlo.non...@minervasys.tech>
>>> Signed-off-by: Marco Solieri <marco.soli...@minervasys.tech>
>>> Reviewed-by: Jan Beulich <jbeul...@suse.com> # common
[...]
>> Also, this function is only executed in case of LLC coloring, so shouldn't it
>> be #ifdef protected.
>
> Here and in other places (patch #8) I'm relying on DCE to remove functions
> that are not called. This was a suggestion from Jan in that patch. Can we
> adopt the same here?
Yes, we can.
~Michal