static int s390x_write_all_elf64_notes(const char *note_name,

                                       WriteCoreDumpFunction f,

                                       S390CPU *cpu, int id,

                                       void *opaque)

{

    Note note;

    const NoteFuncDesc *nf;

    int note_size;

    int ret = -1;



    for (nf = note_func; nf->note_contents_func; nf++) {

        memset(&note, 0, sizeof(note));

        note.hdr.n_namesz = cpu_to_be32(sizeof(note.name));

        note.hdr.n_descsz = cpu_to_be32(nf->contents_size);

        strncpy(note.name, note_name, sizeof(note.name));

        (*nf->note_contents_func)(&note, cpu);



        note_size = sizeof(note) - sizeof(note.contents) + nf->contents_size;

        ret = f(&note, note_size, opaque);



        if (ret < 0) {

            return -1;

        }



    }



    return 0;

}

static int s390x_write_all_elf64_notes(const char *note_name,

                                       WriteCoreDumpFunction f,

                                       S390CPU *cpu, int id,

                                       void *opaque)

{

    Note note;

    const NoteFuncDesc *nf;

    int note_size;

    int ret = -1;



    for (nf = note_func; nf->note_contents_func; nf++) {

        memset(&note, 0, sizeof(note));

        note.hdr.n_namesz = cpu_to_be32(sizeof(note.name));

        note.hdr.n_descsz = cpu_to_be32(nf->contents_size);

        strncpy(note.name, note_name, sizeof(note.name));

        (*nf->note_contents_func)(&note, cpu);



        note_size = sizeof(note) - sizeof(note.contents) + nf->contents_size;

        ret = f(&note, note_size, opaque);



        if (ret < 0) {

            return -1;

        }



    }



    return 0;

}

static int s390x_write_all_elf64_notes(const char *note_name,                                        void *opaque)     for (nf = note_func; nf->note_contents_func; nf++) {         note.hdr.n_namesz = cpu_to_be32(sizeof(note.name));     for (nf = note_func; nf->note_contents_func; nf++) {
static int FUNC_0(const char *VAR_0,

                                       WriteCoreDumpFunction VAR_1,

                                       S390CPU *VAR_2, int VAR_3,

                                       void *VAR_4)

{

    Note note;

    const NoteFuncDesc *VAR_5;

    int VAR_6;

    int VAR_7 = -1;



    for (VAR_5 = note_func; VAR_5->note_contents_func; VAR_5++) {

        memset(&note, 0, sizeof(note));

        note.hdr.n_namesz = cpu_to_be32(sizeof(note.name));

        note.hdr.n_descsz = cpu_to_be32(VAR_5->contents_size);

        strncpy(note.name, VAR_0, sizeof(note.name));

        (*VAR_5->note_contents_func)(&note, VAR_2);



        VAR_6 = sizeof(note) - sizeof(note.contents) + VAR_5->contents_size;

        VAR_7 = VAR_1(&note, VAR_6, VAR_4);



        if (VAR_7 < 0) {

            return -1;

        }



    }



    return 0;

}

static int FUNC_0(const char *VAR_0,
WriteCoreDumpFunction VAR_1,
S390CPU *VAR_2, int VAR_3,
void *VAR_4)
{ Note note; const NoteFuncDesc *VAR_5; int VAR_6; int VAR_7 = -1; for (VAR_5 = note_func; VAR_5->note_contents_func; VAR_5++) { memset(&note, 0, sizeof(note)); note.hdr.n_namesz = cpu_to_be32(sizeof(note.name)); note.hdr.n_descsz = cpu_to_be32(VAR_5->contents_size); strncpy(note.name, VAR_0, sizeof(note.name)); (*VAR_5->note_contents_func)(&note, VAR_2); VAR_6 = sizeof(note) - sizeof(note.contents) + VAR_5->contents_size; VAR_7 = VAR_1(&note, VAR_6, VAR_4); if (VAR_7 < 0) { return -1; } } return 0; }