summaryrefslogtreecommitdiffstats
path: root/platforms/qemu
Commit message (Collapse)AuthorAgeFilesLines
* qemu: bt device isn't always hanging off /Stewart Smith2019-01-161-3/+2
| | | | | | | | | | | | | Just use the normal for_each_compatible instead. Otherwise in the qemu model as executed by op-test, we wouldn't go down the astbmc_init() path, thus not having flash. Cc: stable # v6.2+ Fixes: 2f0b6af6e01c5f7b3c762647d06c4f792e2cb3b7 Signed-off-by: Stewart Smith <stewart@linux.ibm.com> Reviewed-by: Cédric Le Goater <clg@kaod.org> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* plat/qemu: fix platform initialization when the BT device is not presentCédric Le Goater2018-12-131-1/+20
| | | | | | | | | | | | | | A QEMU PowerNV machine does not necessarily have a BT device. It needs to be defined on the command line with : -device ipmi-bmc-sim,id=bmc0 -device isa-ipmi-bt,bmc=bmc0,irq=10 When the QEMU platform is initialized by skiboot, we need to check that such a device is present and if not, skip the AST initialization. Fixes: 8340a9642bba ("plat/qemu: use the common OpenPOWER routines to initialize") Signed-off-by: Cédric Le Goater <clg@kaod.org> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* plat/qemu: use the common OpenPOWER routines to initializeCédric Le Goater2018-12-101-230/+6
| | | | | | | | | | | Back in 2016, we did not have a large support of the PowerNV devices under QEMU and we were using our own custom ones. This has changed and we can now use all the common init routines of the OpenPOWER platforms. Signed-off-by: Cédric Le Goater <clg@kaod.org> Reviewed-by: Joel Stanley <joel@jms.id.au> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* Qemu: don't print PR_WARNING on qemu defining rtc/uartStewart Smith2018-09-131-2/+2
| | | | | | | This helps us boot more warning/error free on qemu Signed-off-by: Stewart Smith <stewart@linux.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* ast-io: Rework setup/tear-down of communication with the BMCAndrew Jeffery2018-07-171-2/+2
| | | | | | | | | It's possible for the platform to configure the BMC with SuperIO access disabled. Rework the interfaces to report failures if SuperIO is not enabled, and clean up once we're finished. Signed-off-by: Andrew Jeffery <andrew@aj.id.au> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* plat/qemu: add PNOR supportCédric Le Goater2018-06-181-0/+10
| | | | | | | | | | | | | | | | | | To access the PNOR, OPAL/skiboot drives the BMC SPI controller using the iLPC2AHB device of the BMC SuperIO controller and accesses the flash contents using the LPC FW address space on which the PNOR is remapped. The QEMU PowerNV machine now integrates such models (SuperIO controller, iLPC2AHB device) and also a pseudo Aspeed SoC AHB memory space populated with the SPI controller registers (same model as for ARM). The AHB window giving access to the contents of the BMC SPI controller flash modules is mapped on the LPC FW address space. The change should be compatible for machine without PNOR support. Signed-off-by: Cédric Le Goater <clg@kaod.org> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* build: use thin archives rather than incremental linkingNicholas Piggin2018-02-281-1/+1
| | | | | | | | | | | | | | | | | | | | This changes to build system to use thin archives rather than incremental linking for built-in.o, similar to recent change to Linux. built-in.o is renamed to built-in.a, and is created as a thin archive with no index, for speed and size. All built-in.a are aggregated into a skiboot.tmp.a which is a thin archive built with an index, making it suitable or linking. This is input into the final link. The advantags of build size and linker code placement flexibility are not as great with skiboot as a bigger project like Linux, but it's a conceptually better way to build, and is more compatible with link time optimisation in toolchains which might be interesting for skiboot particularly for size reductions. Size of build tree before this patch is 34.4MB, afterwards 23.1MB. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* console: use opal_con_ops APIOliver O'Halloran2017-01-041-2/+1
| | | | | | | | | | | | | | | | | | Adds a new structure that contains the implementations of the various OPAL console handlers. This is intended to replace the existing ad-hoc mechanism where the OPAL call handlers are overwritten in the OPAL console driver's init function. Currently this just moves the site where the OPAL call handlers are overwritten to inside of console.c, but it is intended to give us a mechanism for implementing features such as pointer validation for the OPAL console calls without having to manually update each driver. This also helps to clarify differences between the internal (skiboot) console and the external (OPAL) console. Signed-off-by: Oliver O'Halloran <oohall@gmail.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* plat/qemu: add BT and IPMI supportCédric Le Goater2016-08-261-0/+115
| | | | | | | | | | | | | | | | This brings the qemu platform to the level of an Open Power platform. It adds the BT device used to communicate with the BMC using IPMI messaging, power_downs and reboots the way OpenPower systems operate. The device tree is also checked for UART and RTC device nodes and updated if qemu has not defined them already. The initialization of the BT and IPMI interfaces depends on the availability of the BT device which needs to be explicitly defined by qemu. These tests enable skiboot to maintain compatibility with previous versions of qemu which did not update the device tree with enabled devices. Signed-off-by: Cédric Le Goater <clg@kaod.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* uart: Cleanup initialization and remove simulator hackBenjamin Herrenschmidt2016-07-061-6/+2
| | | | | | | | | | Add more generic support for MMIO based UARTs, simplify code, use common initialization, and clean up the device-tree representation as well. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Acked-by: Michael Neuling <mikey@neuling.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* plat/qemu: Add LPC based RTC supportBenjamin Herrenschmidt2015-07-031-0/+5
| | | | | | | | This adds a driver for standard CMOS RTC chips and use it from the QEMU platform. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* plat/qemu: Add simple qemu platformBenjamin Herrenschmidt2015-07-032-0/+149
This adds support for running under qemu "powernv" platform, which is currently available via the qemu repository at: https://github.com/ozbenh/qemu branch "powernv" qemu can't yet create DT entries for ISA devices so we hard wire the UART and RTC devices in the device-tree like we do with other platforms. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
OpenPOWER on IntegriCloud