Hi Luca,

On 09/11/2023 10:06, Luca Fancellu wrote:
> 
> 
> Currently the dom0less feature code is mostly inside domain_build.c
> and setup.c, it is a feature that may not be useful to everyone so
> put the code in a different compilation module in order to make it
> easier to disable the feature in the future.
> 
> Move gic_interrupt_t in domain_build.h to use it with the function
> declaration, move its comment above the declaration.
> 
> The following functions are now visible externally from domain_build
> because they are used also from the dom0less-build module:
>  - get_allocation_size
>  - set_interrupt
>  - domain_fdt_begin_node
>  - make_memory_node
>  - make_resv_memory_node
This one, despite the name, is strictly related to shmem. Shouldn't we move it 
to static-shmem?

>  - make_hypervisor_node
>  - make_psci_node
>  - make_cpus_node
>  - make_timer_node
>  - handle_device_interrupts
>  - construct_domain
>  - process_shm
>  - allocate_bank_memory
What about static event channels? Does it make sense to leave it unguarded? 
Reading the docs,
it looks like at least one domU needs to be present (dom0-domU or domU-domU). 
Hovever, looking at the code it should
be possible for a loopback. That said, I don't really find it useful given that 
loopback does not really need this feature.

> 
> The functions allocate_static_memory and assign_static_memory_11
> are now externally visible, so put their declarations into
> domain_build.h and move the #else and stub definition in the header
> as well.
> 
> Move is_dom0less_mode from setup.c to dom0less-build.c and make it
> externally visible.
> 
> The function allocate_bank_memory is used only by dom0less code
> at the moment, but it's been decided to leave it in domain_build.c
> in case that in the future the dom0 code can use it.
> 
> Where spotted, fix code style issues.
> 
> No functional change is intended.
> 
> Signed-off-by: Luca Fancellu <[email protected]>
> ---
> Changes from v2:
>  - move allocate_bank_memory back in domain_build.c, remove header
>    from dom0less-build.c.
I can see you removed the copyright from .c but .h still has it. This also
applies to other newly introduced files that were subject only to code movement.

~Michal

Reply via email to