static void nvdimm_build_nfit(AcpiNVDIMMState *state, GArray *table_offsets,

                              GArray *table_data, BIOSLinker *linker)

{

    NvdimmFitBuffer *fit_buf = &state->fit_buf;

    unsigned int header;





    /* NVDIMM device is not plugged? */

    if (!fit_buf->fit->len) {

        return;

    }



    acpi_add_table(table_offsets, table_data);



    /* NFIT header. */

    header = table_data->len;

    acpi_data_push(table_data, sizeof(NvdimmNfitHeader));

    /* NVDIMM device structures. */

    g_array_append_vals(table_data, fit_buf->fit->data, fit_buf->fit->len);



    build_header(linker, table_data,

                 (void *)(table_data->data + header), "NFIT",

                 sizeof(NvdimmNfitHeader) + fit_buf->fit->len, 1, NULL, NULL);

}

static void nvdimm_build_nfit(AcpiNVDIMMState *state, GArray *table_offsets,

                              GArray *table_data, BIOSLinker *linker)

{

    NvdimmFitBuffer *fit_buf = &state->fit_buf;

    unsigned int header;





    

    if (!fit_buf->fit->len) {

        return;

    }



    acpi_add_table(table_offsets, table_data);



    

    header = table_data->len;

    acpi_data_push(table_data, sizeof(NvdimmNfitHeader));

    

    g_array_append_vals(table_data, fit_buf->fit->data, fit_buf->fit->len);



    build_header(linker, table_data,

                 (void *)(table_data->data + header), "NFIT",

                 sizeof(NvdimmNfitHeader) + fit_buf->fit->len, 1, NULL, NULL);

}

static void FUNC_0(AcpiNVDIMMState *VAR_0, GArray *VAR_1,

                              GArray *VAR_2, BIOSLinker *VAR_3)

{

    NvdimmFitBuffer *fit_buf = &VAR_0->fit_buf;

    unsigned int VAR_4;





    

    if (!fit_buf->fit->len) {

        return;

    }



    acpi_add_table(VAR_1, VAR_2);



    

    VAR_4 = VAR_2->len;

    acpi_data_push(VAR_2, sizeof(NvdimmNfitHeader));

    

    g_array_append_vals(VAR_2, fit_buf->fit->data, fit_buf->fit->len);



    build_header(VAR_3, VAR_2,

                 (void *)(VAR_2->data + VAR_4), "NFIT",

                 sizeof(NvdimmNfitHeader) + fit_buf->fit->len, 1, NULL, NULL);

}

static void FUNC_0(AcpiNVDIMMState *VAR_0, GArray *VAR_1,
GArray *VAR_2, BIOSLinker *VAR_3)
{ NvdimmFitBuffer *fit_buf = &VAR_0->fit_buf; unsigned int VAR_4; if (!fit_buf->fit->len) { return; } acpi_add_table(VAR_1, VAR_2); VAR_4 = VAR_2->len; acpi_data_push(VAR_2, sizeof(NvdimmNfitHeader)); g_array_append_vals(VAR_2, fit_buf->fit->data, fit_buf->fit->len); build_header(VAR_3, VAR_2,
(void *)(VAR_2->data + VAR_4), "NFIT",
sizeof(NvdimmNfitHeader) + fit_buf->fit->len, 1, NULL, NULL); }