On 3/22/2019 5:33 PM, Jan Kiszka wrote: > On 22.03.19 10:44, 'Lokesh' via Jailhouse wrote: >> From: Nikhil Devshatwar <[email protected]> >> >> When IOMMU drivers are supported, it will setup the IO address >> translation tables unique for each DMA context in the system. >> >> A typical DMA context is identified by an integer called stream id. >> To setup the correct IOMMU mapping, hypervisor should know >> list of all the streamIDs that should be setup in the IOMMU. >> >> Add an array of streamIDs in the VMconfig, bump up the config revision. > > Let's call VMconfig "cell config", that's more common in our context. > Sure, will fix it in next version. >> Change the python struct unpacking logic in the tools to reflect >> revised config structure. >> >> Signed-off-by: Nikhil Devshatwar <[email protected]> >> Signed-off-by: Lokesh Vutla <[email protected]> >> --- >> include/jailhouse/cell-config.h | 3 ++- >> tools/jailhouse-cell-linux | 4 ++-- >> tools/jailhouse-hardware-check | 2 +- >> 3 files changed, 5 insertions(+), 4 deletions(-) >> >> diff --git a/include/jailhouse/cell-config.h >> b/include/jailhouse/cell-config.h >> index 519afefc..9a26a2c5 100644 >> --- a/include/jailhouse/cell-config.h >> +++ b/include/jailhouse/cell-config.h >> @@ -45,7 +45,7 @@ >> * Incremented on any layout or semantic change of system or cell >> config. >> * Also update HEADER_REVISION in tools. >> */ >> -#define JAILHOUSE_CONFIG_REVISION 10 >> +#define JAILHOUSE_CONFIG_REVISION 11 >> #define JAILHOUSE_CELL_NAME_MAXLEN 31 >> @@ -90,6 +90,7 @@ struct jailhouse_cell_desc { >> __u32 pio_bitmap_size; >> __u32 num_pci_devices; >> __u32 num_pci_caps; >> + __u32 sids[32]; > > stream_ids. When will we need more than 32? Or less? Should we rather > have a struct with a size define here? okay, make sense. Will fix it in next version. Thanks and regards, Lokesh > >> __u32 vpci_irq_base; >> diff --git a/tools/jailhouse-cell-linux b/tools/jailhouse-cell-linux >> index 49babd92..4b6f504b 100755 >> --- a/tools/jailhouse-cell-linux >> +++ b/tools/jailhouse-cell-linux >> @@ -564,8 +564,8 @@ class Irqchip: >> class Config: >> - _HEADER_FORMAT = '6sH32s4xIIIIIIIIIQ8x32x' >> - _HEADER_REVISION = 10 >> + _HEADER_FORMAT = '6sH32s4xIIIIIIII128xIQ8x32x' >> + _HEADER_REVISION = 11 >> def __init__(self, config_file): >> self.data = config_file.read() >> diff --git a/tools/jailhouse-hardware-check >> b/tools/jailhouse-hardware-check >> index 51dea82d..1d08b047 100755 >> --- a/tools/jailhouse-hardware-check >> +++ b/tools/jailhouse-hardware-check >> @@ -138,7 +138,7 @@ class Sysconfig: >> X86_MAX_IOMMU_UNITS = 8 >> X86_IOMMU_SIZE = 20 >> - HEADER_REVISION = 10 >> + HEADER_REVISION = 11 >> HEADER_FORMAT = '6sH' >> def __init__(self, path): >> > > Jan > -- 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.
Re: [RFC PATCH 3/5] core: Add stream id list in the VMconfig
'Lokesh Vutla' via Jailhouse Fri, 22 Mar 2019 10:05:22 -0700
- [RFC PATCH 0/5] arm64: iommu: smmu-v3: Add su... 'Lokesh' via Jailhouse
- [RFC PATCH 3/5] core: Add stream id list... 'Lokesh' via Jailhouse
- Re: [RFC PATCH 3/5] core: Add stream... Jan Kiszka
- Re: [RFC PATCH 3/5] core: Add st... 'Lokesh Vutla' via Jailhouse
- [RFC PATCH 1/5] iommu: x86: Generalize i... 'Lokesh' via Jailhouse
- Re: [RFC PATCH 1/5] iommu: x86: Gene... Jan Kiszka
- Re: [RFC PATCH 1/5] iommu: x86: ... 'Lokesh Vutla' via Jailhouse
- [RFC PATCH 4/5] arm64: iommu: smmu-v3: A... 'Lokesh' via Jailhouse
- [RFC PATCH 2/5] arm-common: Introduce io... 'Lokesh' via Jailhouse
- Re: [RFC PATCH 2/5] arm-common: Intr... Jan Kiszka
- Re: [RFC PATCH 2/5] arm-common: ... 'Lokesh Vutla' via Jailhouse
- [RFC PATCH 5/5] arm64: iommu: smmu-v3: A... 'Lokesh' via Jailhouse
- Re: [RFC PATCH 5/5] arm64: iommu: sm... Jan Kiszka
- RE: [RFC PATCH 5/5] arm64: iommu... Peng Fan
