/dragonfly/contrib/lvm2/dist/lib/metadata/ |
H A D | pv_manip.c | 39 peg->pv = pv; in _alloc_pv_segment() 54 if (!pv->pe_count) in alloc_pv_segment_whole_pv() 58 if (!(peg = _alloc_pv_segment(mem, pv, 0, pv->pe_count, NULL, 0))) in alloc_pv_segment_whole_pv() 92 if (!(peg_new = _alloc_pv_segment(pv->fmt->cmd->mem, peg->pv, pe, in _pv_split_segment() 136 .pv = NULL, 148 if (!pv) in assign_peg_to_lvseg() 261 pv = pvl->pv; in check_pv_segments() 386 if ((uint64_t) new_pe_count * pv->pe_size > pv->size ) { in _extend_pv() 389 new_pe_count, pv->size / pv->pe_size); in _extend_pv() 393 peg = _alloc_pv_segment(pv->fmt->cmd->mem, pv, in _extend_pv() [all …]
|
H A D | metadata.c | 84 pv->pe_align = MAX(pv->pe_align, in set_pe_align() 98 pv->pe_align = MAX(pv->pe_align, in set_pe_align() 225 pvl->pv = pv; in add_pv_to_vg() 337 pv = pvl->pv; in move_pv() 527 pv = pvl->pv; in vg_remove() 641 pv = pvl->pv; in vg_reduce() 969 pv = pvl->pv; in vg_set_extent_size() 1211 if (pv && is_orphan(pv)) { in pvcreate_check() 1590 if (pvl->pv == pv) in find_pv_in_pv_list() 1601 if (pv == pvl->pv) in pv_is_in_vg() [all …]
|
H A D | metadata.h | 169 #define seg_pvseg(seg, s) (seg)->areas[(s)].u.pv.pvseg 170 #define seg_dev(seg, s) (seg)->areas[(s)].u.pv.pvseg->pv->dev 171 #define seg_pe(seg, s) (seg)->areas[(s)].u.pv.pvseg->pe 208 struct physical_volume * pv, struct dm_list *mdas, 221 struct physical_volume * pv, struct volume_group * vg); 228 struct physical_volume * pv, struct dm_list * mdas, 287 struct physical_volume *pv); 308 const struct physical_volume *pv); 378 struct id pv_id(const struct physical_volume *pv); 380 struct id pv_vgid(const struct physical_volume *pv); [all …]
|
H A D | pv_map.c | 51 PRIu32, pv_dev_name(pvm->pv), start, length); in _create_single_area() 68 if (end > pvm->pv->pe_count - 1) in _create_alloc_areas_for_pv() 69 end = pvm->pv->pe_count - 1; in _create_alloc_areas_for_pv() 74 dm_list_iterate_items(peg, &pvm->pv->segments) { in _create_alloc_areas_for_pv() 111 pvm->pv->pe_count)) in _create_all_areas_for_pv() 132 if (!(pvl->pv->status & ALLOCATABLE_PV)) in _create_maps() 134 if (pvl->pv->status & MISSING_PV) in _create_maps() 136 assert(pvl->pv->dev); in _create_maps() 141 if (pvm2->pv->dev == pvl->pv->dev) { in _create_maps() 150 pvm->pv = pvl->pv; in _create_maps()
|
/dragonfly/contrib/lvm2/dist/tools/ |
H A D | pvscan.c | 67 if (is_orphan(pv)) { in _pvscan_display_single() 71 pv->fmt ? pv->fmt->name : " ", in _pvscan_display_single() 83 pv_pe_size(pv)), in _pvscan_display_single() 85 pv_pe_alloc_count(pv)) in _pvscan_display_single() 93 pv->fmt ? pv->fmt->name : " ", in _pvscan_display_single() 95 pv_pe_size(pv)), in _pvscan_display_single() 98 pv_pe_size(pv))); in _pvscan_display_single() 146 pv = pvl->pv; in pvscan() 167 if (is_orphan(pv)) { in pvscan() 172 size_total += pv_pe_count(pv) * pv_pe_size(pv); in pvscan() [all …]
|
H A D | pvchange.c | 57 if (!is_orphan(pv)) { in _pvchange_single() 58 vg_name = pv_vg_name(pv); in _pvchange_single() 83 pv = pvl->pv; in _pvchange_single() 108 if (is_orphan(pv) && in _pvchange_single() 156 if (!id_create(&pv->id)) { in _pvchange_single() 164 if (!is_orphan(pv)) { in _pvchange_single() 173 pv->vg_name = pv->fmt->orphan_vg_name; in _pvchange_single() 174 pv->pe_alloc_count = 0; in _pvchange_single() 180 pv->vg_name = orig_vg_name; in _pvchange_single() 190 if (!is_orphan(pv)) { in _pvchange_single() [all …]
|
H A D | pvresize.c | 30 struct physical_volume *pv, in _pv_resize_single() argument 38 const char *pv_name = pv_dev_name(pv); in _pv_resize_single() 46 if (is_orphan_vg(pv_vg_name(pv))) { in _pv_resize_single() 61 vg_name = pv_vg_name(pv); in _pv_resize_single() 74 pv = pvl->pv; in _pv_resize_single() 121 if (size < pv_pe_start(pv)) { in _pv_resize_single() 127 pv->size = size; in _pv_resize_single() 130 pv->size -= pv_pe_start(pv); in _pv_resize_single() 137 pv_pe_size(pv)); in _pv_resize_single() 146 pv_name, pv_size(pv)); in _pv_resize_single() [all …]
|
H A D | pvdisplay.c | 32 if (!is_orphan(pv) && !vg) { in _pvdisplay_single() 33 vg_name = pv_vg_name(pv); in _pvdisplay_single() 53 pv = pvl->pv; in _pvdisplay_single() 56 if (is_orphan(pv)) in _pvdisplay_single() 57 size = pv_size(pv); in _pvdisplay_single() 59 size = (pv_pe_count(pv) - pv_pe_alloc_count(pv)) * in _pvdisplay_single() 60 pv_pe_size(pv); in _pvdisplay_single() 68 if (pv_status(pv) & EXPORTED_VG) in _pvdisplay_single() 72 if (is_orphan(pv)) in _pvdisplay_single() 77 pvdisplay_colons(pv); in _pvdisplay_single() [all …]
|
H A D | pvremove.c | 29 struct physical_volume *pv; in pvremove_check() local 38 if (!(pv = pv_read(cmd, name, &mdas, NULL, 1, 0))) { in pvremove_check() 52 if (is_orphan(pv) && !dm_list_size(&mdas)) { in pvremove_check() 58 if (!(pv = pv_read(cmd, name, NULL, NULL, 1, 0))) { in pvremove_check() 65 if (is_orphan(pv)) in pvremove_check() 72 "volume group \"%s\" without -ff", name, pv_vg_name(pv)); in pvremove_check() 78 yes_no_prompt(_really_wipe, name, pv_vg_name(pv)) == 'n') { in pvremove_check() 86 !is_orphan(pv) ? " of volume group \"" : "", in pvremove_check() 87 !is_orphan(pv) ? pv_vg_name(pv) : "", in pvremove_check() 88 !is_orphan(pv) ? "\"" : ""); in pvremove_check()
|
H A D | vgreduce.c | 35 if (pvl->pv->pe_alloc_count) { in _remove_pv() 42 vg->free_count -= pvl->pv->pe_count; in _remove_pv() 157 if (pvl->pv->dev && !(pvl->pv->status & MISSING_PV)) in _consolidate_vg() 173 struct physical_volume *pv; in _make_vg_consistent() local 196 pv = seg_pv(seg, s); in _make_vg_consistent() 197 if (!pv || !pv_dev(pv) || in _make_vg_consistent() 229 if (pvl->pv->dev) in _make_vg_consistent() 390 if (pv_pe_alloc_count(pv)) { in _vgreduce_single() 417 pv->status = ALLOCATABLE_PV; in _vgreduce_single() 419 if (!dev_get_size(pv_dev(pv), &pv->size)) { in _vgreduce_single() [all …]
|
H A D | vgconvert.c | 24 struct physical_volume *pv, *existing_pv; in vgconvert_single() local 121 existing_pv = pvl->pv; in vgconvert_single() 128 if (!(pv = pv_create(cmd, pv_dev(existing_pv), in vgconvert_single() 145 " available sectors", pv_dev_name(pv), pv_size(pv)); in vgconvert_single() 148 if (!label_remove(pv_dev(pv))) { in vgconvert_single() 150 pv_dev_name(pv)); in vgconvert_single() 157 pv_dev_name(pv)); in vgconvert_single() 158 if (!(pv_write(cmd, pv, &mdas, in vgconvert_single() 162 pv_dev_name(pv)); in vgconvert_single() 168 pv_dev_name(pv)); in vgconvert_single()
|
H A D | toollib.c | 353 struct pv_segment _free_pv_segment = { .pv = pv }; in process_each_segment_in_pv() 355 if (is_pv(pv) && !vg && !is_orphan(pv)) { in process_each_segment_in_pv() 356 vg_name = pv_vg_name(pv); in process_each_segment_in_pv() 376 pv = pvl->pv; in process_each_segment_in_pv() 586 struct physical_volume *pv; in _process_all_devs() local 611 pv = &pv_dummy; in _process_all_devs() 644 struct physical_volume *pv; in process_each_pv() local 688 pv = pvl->pv; in process_each_pv() 1015 (pvl->pv->pe_count == pvl->pv->pe_alloc_count)) { in _create_pv_entry() 1021 if (pvl->pv->dev == pvl2->pv->dev) { in _create_pv_entry() [all …]
|
/dragonfly/contrib/lvm2/dist/lib/format1/ |
H A D | import-export.c | 62 memset(pv, 0, sizeof(*pv)); in import_pv() 65 pv->dev = dev; in import_pv() 99 pv->pe_alloc_count = 0; in import_pv() 100 pv->pe_align = 0; in import_pv() 103 if (!pv->size || pv->size > (1ULL << 62)) { in import_pv() 110 pv_dev_name(pv)); in import_pv() 113 pv->pe_start; in import_pv() 114 if (size > pv->size) in import_pv() 154 if (pv->vg_name && !is_orphan(pv)) { in export_pv() 436 !(pvl->pv = dm_pool_alloc(mem, sizeof(*pvl->pv)))) in import_pvs() [all …]
|
H A D | format1.c | 196 struct physical_volume *pv, in _flatten_pv() argument 205 dl->dev = pv->dev; in _flatten_pv() 289 pv->fmt = fmt; in _format1_pv_read() 307 if (pv->size > MAX_PV_SIZE) in _format1_pv_setup() 308 pv->size--; in _format1_pv_setup() 309 if (pv->size > MAX_PV_SIZE) { in _format1_pv_setup() 365 if (!(info = lvmcache_add(fmt->labeller, (char *) &pv->id, pv->dev, in _format1_pv_write() 366 pv->vg_name, NULL, 0))) in _format1_pv_write() 377 pv->pe_size = pv->pe_count = 0; in _format1_pv_write() 378 pv->pe_start = LVM1_PE_ALIGN; in _format1_pv_write() [all …]
|
H A D | import-extents.c | 36 struct physical_volume *pv; member 113 struct physical_volume *pv; in _fill_maps() local 119 pv = find_pv(vg, dl->dev); in _fill_maps() 141 dev_name(pv->dev), i, in _fill_maps() 154 if (lvm->map[le].pv) { in _fill_maps() 160 lvm->map[le].pv = pv; in _fill_maps() 174 if (!lvm->map[i].pv) { in _check_single_map() 204 while ((lvm->map[le + len].pv == lvm->map[le].pv) && in _area_length() 205 (lvm->map[le].pv && in _area_length() 252 lvm->map[base_le + st * total_area_len].pv) || in _check_stripe() [all …]
|
/dragonfly/contrib/lvm2/dist/lib/format_pool/ |
H A D | import_export.c | 115 if (!(pvl->pv = dm_pool_zalloc(mem, sizeof(*pvl->pv)))) { in import_pool_pvs() 122 pl->pv = pvl->pv; in import_pool_pvs() 137 memset(pv, 0, sizeof(*pv)); in import_pool_pv() 140 pv->fmt = fmt; in import_pool_pv() 142 pv->dev = pl->dev; in import_pool_pv() 149 pv->status = 0; in import_pool_pv() 150 pv->size = pd->pl_blocks; in import_pool_pv() 153 pv->pe_count = pv->size / POOL_PE_SIZE; in import_pool_pv() 154 pv->pe_alloc_count = 0; in import_pool_pv() 155 pv->pe_align = 0; in import_pool_pv() [all …]
|
/dragonfly/contrib/lvm2/dist/lib/display/ |
H A D | display.c | 314 if (!pv) in pvdisplay_colons() 323 pv_dev_name(pv), pv->vg_name, pv->size, in pvdisplay_colons() 330 pv->pe_count - pv->pe_alloc_count, in pvdisplay_colons() 374 if (!pv) in pvdisplay_full() 385 is_orphan(pv) ? "" : pv->vg_name, in pvdisplay_full() 388 data_size = (uint64_t) pv->pe_count * pv->pe_size; in pvdisplay_full() 389 if (pv->size > data_size + pv->pe_start) { in pvdisplay_full() 408 pe_free = pv->pe_count - pv->pe_alloc_count; in pvdisplay_full() 409 if (pv->pe_count && (pv->status & ALLOCATABLE_PV)) in pvdisplay_full() 440 if (!pv) in pvdisplay_short() [all …]
|
/dragonfly/sys/platform/pc64/x86_64/ |
H A D | pmap.c | 114 #define pv_lock(pv) _pv_lock(pv \ argument 116 #define pv_hold_try(pv) _pv_hold_try(pv \ argument 130 #define pv_lock(pv) _pv_lock(pv) argument 131 #define pv_hold_try(pv) _pv_hold_try(pv) argument 133 #define pv_free(pv, pvp) _pv_free(pv, pvp) argument 595 if (pv == NULL || pv->pv_pmap != pmap) { in pv_entry_lookup() 597 if (pv) in pv_entry_lookup() 602 if (pv) in pv_entry_lookup() 608 return pv; in pv_entry_lookup() 745 if (pv == NULL || pv->pv_m == NULL) { in pmap_pt() [all …]
|
/dragonfly/contrib/lvm2/dist/lib/format_text/ |
H A D | import_vsn1.c | 166 !(pvl->pv = dm_pool_zalloc(mem, sizeof(*pvl->pv)))) in _read_pv() 169 pv = pvl->pv; in _read_pv() 191 if (!(pv->dev = device_from_pvid(fid->fmt->cmd, &pv->id))) { in _read_pv() 211 if (!pv->dev) in _read_pv() 245 pv->pe_alloc_count = 0; in _read_pv() 246 pv->pe_align = 0; in _read_pv() 247 pv->fmt = fid->fmt; in _read_pv() 250 if ((!pv->size || pv->size > (1ULL << 62)) && pv->dev) { in _read_pv() 251 if (!dev_get_size(pv->dev, &pv->size)) { in _read_pv() 260 pv->pe_start; in _read_pv() [all …]
|
H A D | format-text.c | 1401 pv_dev_name(pv), pv->pe_start); in _text_pv_write() 1411 pv->pe_start = pv->pe_align; in _text_pv_write() 1413 pv->pe_start += pv->pe_align_offset; in _text_pv_write() 1428 (pv->pe_start - pv->pe_align_offset) % pv->pe_align; in _text_pv_write() 1430 pv->pe_start += pv->pe_align - adjustment; in _text_pv_write() 1436 pv_dev_name(pv), pv->pe_start, in _text_pv_write() 1444 if (pv->pe_start >= pv->size) { in _text_pv_write() 1742 if (!pv->size && pv->pe_count) in _text_pv_setup() 1783 if (pv->pe_align < pv->pe_align_offset) { in _text_pv_setup() 1786 pv_dev_name(pv), pv->pe_align, pv->pe_align_offset); in _text_pv_setup() [all …]
|
/dragonfly/contrib/lvm2/dist/include/ |
H A D | metadata.h | 169 #define seg_pvseg(seg, s) (seg)->areas[(s)].u.pv.pvseg 170 #define seg_dev(seg, s) (seg)->areas[(s)].u.pv.pvseg->pv->dev 171 #define seg_pe(seg, s) (seg)->areas[(s)].u.pv.pvseg->pe 208 struct physical_volume * pv, struct dm_list *mdas, 221 struct physical_volume * pv, struct volume_group * vg); 228 struct physical_volume * pv, struct dm_list * mdas, 287 struct physical_volume *pv); 308 const struct physical_volume *pv); 378 struct id pv_id(const struct physical_volume *pv); 380 struct id pv_vgid(const struct physical_volume *pv); [all …]
|
/dragonfly/contrib/tcsh-6/ |
H A D | sh.exec.c | 175 trim(pv); in doexec() 209 xfree(pv); in doexec() 265 pv = opv; in doexec() 309 pv++; in doexec() 671 for (pv = v->vec; pv && *pv; pv++, hashwidth++) in dohash() 697 for (pv = v->vec; pv && *pv; pv++, i++) { in dohash() 829 pv = opv; in iscommand() 855 pv++; in iscommand() 1007 Char **pv; in tellmewhat() local 1018 if (pv[0][0] == 0 || eq(pv[0], STRdot)) { in tellmewhat() [all …]
|
/dragonfly/sys/platform/vkernel64/platform/ |
H A D | pmap.c | 2090 pmap_unuse_pt(pmap, pv->pv_va, pv->pv_ptem); in pmap_remove_all() 2144 pmap_unuse_pt(pmap, pv->pv_va, pv->pv_ptem); in pmap_remove_specific() 2736 for (pv = TAILQ_FIRST(&pmap->pm_pvlist); pv; pv = npv) { in pmap_remove_pages() 2737 if (pv->pv_va >= eva || pv->pv_va < sva) { in pmap_remove_pages() 2782 pmap_unuse_pt(pmap, pv->pv_va, pv->pv_ptem); in pmap_remove_pages() 2823 pmap_track_modified(pv->pv_pmap, pv->pv_va); in pmap_testbit() 2831 pte = pmap_pte(pv->pv_pmap, pv->pv_va); in pmap_testbit() 2887 pmap_track_modified(pv->pv_pmap, pv->pv_va); in pmap_clearbit() 2908 pte = pmap_pte(pv->pv_pmap, pv->pv_va); in pmap_clearbit() 3011 pte = pmap_pte(pv->pv_pmap, pv->pv_va); in pmap_ts_referenced() [all …]
|
/dragonfly/contrib/lvm2/dist/lib/report/ |
H A D | columns.h | 81 FIELD(LABEL, pv, STR, "Fmt", id, 3, pvfmt, "pv_fmt", "Type of metadata.") 82 FIELD(LABEL, pv, STR, "PV UUID", id, 38, uuid, "pv_uuid", "Unique identifier.") 83 FIELD(LABEL, pv, NUM, "DevSize", dev, 7, devsize, "dev_size", "Size of underlying device in current… 84 FIELD(LABEL, pv, STR, "PV", dev, 10, dev_name, "pv_name", "Name.") 89 FIELD(PVS, pv, NUM, "PSize", id, 5, pvsize, "pv_size", "Size of PV in current units.") 90 FIELD(PVS, pv, NUM, "PFree", id, 5, pvfree, "pv_free", "Total amount of unallocated space in curren… 91 FIELD(PVS, pv, NUM, "Used", id, 4, pvused, "pv_used", "Total amount of allocated space in current u… 92 FIELD(PVS, pv, STR, "Attr", status, 4, pvstatus, "pv_attr", "Various attributes - see man page.") 93 FIELD(PVS, pv, NUM, "PE", pe_count, 3, uint32, "pv_pe_count", "Total number of Physical Extents.") 95 FIELD(PVS, pv, STR, "PV Tags", tags, 7, tags, "pv_tags", "Tags, if any.") [all …]
|
/dragonfly/contrib/lvm2/dist/liblvm/ |
H A D | lvm_pv.c | 22 char *lvm_pv_get_uuid(const pv_t pv) in lvm_pv_get_uuid() argument 26 if (!id_write_format(&pv->id, uuid, sizeof(uuid))) { in lvm_pv_get_uuid() 33 char *lvm_pv_get_name(const pv_t pv) in lvm_pv_get_name() argument 38 strncpy(name, (const char *)pv_dev_name(pv), NAME_LEN); in lvm_pv_get_name() 43 uint64_t lvm_pv_get_mda_count(const pv_t pv) in lvm_pv_get_mda_count() argument 45 return (uint64_t) pv_mda_count(pv); in lvm_pv_get_mda_count() 48 int lvm_pv_resize(const pv_t pv, uint64_t new_size) in lvm_pv_resize() argument
|