• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/sys/geom/linux_lvm/

Lines Matching defs:lv

197 	struct g_llvm_lv *lv;
207 lv = pp->private;
242 if (lv->lv_sgcount == 1) {
247 sg = lv->lv_firstsg;
257 LIST_FOREACH(sg, &lv->lv_segs, sg_next) {
284 offset, length, lv->lv_name,
314 struct g_llvm_lv *lv;
324 LIST_FOREACH(lv, &vg->vg_lvs, lv_next) {
327 LIST_FOREACH(sg, &lv->lv_segs, sg_next) {
330 lv->lv_sgactive--;
337 lv->lv_gprov->name);
338 g_wither_provider(lv->lv_gprov, ENXIO);
339 lv->lv_gprov = NULL;
366 g_llvm_activate_lv(struct g_llvm_vg *vg, struct g_llvm_lv *lv)
373 KASSERT(lv->lv_sgactive == lv->lv_sgcount, ("segment missing"));
376 pp = g_new_providerf(gp, "linux_lvm/%s-%s", vg->vg_name, lv->lv_name);
377 pp->mediasize = vg->vg_extentsize * (off_t)lv->lv_extentcount;
380 lv->lv_gprov = pp;
381 pp->private = lv;
395 struct g_llvm_lv *lv;
454 LIST_FOREACH(lv, &vg->vg_lvs, lv_next) {
456 LIST_FOREACH(sg, &lv->lv_segs, sg_next) {
465 lv->lv_sgactive++;
469 lv->lv_name, sg->sg_start, sg->sg_end,
476 if (lv->lv_gprov == NULL && lv->lv_sgactive == lv->lv_sgcount) {
477 error = g_llvm_activate_lv(vg, lv);
495 struct g_llvm_lv *lv;
503 while ((lv = LIST_FIRST(&vg->vg_lvs)) != NULL) {
504 while ((sg = LIST_FIRST(&lv->lv_segs)) != NULL) {
508 LIST_REMOVE(lv, lv_next);
509 free(lv, M_GLLVM);
1040 struct g_llvm_lv *lv;
1048 lv = malloc(sizeof(*lv), M_GLLVM, M_NOWAIT|M_ZERO);
1049 if (lv == NULL)
1052 lv->lv_vg = vg;
1053 LIST_INIT(&lv->lv_segs);
1057 len = llvm_grab_name(lv->lv_name, tok);
1064 llvm_textconf_decode_sg(buf, tok, lv);
1077 GRAB_STR("id", v, tok, lv->lv_uuid, sizeof(lv->lv_uuid));
1078 GRAB_INT("segment_count", v, tok, lv->lv_sgcount);
1084 if (lv->lv_sgcount == 0 || lv->lv_sgcount != lv->lv_numsegs)
1089 lv->lv_firstsg = LIST_FIRST(&lv->lv_segs);
1090 LIST_INSERT_HEAD(&vg->vg_lvs, lv, lv_next);
1091 G_LLVM_DEBUG(3, "lv: name=%s uuid=%s", lv->lv_name, lv->lv_uuid);
1095 while ((sg = LIST_FIRST(&lv->lv_segs)) != NULL) {
1099 free(lv, M_GLLVM);
1104 llvm_textconf_decode_sg(char **buf, char *tok, struct g_llvm_lv *lv)
1171 lv->lv_numsegs++;
1172 lv->lv_extentcount += sg->sg_count;
1173 LIST_INSERT_HEAD(&lv->lv_segs, sg, sg_next);