static void powernv_populate_chip(PnvChip *chip, void *fdt)
{
    PnvChipClass *pcc = PNV_CHIP_GET_CLASS(chip);
    char *typename = pnv_core_typename(pcc->cpu_model);
    size_t typesize = object_type_get_instance_size(typename);
    int i;
    for (i = 0; i < chip->nr_cores; i++) {
        PnvCore *pnv_core = PNV_CORE(chip->cores + i * typesize);
        powernv_create_core_node(chip, pnv_core, fdt);
    }
    if (chip->ram_size) {
        powernv_populate_memory_node(fdt, chip->chip_id, chip->ram_start,
                                     chip->ram_size);
    }
    g_free(typename);
}
static void powernv_populate_chip(PnvChip *chip, void *fdt)
{
    PnvChipClass *pcc = PNV_CHIP_GET_CLASS(chip);
    char *typename = pnv_core_typename(pcc->cpu_model);
    size_t typesize = object_type_get_instance_size(typename);
    int i;
    for (i = 0; i < chip->nr_cores; i++) {
        PnvCore *pnv_core = PNV_CORE(chip->cores + i * typesize);
        powernv_create_core_node(chip, pnv_core, fdt);
    }
    if (chip->ram_size) {
        powernv_populate_memory_node(fdt, chip->chip_id, chip->ram_start,
                                     chip->ram_size);
    }
    g_free(typename);
}
static void FUNC_0(PnvChip *VAR_0, void *VAR_1)
{
    PnvChipClass *pcc = PNV_CHIP_GET_CLASS(VAR_0);
    char *VAR_2 = pnv_core_typename(pcc->cpu_model);
    size_t typesize = object_type_get_instance_size(VAR_2);
    int VAR_3;
    for (VAR_3 = 0; VAR_3 < VAR_0->nr_cores; VAR_3++) {
        PnvCore *pnv_core = PNV_CORE(VAR_0->cores + VAR_3 * typesize);
        powernv_create_core_node(VAR_0, pnv_core, VAR_1);
    }
    if (VAR_0->ram_size) {
        powernv_populate_memory_node(VAR_1, VAR_0->chip_id, VAR_0->ram_start,
                                     VAR_0->ram_size);
    }
    g_free(VAR_2);
}
static void FUNC_0(PnvChip *VAR_0, void *VAR_1)
{ PnvChipClass *pcc = PNV_CHIP_GET_CLASS(VAR_0); char *VAR_2 = pnv_core_typename(pcc->cpu_model); size_t typesize = object_type_get_instance_size(VAR_2); int VAR_3; for (VAR_3 = 0; VAR_3 < VAR_0->nr_cores; VAR_3++) { PnvCore *pnv_core = PNV_CORE(VAR_0->cores + VAR_3 * typesize); powernv_create_core_node(VAR_0, pnv_core, VAR_1); } if (VAR_0->ram_size) { powernv_populate_memory_node(VAR_1, VAR_0->chip_id, VAR_0->ram_start,
VAR_0->ram_size); } g_free(VAR_2); }