summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/85xx/p5020_ds.c
diff options
context:
space:
mode:
authorTimur Tabi <timur@freescale.com>2011-05-19 08:54:30 -0500
committerKumar Gala <galak@kernel.crashing.org>2011-06-27 08:30:54 -0500
commit3907ab26866006087c4d1e48e9d1306e281ec955 (patch)
tree83cd8155d4b387bd340e6fa4235bfbd4b4e04454 /arch/powerpc/platforms/85xx/p5020_ds.c
parentd173ea6b4078f37320b49d06f9656ba76ee1ba6c (diff)
downloadtalos-obmc-linux-3907ab26866006087c4d1e48e9d1306e281ec955.tar.gz
talos-obmc-linux-3907ab26866006087c4d1e48e9d1306e281ec955.zip
powerpc/85xx: add board support for the Freescale hypervisor
Add support for the ePAPR-compliant Freescale hypervisor (aka "Topaz") on the Freescale P3041DS, P4080DS, and P5020DS reference boards. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms/85xx/p5020_ds.c')
-rw-r--r--arch/powerpc/platforms/85xx/p5020_ds.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/85xx/p5020_ds.c b/arch/powerpc/platforms/85xx/p5020_ds.c
index 7467b712ee00..94348c9b5dc6 100644
--- a/arch/powerpc/platforms/85xx/p5020_ds.c
+++ b/arch/powerpc/platforms/85xx/p5020_ds.c
@@ -30,6 +30,7 @@
#include <linux/of_platform.h>
#include <sysdev/fsl_soc.h>
#include <sysdev/fsl_pci.h>
+#include <asm/ehv_pic.h>
#include "corenet_ds.h"
@@ -40,7 +41,20 @@ static int __init p5020_ds_probe(void)
{
unsigned long root = of_get_flat_dt_root();
- return of_flat_dt_is_compatible(root, "fsl,P5020DS");
+ if (of_flat_dt_is_compatible(root, "fsl,P5020DS"))
+ return 1;
+
+ /* Check if we're running under the Freescale hypervisor */
+ if (of_flat_dt_is_compatible(root, "fsl,P5020DS-hv")) {
+ ppc_md.init_IRQ = ehv_pic_init;
+ ppc_md.get_irq = ehv_pic_get_irq;
+ ppc_md.restart = fsl_hv_restart;
+ ppc_md.power_off = fsl_hv_halt;
+ ppc_md.halt = fsl_hv_halt;
+ return 1;
+ }
+
+ return 0;
}
define_machine(p5020_ds) {
OpenPOWER on IntegriCloud