Lines Matching full:note

54 static void riscv64_note_init(struct riscv64_note *note, DumpState *s,  in riscv64_note_init()  argument
58 memset(note, 0, sizeof(*note)); in riscv64_note_init()
60 note->hdr.n_namesz = cpu_to_dump32(s, namesz); in riscv64_note_init()
61 note->hdr.n_descsz = cpu_to_dump32(s, descsz); in riscv64_note_init()
62 note->hdr.n_type = cpu_to_dump32(s, type); in riscv64_note_init()
64 memcpy(note->name, name, namesz); in riscv64_note_init()
70 struct riscv64_note note; in riscv_cpu_write_elf64_note() local
76 riscv64_note_init(&note, s, name, sizeof(name), in riscv_cpu_write_elf64_note()
77 NT_PRSTATUS, sizeof(note.prstatus)); in riscv_cpu_write_elf64_note()
79 note.prstatus.pr_pid = cpu_to_dump32(s, cpuid); in riscv_cpu_write_elf64_note()
81 note.prstatus.pr_reg.pc = cpu_to_dump64(s, env->pc); in riscv_cpu_write_elf64_note()
84 note.prstatus.pr_reg.regs[i] = cpu_to_dump64(s, env->gpr[i + 1]); in riscv_cpu_write_elf64_note()
87 ret = f(&note, RISCV64_PRSTATUS_NOTE_SIZE, s); in riscv_cpu_write_elf64_note()
123 static void riscv32_note_init(struct riscv32_note *note, DumpState *s, in riscv32_note_init() argument
127 memset(note, 0, sizeof(*note)); in riscv32_note_init()
129 note->hdr.n_namesz = cpu_to_dump32(s, namesz); in riscv32_note_init()
130 note->hdr.n_descsz = cpu_to_dump32(s, descsz); in riscv32_note_init()
131 note->hdr.n_type = cpu_to_dump32(s, type); in riscv32_note_init()
133 memcpy(note->name, name, namesz); in riscv32_note_init()
139 struct riscv32_note note; in riscv_cpu_write_elf32_note() local
145 riscv32_note_init(&note, s, name, sizeof(name), in riscv_cpu_write_elf32_note()
146 NT_PRSTATUS, sizeof(note.prstatus)); in riscv_cpu_write_elf32_note()
148 note.prstatus.pr_pid = cpu_to_dump32(s, cpuid); in riscv_cpu_write_elf32_note()
150 note.prstatus.pr_reg.pc = cpu_to_dump32(s, env->pc); in riscv_cpu_write_elf32_note()
153 note.prstatus.pr_reg.regs[i] = cpu_to_dump32(s, env->gpr[i + 1]); in riscv_cpu_write_elf32_note()
156 ret = f(&note, RISCV32_PRSTATUS_NOTE_SIZE, s); in riscv_cpu_write_elf32_note()