Files
Ryan Grimm 70bf92ae7e AWAN simulator support for P10
This patch enables Skiboot to initialize and Linux to boot to user space
on the AWAN core and chip models.

We need the distinction between core and chip models because the core
models do not have an XSCOM unit, CHIPTOD, nor RNG.  The chip
model does have them and they work.

So, add a device_type property to the awan node to distinguish core from
chip.  Sample DTS are provided for the core and chip models in
external/awan.

Just like Mambo, we need to return in slw_init before trying to
initialize SLW.  Without an XSCOM unit in the device tree for the core
model, the SLW code path eventually fails an assert due to lack of
chips.

This commit defines a QUIRK_AWAN where previously Mambo used
QUIRK_MAMBO_CALLOUTS so now Mambo and AWAN core both work.

Also, fix up chip quirks so the core model and chip model boot and
initialize the appropriate units.

Disable sreset and power management in a couple spots because the chip
model does not support stop with EC=1 and enter_p9_pm_state spins in the
branch-to-self after stop.

Provide an external/awan/README.md with a high-level view of booting in
the environment.

Signed-off-by: Ryan Grimm <grimm@linux.ibm.com>
Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
2021-10-19 12:14:20 +05:30
..
2021-10-19 12:14:20 +05:30

Running skiboot and Linux in AWAN

AWAN is a hardware accelerator composed of programmable gate arrays that can emulate a POWER logic core. The AWAN environment can be used to run hardware procedures or test binaries on the logic, before hardware is available or when hardware is scarce.

The AWAN environment is slow compared to Mambo and QEMU. Each timebase tick is equivalent to 8 simclocks, and simclock is slow. For example, on the core model we get through Skiboot in about 6 million simclock cycles and that takes approximately 1 minute wall-clock time to complete.

Getting started

To run in AWAN, you need a an initial checkpoint, a loader, and a method to read memory.

The high-level sequence for running in AWAN is:

  1. Load an initial checkpoint provided by the person that built the model

  2. Load a stripped vmlinux at 0

  3. Load an initramfs at 0x28200000

  4. Load skiboot.lid at 0x30000000

  5. Load a small piece of start code at 0x100 that tells skiboot where to find the device tree blob

  6. Load a compiled device tree blob at 0x1f00000

  7. Run "simclock 5000000" and check the console buffer for the Skiboot log by reading memory at 784MB.