Revert "core: make the jailhouse-header arch-independent"

This reverts commit 17f8453876f8b143022278e6438c8ebb157d1821.

It turned out to break 32-bit architectures: At least core_size and
entry must be of the size the hypervisor uses for pointer, otherwise
link-time initialization of those fields fail.

We will need a more sophisticated solution if including the header in
i386 mode is really necessary.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
inmates: pci: allow pci_find_device to discover multiple devices

Systems can have more than one PCI device with the same vendor/device
id pair. Change the discovery helper to allow searching for more than
just the first bdf.

Signed-off-by: Henning Schild <henning.schild@siemens.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
inmates: pci: add msix support to inmate lib

Add basic MSI-X support to inmate PCI library.

Signed-off-by: Henning Schild <henning.schild@siemens.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
tooling: Fix parallel kbuild

The define decouples the calling make from the recursively called one.
Fix it by prefixing the latter with "+".

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
tooling: Do not print directory names during build

Just to reduce verbosity.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Documentation: Add Doxygen infrastructure

We diverge from Linux kernel style and use Doxygen as our code
documentation generator, see [1] for the reasoning. This adds the
required build infrastructure. Run "make docs" to trigger it (not
automatically done via other targets).

[1] http://thread.gmane.org/gmane.linux.jailhouse/1281

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Prefix arch-specific PCI functions properly

Add the "arch_"-prefix to pci_suppress_msi, pci_update_msi and
pci_update_msix_vector. This clearly signals that those functions have
to be implemented by the architecture support.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Document PCI subsystem interfaces

Convert existing kernel-doc comments to doxygen style and add missing
functions and structure descriptions for public interfaces. Architecture
specific functions are documented in the headers to avoid duplications
at the implementation site.

No functional changes.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Rename page_map_* -> paging_*

The module is already called "paging", so lets call its functions like
this as well. No functional changes.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Rename *MAX_PAGE_DIR_LEVELS to *MAX_PAGE_TABLE_LEVELS

To be consistent with terms used throughout the hypervisor.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Rename arch-specific cache and TLB flush functions

Consistently add "arch_" and the subsystem prefix und use clearer names
for cache and TLB flushing services.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Document page management subsystem interfaces

This adds doxygen-style documentation for public parts of the page
management subsystem. Again we place documentation of architecture-
provided entities in the generic header.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Factor out generic jailhouse/types.h

Some types in the architecture-specific header are in fact generic. Move
them into a separate header and include this one directly from now on.
Document cpu_set at this chance according to doxygen style.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Remove cpu_data parameter from hypercall functions

We can obtain a reference on demand now.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Remove unused cpu_data from arch_cell_create/destroy

Became obsolete with 77b0e690ec.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Remove cpu_data from arch_config_commit

We can obtain a reference inside arch_config_commit. This also allows to
drop cpu_data from late_init.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Rename [arch_]panic_halt to [arch_]panic_park

This makes naming consistent with other parts of the code.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Document control subsystem

This adds doxygen-style documentation for public parts of the control
subsystem.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
x86: Rename vm_exit to vmx_vmexit

Clarify that this is in fact a VMX-specific entry point. Consequently,
move the misplaced prototype to the VMX header.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core: Document setup subsystem

This adds doxygen-style documentation for public parts of the setup
subsystem, including the hypervisor header.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>