| /freebsd-head/contrib/llvm-project/compiler-rt/lib/sanitizer_common/ |
| HD | sanitizer_allocator_secondary.h | 87 uptr map_size = RoundUpMapSize(size); in Allocate() local 89 map_size += alignment; in Allocate() 91 if (map_size < size) { in Allocate() 94 SanitizerToolName, map_size, alignment); in Allocate() 98 MmapOrDieOnFatalError(map_size, SecondaryAllocatorName)); in Allocate() 102 uptr map_end = map_beg + map_size; in Allocate() 106 MapUnmapCallback().OnMapSecondary(map_beg, map_size, res, size); in Allocate() 114 h->map_size = map_size; in Allocate() 115 uptr size_log = MostSignificantSetBitIndex(map_size); in Allocate() 125 stats.currently_allocated += map_size; in Allocate() [all …]
|
| HD | sanitizer_fuchsia.cpp | 250 static uptr DoMmapFixedOrDie(zx_handle_t vmar, uptr fixed_addr, uptr map_size, in DoMmapFixedOrDie() argument 253 map_size = RoundUpTo(map_size, GetPageSize()); in DoMmapFixedOrDie() 255 zx_status_t status = _zx_vmo_create(map_size, 0, &vmo); in DoMmapFixedOrDie() 258 ReportMmapFailureAndDie(map_size, name, "zx_vmo_create", status); in DoMmapFixedOrDie() 262 DCHECK_GE(base + size_, map_size + offset); in DoMmapFixedOrDie() 267 offset, vmo, 0, map_size, &addr); in DoMmapFixedOrDie() 271 ReportMmapFailureAndDie(map_size, name, "zx_vmar_map", status); in DoMmapFixedOrDie() 275 IncreaseTotalMmap(map_size); in DoMmapFixedOrDie() 279 uptr ReservedAddressRange::Map(uptr fixed_addr, uptr map_size, in Map() argument 281 return DoMmapFixedOrDie(os_handle_, fixed_addr, map_size, base_, in Map() [all …]
|
| HD | sanitizer_posix.cpp | 87 uptr map_size = size + alignment; in MmapAlignedOrDieOnFatalError() local 92 map_size = RoundUpTo(map_size, GetPageSizeCached()); in MmapAlignedOrDieOnFatalError() 93 uptr map_res = (uptr)MmapOrDieOnFatalError(map_size, mem_type); in MmapAlignedOrDieOnFatalError() 101 uptr map_end = map_res + map_size; in MmapAlignedOrDieOnFatalError()
|
| HD | sanitizer_linux_libcdep.cpp | 1019 const uptr map_size = shadow_size + left_padding + alignment; in MapDynamicShadow() local 1021 const uptr map_start = (uptr)MmapNoAccess(map_size); in MapDynamicShadow() 1027 UnmapFromTo(shadow_start + shadow_size, map_start + map_size); in MapDynamicShadow() 1077 const uptr map_size = left_padding + 2 * alignment; in MapDynamicShadowAndAliases() local 1079 const uptr map_start = reinterpret_cast<uptr>(MmapNoAccess(map_size)); in MapDynamicShadowAndAliases() 1084 UnmapFromTo(right_start + right_size, map_start + map_size); in MapDynamicShadowAndAliases()
|
| /freebsd-head/sys/dev/smbios/ |
| HD | smbios.c | 88 size_t map_size = sizeof(*eps); in smbios_identify() local 97 map_size = sizeof(*eps3); in smbios_identify() 109 map_size = sizeof(*eps3); in smbios_identify() 119 ptr = pmap_mapbios(addr, map_size); in smbios_identify() 124 if (map_size == sizeof(*eps3)) { in smbios_identify() 135 if (length != map_size) { in smbios_identify() 140 if (length == 0x1e && map_size == sizeof(*eps) && in smbios_identify() 142 length = map_size; in smbios_identify() 146 map_size == sizeof(*eps3) ? "64" : "32", in smbios_identify() 147 length, map_size); in smbios_identify() [all …]
|
| /freebsd-head/stand/kboot/libkboot/ |
| HD | efi.c | 32 uint32_t efisz, sz, map_size; 57 map_size = sizeof(struct efi_md) * entries; 59 sz = efisz + map_size; 60 buf = malloc(efisz + map_size); 67 efi_map_hdr->memory_size = map_size; 108 efi_read_from_pa(uint64_t pa, uint32_t map_size, uint32_t desc_size, uint32_t vers) in efi_read_from_pa() argument 123 sz = efisz + map_size; in efi_read_from_pa() 124 buf = malloc(efisz + map_size); in efi_read_from_pa() 131 efi_map_hdr->memory_size = map_size; in efi_read_from_pa()
|
| /freebsd-head/tools/test/stress2/misc/ |
| HD | mmap.sh | 29 static const size_t map_size = 0x1000; 36 p = mmap(NULL, 2 * map_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 43 if (munmap(p, map_size) == -1) {
|
| /freebsd-head/lib/geom/virstor/ |
| HD | geom_virstor.c | 162 size_t map_size; /* In bytes. */ in virstor_label() local 239 map_size = total_chunks * sizeof(*map); in virstor_label() 242 ssize = map_size % secsize; in virstor_label() 247 map_size = total_chunks * sizeof(*map); in virstor_label() 282 if (msize < (off_t) MAX(md.md_chunk_size*4, map_size)) in virstor_label() 301 map_chunks = map_size/md.md_chunk_size; in virstor_label() 302 if (map_size % md.md_chunk_size != 0) in virstor_label() 305 printf(" (%zu MB, %d chunks) ", map_size/(1024*1024), map_chunks); in virstor_label() 353 map_size, strerror(errno)); in virstor_label()
|
| /freebsd-head/tests/sys/fs/fusefs/ |
| HD | io.cc | 290 size_t map_size; in do_mapread() local 294 map_size = pg_offset + size; in do_mapread() 296 p = mmap(NULL, map_size, PROT_READ, MAP_FILE | MAP_SHARED, m_test_fd, in do_mapread() 307 ASSERT_EQ(0, munmap(p, map_size)) << strerror(errno); in do_mapread() 338 size_t map_size; in do_mapwrite() local 343 map_size = pg_offset + size; in do_mapwrite() 357 p = mmap(NULL, map_size, PROT_READ | PROT_WRITE, in do_mapwrite() 366 ASSERT_EQ(0, munmap(p, map_size)) << strerror(errno); in do_mapwrite()
|
| /freebsd-head/crypto/openssl/crypto/ |
| HD | mem_sec.c | 311 size_t map_size; member 497 sh.map_size = pgsize + sh.arena_size + pgsize; in sh_init() 501 sh.map_result = mmap(NULL, sh.map_size, in sh_init() 509 sh.map_result = mmap(NULL, sh.map_size, in sh_init() 518 sh.map_result = VirtualAlloc(NULL, sh.map_size, MEM_COMMIT | MEM_RESERVE, PAGE_READWRITE); in sh_init() 584 if (sh.map_result != MAP_FAILED && sh.map_size) in sh_done() 585 munmap(sh.map_result, sh.map_size); in sh_done() 587 if (sh.map_result != NULL && sh.map_size) in sh_done()
|
| /freebsd-head/tools/regression/fsx/ |
| HD | fsx.c | 515 unsigned map_size; in domapread() local 547 map_size = pg_offset + size; in domapread() 549 if ((p = (char *)mmap(0, map_size, PROT_READ, MAP_FILE | MAP_SHARED, fd, in domapread() 558 if (munmap(p, map_size) != 0) { in domapread() 638 unsigned map_size; in domapwrite() local 683 map_size = pg_offset + size; in domapwrite() 685 if ((p = (char *)mmap(0, map_size, PROT_READ | PROT_WRITE, in domapwrite() 692 if (mapped_msync && msync(p, map_size, MS_SYNC) != 0) { in domapwrite() 699 if (munmap(p, map_size) != 0) { in domapwrite()
|
| /freebsd-head/sys/contrib/openzfs/module/zfs/ |
| HD | vdev_indirect_mapping.c | 295 uint64_t map_size = vdev_indirect_mapping_size(vim); in vdev_indirect_mapping_close() local 296 vmem_free(vim->vim_entries, map_size); in vdev_indirect_mapping_close() 362 uint64_t map_size = vdev_indirect_mapping_size(vim); in vdev_indirect_mapping_open() local 363 vim->vim_entries = vmem_alloc(map_size, KM_SLEEP); in vdev_indirect_mapping_open() 364 VERIFY0(dmu_read(os, vim->vim_object, 0, map_size, in vdev_indirect_mapping_open()
|
| /freebsd-head/contrib/libcbor/src/cbor/ |
| HD | serialization.c | 123 size_t map_size = cbor_map_is_definite(item) in cbor_serialized_size() local 128 map_size = _cbor_safe_signaling_add( in cbor_serialized_size() 129 map_size, in cbor_serialized_size() 133 return map_size; in cbor_serialized_size()
|
| /freebsd-head/stand/kboot/include/ |
| HD | efi.h | 18 bool efi_read_from_pa(uint64_t pa, uint32_t map_size, uint32_t desc_size, uint32_t vers);
|
| /freebsd-head/sys/geom/virstor/ |
| HD | g_virstor.h | 94 size_t map_size; /* (in bytes) */ member
|
| HD | g_virstor.c | 1216 sc->map_size = sc->chunk_count * sizeof *(sc->map); in virstor_check_and_run() 1218 sc->map = malloc(sc->map_size, M_GVIRSTOR, M_WAITOK); in virstor_check_and_run() 1220 __func__, sc->map_size, sc->provider->name)); in virstor_check_and_run() 1221 sc->map_sectors = sc->map_size / sc->sectorsize; in virstor_check_and_run() 1242 while (count < sc->map_size) { in virstor_check_and_run() 1246 bs = MIN(maxphys, sc->map_size - count); in virstor_check_and_run()
|
| /freebsd-head/sys/contrib/dev/mediatek/mt76/mt7915/ |
| HD | mmio.c | 482 for (i = 0; i < dev->reg.map_size; i++) { in __mt7915_reg_addr() 761 dev->reg.map_size = ARRAY_SIZE(mt7915_reg_map); in mt7915_mmio_init() 767 dev->reg.map_size = ARRAY_SIZE(mt7916_reg_map); in mt7915_mmio_init() 774 dev->reg.map_size = ARRAY_SIZE(mt7986_reg_map); in mt7915_mmio_init()
|
| /freebsd-head/sys/contrib/dev/mediatek/mt76/mt7996/ |
| HD | mmio.c | 176 for (i = 0; i < dev->reg.map_size; i++) { in __mt7996_reg_addr() 461 dev->reg.map_size = ARRAY_SIZE(mt7996_reg_map); in mt7996_mmio_init() 467 dev->reg.map_size = ARRAY_SIZE(mt7996_reg_map); in mt7996_mmio_init()
|
| HD | regs.h | 24 u32 map_size; member
|
| /freebsd-head/contrib/llvm-project/llvm/include/llvm/LTO/legacy/ |
| HD | LTOModule.h | 105 size_t map_size, off_t offset,
|
| /freebsd-head/contrib/llvm-project/openmp/runtime/src/ |
| HD | kmp_taskdeps.cpp | 696 if (new_taskdata->td_task_id >= tdg->map_size) { in __kmpc_omp_task_with_deps() 698 if (new_taskdata->td_task_id >= tdg->map_size) { in __kmpc_omp_task_with_deps() 699 kmp_uint old_size = tdg->map_size; in __kmpc_omp_task_with_deps() 722 tdg->map_size = new_size; in __kmpc_omp_task_with_deps()
|
| HD | kmp_tasking.cpp | 2038 if (new_taskdata->td_task_id >= new_taskdata->tdg->map_size) { 2042 if (new_taskdata->td_task_id >= tdg->map_size) { 2043 kmp_uint old_size = tdg->map_size; 2066 tdg->map_size = new_size; 5590 tdg->map_size = INIT_MAPSIZE; 5666 kmp_int32 this_map_size = tdg->map_size; 5677 tdg->map_size = this_map_size;
|
| /freebsd-head/usr.sbin/bhyvectl/amd64/ |
| HD | bhyvectl_machdep.c | 401 int error, fd, map_size; in dump_msr_bitmap() local 413 map_size = PAGE_SIZE; in dump_msr_bitmap() 415 map_size = 2 * PAGE_SIZE; in dump_msr_bitmap() 417 bitmap = mmap(NULL, map_size, PROT_READ, MAP_SHARED, fd, addr); in dump_msr_bitmap() 431 munmap((void *)bitmap, map_size); in dump_msr_bitmap()
|
| /freebsd-head/contrib/llvm-project/llvm/include/llvm-c/ |
| HD | lto.h | 238 size_t map_size, off_t offset);
|
| /freebsd-head/contrib/llvm-project/llvm/lib/LTO/ |
| HD | LTOModule.cpp | 132 size_t map_size, off_t offset, in createFromOpenFileSlice() argument 136 map_size, offset); in createFromOpenFileSlice()
|