[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC PATCH 09/15] spapr: populate PHB DRC entries for root
From: |
Michael Roth |
Subject: |
[Qemu-devel] [RFC PATCH 09/15] spapr: populate PHB DRC entries for root DT node |
Date: |
Wed, 29 Apr 2015 14:20:18 -0500 |
From: Nathan Fontenot <address@hidden>
This add entries to the root OF node to advertise our PHBs as being
DR-capable in accordance with PAPR specification.
Signed-off-by: Nathan Fontenot <address@hidden>
Signed-off-by: Michael Roth <address@hidden>
---
hw/ppc/spapr.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index c539932..a7af332 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -57,6 +57,7 @@
#include "qemu/error-report.h"
#include "trace.h"
#include "hw/nmi.h"
+#include "hw/ppc/spapr_drc.h"
#include "hw/compat.h"
@@ -745,6 +746,7 @@ static void spapr_finalize_fdt(sPAPREnvironment *spapr,
size_t cb = 0;
char *bootlist;
void *fdt;
+ int fdt_offset;
sPAPRPHBState *phb;
fdt = g_malloc(FDT_MAX_SIZE);
@@ -804,6 +806,13 @@ static void spapr_finalize_fdt(sPAPREnvironment *spapr,
spapr_populate_chosen_stdout(fdt, spapr->vio_bus);
}
+ fdt_offset = fdt_path_offset(fdt, "/");
+ ret = spapr_drc_populate_dt(fdt, fdt_offset, NULL,
+ SPAPR_DR_CONNECTOR_TYPE_PHB);
+ if (ret < 0) {
+ fprintf(stderr, "Couldn't set up RTAS device tree properties\n");
+ }
+
_FDT((fdt_pack(fdt)));
if (fdt_totalsize(fdt) > FDT_MAX_SIZE) {
--
1.9.1
- [Qemu-devel] [RFC PATCH 00/15] spapr: add support for PHB hotplug, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 10/15] spapr_events: add support for phb hotplug events, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 09/15] spapr: populate PHB DRC entries for root DT node,
Michael Roth <=
- [Qemu-devel] [RFC PATCH 11/15] qdev: add qbus_set_hotplug_handler_generic(), Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 13/15] spapr_pci: provide node start offset via spapr_populate_pci_dt(), Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 12/15] spapr: stub implementation of machine-level HotplugHandler interface, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 14/15] spapr_pci: add ibm, my-drc-index property for PHB hotplug, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 01/15] pci: allow cleanup/unregistration of PCI buses, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 02/15] qdev: store DeviceState's canonical path to use when unparenting, Michael Roth, 2015/04/29
- [Qemu-devel] [RFC PATCH 04/15] spapr_iommu: pass object ownership to parent/owner, Michael Roth, 2015/04/29