tools: Add installation rules

This installs the jailhouse tool, its helper scripts and the template
files to standard, configurable directories. We patch the config
generator on installation so that the target version is aware of the
chosen data directory.

Note that installing the bash completion is left up to the user. There
is apparently no distro-independent way to achieve this.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
tools: Remove dependency of jailhouse tool on cell-config.h

Two things caused jailhouse.h and, thus, tools/jailhouse.c to depend on
the cell configuration header: the definition of the JAILHOUSE_ENABLE
IOCTL and the maximum cell name length in config files.

The first dependency is not only unneeded (the command line tool passed
the an uninterpreted blob via JAILHOUSE_ENABLE), it also made the driver
ABI change each time we updated the config format. So replace the
reference to struct jailhouse_system in JAILHOUSE_ENABLE with a symbolic
"void *".

The second dependency is also unneeded: While the name length used in
configs and, thus, also inside the driver to reference cells should be
identical to the lengths we use in struct jailhouse_cell_id, there is no
hard dependency. In the worst case (different lengths), we would fail to
address cells by name. However, these lengths are unlikely to change. So
simply define our own name length for that struct and test for
deviations during the driver build.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
core/driver: Add version information

Create a version string in the format

    vX.Y (<commits-since-vX.Y>-<git-hash>[-dirty])

and embed it into the hypervisor core as well as the driver module.
Helps to identify what is actually executed.

The management tool is more decoupled from those two and will get a
simpler version tag.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
tools: Add Version information to command line tool

Dump the static version tag from the management tool when invoked with
"--version". We don't need precise git-based tracking here as interfaces
are fairly decoupled now.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
scripts: Add release-maker script

To document the steps in a productive way. The final git push is not
included, intentionally.

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>
x86: Remove unused cpu_data argument from vmx_entry_failure

panic_stop no longer requires it, so it became useless.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
x86: Remove cpu_data parameter from interrupt handling path

We can obtain a reference on demand now.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
x86: Remove cpu_data parameter from vmx_set_cell_config

As a consequence, this allows to remove it also from vmx_cpu_reset and
vmx_cpu_park. All functions always work against the invoking CPU.

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>