lp:~linaro-toolchain-dev/linaro-toolchain-misc/kvm-boot-wrapper

Created by Michael Hope and last modified
Get this branch:
bzr branch lp:~linaro-toolchain-dev/linaro-toolchain-misc/kvm-boot-wrapper

Branch merges

Related bugs

Related blueprints

Branch information

Owner:
Linaro Toolchain Developers
Project:
Linaro Toolchain Miscellanies
Status:
Development

Import details

Import Status: Failed

This branch is an import of the HEAD branch of the Git repository at git://git.linaro.org/arm/models/boot-wrapper.git.

The import has been suspended because it failed 5 or more times in succession.

Last successful import was .

Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 4 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-0 and finished taking 4 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-5 and finished taking 4 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 5 seconds — see the log

Recent revisions

48. By Tixy (Jon Medhurst)

bootwrapper: CPU hotplug aware boot protocol

To enable CPU hotplug the need to provide some boot code at the reset
vector and which survives after the kernel has booted without being
overwritten. We achieve this by the getting the linker script to place
the code in boot.S at address zero. This now means we can delete the
code that relocates the secondary CPU pen code to "a location less
likely to be overridden".

We then modify the boot protocol slightly to allow hot-plugging of any
CPU, including CPU #0, when the system is already booted. This is done
by checking if SYS_FLAGS is already set before the normal check for CPU0
and the boot-or-wait decision made.

This patch is based on work by Nicolas Pitre.

Signed-off-by: Nicolas Pitre <email address hidden>
Signed-off-by: Jon Medhurst <email address hidden>

47. By Tixy (Jon Medhurst)

bootwrapper: Enable non-secure access to the CCI

We boot the kernel in non-secure mode and by default access to
the CCI device is not enabled for non-secure access, so we must
enable this if we want Linux to manage CPU hotplug on big.LITTLE
models.

Signed-off-by: Jon Medhurst <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

46. By Will Deacon

bootwrapper: Fix check for architected timer

We need to set the flags when checking the feature register.

Signed-off-by: Will Deacon <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

45. By Tixy (Jon Medhurst)

bootwrapper: Initialise CCI device if found in the fdt

The A15xA7 models simulate a Cache Coherent Interconnect (CCI) and this
needs to be initialised correctly for Linux to boot.

To perform this initiation we add the new function configure_from_fdt()
which will look in the fdt for devices to initialise. In this first case
we look for the CCI node and if found then setup this device.

Signed-off-by: Jon Medhurst <email address hidden>
Acked-by: Dave Martin <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

44. By Tixy (Jon Medhurst)

bootwrapper: Factor out parsing of fdt #address-cells and #size-cells

A subsequent patch will also need to obtain address-cells and
size-cells, so lets factor out this code into a handy function.

Signed-off-by: Jon Medhurst <email address hidden>
[PMM: fixed some minor style nits pointed out by Dave M]
Signed-off-by: Peter Maydell <email address hidden>

43. By Tixy (Jon Medhurst)

bootwrapper: Allow for multiple clusters in boot CPU detection

Check all the CPU affinity fields of MPIDR, so we select only
the first CPU of the first cluster as the one to boot on.

Signed-off-by: Jon Medhurst <email address hidden>
Acked-by: Dave Martin <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

42. By Peter Maydell

bootwrapper: Drop now-obsolete SMC interface support

Now that the kernel supports simply being started in Hyp mode,
we don't need to maintain the obsolete SMC interface for setting
HVBAR and switching to NS mode. Drop monitor.S in favour of a
much simpler special-purpose bit of code in boot.S which passes
briefly through Monitor mode to set up HVBAR and drop into
NS state. We also disable SMC in NS mode, so that inadvertent
use of it will UNDEF rather than leaping back into the boot
wrapper later on.

Signed-off-by: Peter Maydell <email address hidden>

41. By Dave Martin

bootwrapper: Delay switch to Hyp mode until kernel entry

The bootwrapper is really doubling as firmware, so it doesn't make
sense for it to drop out of the Secure World before getting a
chance to parse its parameters and configuration.

Instead, it is better to delay switching to the Normal World for
as long as possible so that we have a chance to do any required
firmware-level configuration in the Secure World first.

Signed-off-by: Dave Martin <email address hidden>
[PMM: moved enter_hyp for secondary CPUs to just before the WFE
 loop to avoid making the loop code that needs relocation bigger]
Signed-off-by: Peter Maydell <email address hidden>

40. By Dave Martin

bootwrapper: Refactor entry into Hyp mode to be more reusable

  * Split Hyp mode entry out into a separate macro.
  * hvc now jumps back to the caller in Hyp mode instead of
    branching to a fixed label.

Signed-off-by: Dave Martin <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

39. By Dave Martin

bootwrapper: Fix misaligned Hyp mode vector table

Currently, it looks like we rely on luck in order to fall through
to the correct vector when a Hyp Trap exception occurs.

This patch aligns the Hyp mode vector table explicitly to a 32-byte
boundary, as required by the architecture.

Signed-off-by: Dave Martin <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
This branch contains Public information 
Everyone can see this information.