OK, some more remarks:

On 2016-08-28 14:39, Ralf Ramsauer wrote:
> If the cell id is chosen by the driver instead of the hypervisor, the
> cell id gets part of the cell configuration.
> 
> As part of the configuration, move the cell id from hypervisor's struct
> cell to struct jailhouse_cell_desc, as this structure is passed from the
> driver to the hypervisor.
> 
> Let the hypervisor as well as the driver check collisions of cells.
> Both, cell name and cell id are still both unique values.
> 
> Signed-off-by: Ralf Ramsauer <[email protected]>
> ---
>  Documentation/hypervisor-interfaces.txt    |  4 ++--
>  driver/cell.c                              | 23 +++++++++++++++++------
>  hypervisor/arch/arm/mmu_cell.c             |  4 ++--
>  hypervisor/arch/x86/amd_iommu.c            |  8 ++++----
>  hypervisor/arch/x86/vtd.c                  |  8 ++++----
>  hypervisor/control.c                       | 26 +++++---------------------
>  hypervisor/include/jailhouse/cell-config.h |  1 +
>  hypervisor/include/jailhouse/cell.h        |  2 --
>  hypervisor/setup.c                         |  1 -
>  9 files changed, 35 insertions(+), 42 deletions(-)
> 

...

> diff --git a/hypervisor/include/jailhouse/cell-config.h 
> b/hypervisor/include/jailhouse/cell-config.h
> index 8e8495d..4e2b5cb 100644
> --- a/hypervisor/include/jailhouse/cell-config.h
> +++ b/hypervisor/include/jailhouse/cell-config.h
> @@ -48,6 +48,7 @@
>  struct jailhouse_cell_desc {
>       char signature[8];
>       char name[JAILHOUSE_CELL_NAME_MAXLEN+1];
> +     unsigned int id; /* set by the driver */

__u32 - we want to be explicit regarding the width.

Furthermore, when changing this structure, you also need to update
jailhouse-cell-linux. Maybe a good time to leave a comment here that
refers to this non-obvious dependency.

Jan

-- 
Siemens AG, Corporate Technology, CT RDA ITP SES-DE
Corporate Competence Center Embedded Linux

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to