2 * Dynamic sysbus device tree node generation API
4 * Copyright Linaro Limited, 2014
7 * Alex Graf <agraf@suse.de>
8 * Eric Auger <eric.auger@linaro.org>
10 * This program is free software; you can redistribute it and/or modify it
11 * under the terms and conditions of the GNU General Public License,
12 * version 2 or later, as published by the Free Software Foundation.
14 * This program is distributed in the hope it will be useful, but WITHOUT
15 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
16 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
19 * You should have received a copy of the GNU General Public License along with
20 * this program. If not, see <http://www.gnu.org/licenses/>.
24 #ifndef HW_ARM_SYSBUS_FDT_H
25 #define HW_ARM_SYSBUS_FDT_H
27 #include "hw/arm/arm.h"
28 #include "qemu-common.h"
29 #include "hw/sysbus.h"
32 * struct that contains dimensioning parameters of the platform bus
35 hwaddr platform_bus_base; /* start address of the bus */
36 hwaddr platform_bus_size; /* size of the bus */
37 int platform_bus_first_irq; /* first hwirq assigned to the bus */
38 int platform_bus_num_irqs; /* number of hwirq assigned to the bus */
39 } ARMPlatformBusSystemParams;
42 * struct that contains all relevant info to build the fdt nodes of
43 * platform bus and attached dynamic sysbus devices
44 * in the future might be augmented with additional info
45 * such as PHY, CLK handles ...
48 const ARMPlatformBusSystemParams *system_params;
49 struct arm_boot_info *binfo;
50 const char *intc; /* parent interrupt controller name */
51 } ARMPlatformBusFDTParams;
54 * arm_register_platform_bus_fdt_creator - register a machine init done
55 * notifier that creates the device tree nodes of the platform bus and
56 * associated dynamic sysbus devices
58 void arm_register_platform_bus_fdt_creator(ARMPlatformBusFDTParams *fdt_params);