[CORE] vmm_devdrv: Rename "default" bus to "platform" bus

Our "default" bus is nothing but "platform" bus in linux
terminology hence, this patch does the renaming accordingly.

Signed-off-by: Anup Patel <anup@brainfault.org>
[COMMANDS] cmd_host: Add sub-commands to list buses, classes, and devices

This patch adds following sub-commands to host commands:
bus_list          - List all buses
bus_device_list   - List all devices on given bus
class_list        - List all classes
class_device_list - List all devices on given class

Signed-off-by: Anup Patel <anup@brainfault.org>
[DRIVERS] Move dma_addr_t to core/vmm_types.h

The IOMMU framework uses dma_addr_t type and this framework
will be shared by drivers and emulations hence we move
dma_addr_t to core/vmm_types.h.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_devdrv: Add public fields for IOMMU framework

The IOMMU framework requires "iommu_ops" field in struct vmm_bus
and "iommu_group" in struct vmm_device hence this patch.

This is more of preparatory patch for IOMMU framework.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] First-cut implementation of IOMMU framework

This patch adds Linux-like IOMMU framework for Xvisor.

Currently, the IOMMU framework is little incomplete due
to pending changes in device driver framework.

The IOMMU framework will be used by device drivers via
linux-compatible linux/iommu.h header. It will be also
used by emulator to setup IOMMU context for pass-through
devices.

Signed-off-by: Anup Patel <anup@brainfault.org>
[ARM] Enable IOMMU framework for arm32ve and arm64

The SystemMMU hardware is generally available on ARM
boards with hardware virtualization support hence
enabled IOMMU framework for arm32ve and arm64 ports.

Signed-off-by: Anup Patel <anup@brainfault.org>
[COMMANDS] Advertise host cpu stats command

We forgot to advertise "host cpu stats" command in host
command usage hence this patch.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_devdrv: Add support bus event notifications

This patch adds linux-like bus event notifications.

The bus events which can be listened include:
1. Add device
2. Delete device
3. Bind driver
4. Bound driver
5. Unbind driver
6. Unbound driver

Signed-off-by: Anup Patel <anup@brainfault.org>
[DRIVERS] Add linux-compatile bus notification API in linux/device.h

This patch updates linux/device.h header to have linux-compatible
bus notification API in-terms of vmm_devdrv APIs.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_devdrv: Improve APIs to find and iterate over bus devices

This patch makes APIs to find bus device linux-like and adds
new linux-like API to iterate over bus devices.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_iommu: IOMMU framework must listen to bus events

The IOMMU framework must monitor/watch bus events and update
IOMMU groups when device is added/deleted.

This patch also establish connection between IOMMU group events
and device driver BUS events.

Signed-off-by: Anup Patel <anup@brainfault.org>
[DRIVERS] Add linux-compatiblity header for porting IOMMU drivers

This patch adds linux/iommu.h header which expresses Linux IOMMU
APIs in-terms of vmm_iommu.h APIs so that porting IOMMU drivers
is easier.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_host_irq: Add APIs for access to state of routed interrupts

For pass-through device access, we need explicit access to state
of routed interrupts. This is required for devices that need to
ensure that device interrupt is in-active when guest is reset.

This patch adds needed APIs and infrastructure in vmm_host_irq
for access to state of routed interrupts.

Signed-off-by: Anup Patel <anup@brainfault.org>
[CORE] vmm_host_irq: Rename VMM_ROUTED_IRQ_xxx to VMM_ROUTED_IRQ_STATE_xxx

This patch renames VMM_ROUTED_IRQ_xxx to VMM_ROUTED_IRQ_STATE_xxx
for better readablity.

Signed-off-by: Anup Patel <anup@brainfault.org>
[DRIVERS] irq-gic: Implement routines to set/get routed irq state

This patch implements set/get routines for routed irqs in GIC driver.

This will help us control state of routed irqs for pass-through devices.

Signed-off-by: Anup Patel <anup@brainfault.org>
[x86] Make the package installation automated

Currently, while installing the required packages,
the script asks for the password. Make it automated.

Signed-off-by: Himanshu Chauhan <hschauhan@nulltrace.org>