Lines Matching refs:section
108 int pt_sec_file_map(struct pt_section *section, FILE *file) in pt_sec_file_map() argument
115 if (!section) in pt_sec_file_map()
118 mapping = section->mapping; in pt_sec_file_map()
122 offset = section->offset; in pt_sec_file_map()
123 size = section->size; in pt_sec_file_map()
162 section->mapping = mapping; in pt_sec_file_map()
163 section->unmap = pt_sec_file_unmap; in pt_sec_file_map()
164 section->read = pt_sec_file_read; in pt_sec_file_map()
165 section->memsize = pt_sec_file_memsize; in pt_sec_file_map()
174 int pt_sec_file_unmap(struct pt_section *section) in pt_sec_file_unmap() argument
178 if (!section) in pt_sec_file_unmap()
181 mapping = section->mapping; in pt_sec_file_unmap()
183 if (!mapping || !section->unmap || !section->read || !section->memsize) in pt_sec_file_unmap()
186 section->mapping = NULL; in pt_sec_file_unmap()
187 section->unmap = NULL; in pt_sec_file_unmap()
188 section->read = NULL; in pt_sec_file_unmap()
189 section->memsize = NULL; in pt_sec_file_unmap()
197 int pt_sec_file_read(const struct pt_section *section, uint8_t *buffer, in pt_sec_file_read() argument
206 if (!buffer || !section) in pt_sec_file_read()
209 mapping = section->mapping; in pt_sec_file_read()
244 int pt_sec_file_memsize(const struct pt_section *section, uint64_t *size) in pt_sec_file_memsize() argument
246 if (!section || !size) in pt_sec_file_memsize()
249 if (!section->mapping) in pt_sec_file_memsize()