Lines Matching refs:rval
200 int rval = 0; in efi_get_info() local
221 rval = sscanf(dev_path, "/dev/%[a-zA-Z]%hu", in efi_get_info()
227 rval = sscanf(dev_path, "/dev/%[a-zA-Z]%hu", in efi_get_info()
234 rval = sscanf(dev_path, "/dev/md%[0-9]p%hu", in efi_get_info()
240 rval = sscanf(dev_path, "/dev/%[a-zA-Z]%hu", in efi_get_info()
246 rval = sscanf(dev_path, "/dev/%[a-zA-Z]%hu", in efi_get_info()
253 rval = sscanf(dev_path, "/dev/zd%[0-9]p%hu", in efi_get_info()
260 rval = sscanf(dev_path, "/dev/dm-%[0-9]p%hu", in efi_get_info()
267 rval = sscanf(dev_path, "/dev/ram%[0-9]p%hu", in efi_get_info()
274 rval = sscanf(dev_path, "/dev/loop%[0-9]p%hu", in efi_get_info()
287 rval = sscanf(dev_path, in efi_get_info()
297 switch (rval) { in efi_get_info()
405 int rval; in efi_alloc_and_read() local
420 rval = efi_read(fd, vptr); in efi_alloc_and_read()
422 if ((rval == VT_EINVAL) && vptr->efi_nparts > nparts) { in efi_alloc_and_read()
433 rval = efi_read(fd, vptr); in efi_alloc_and_read()
437 if (rval < 0) { in efi_alloc_and_read()
440 "read of EFI table failed, rval=%d\n", rval); in efi_alloc_and_read()
448 return (rval); in efi_alloc_and_read()
638 int rval = 0; in efi_read() local
654 if ((rval = efi_get_info(fd, &dki_info)) != 0) in efi_read()
655 return (rval); in efi_read()
724 } else if ((rval = check_label(fd, &dk_ioc)) == VT_EINVAL) { in efi_read()
742 rval = check_label(fd, &dk_ioc); in efi_read()
743 if (rval == VT_EINVAL) { in efi_read()
750 rval = check_label(fd, &dk_ioc); in efi_read()
751 if (rval == 0) { in efi_read()
760 if ((efi_debug) && (rval == 0)) in efi_read()
766 if (rval == 0) { in efi_read()
791 rval = VT_EINVAL; in efi_read()
796 rval = efi_ioctl(fd, DKIOCGETEFI, &dk_ioc); in efi_read()
800 } else if (rval == 0) { in efi_read()
807 rval = efi_ioctl(fd, DKIOCGETEFI, &dk_ioc); in efi_read()
809 } else if (vdc_flag && rval == VT_ERROR && errno == EINVAL) { in efi_read()
822 rval = check_label(fd, &dk_ioc); in efi_read()
825 if (rval < 0) { in efi_read()
827 return (rval); in efi_read()
1117 int rval; in efi_use_whole_disk() local
1125 rval = efi_alloc_and_read(fd, &efi_label); in efi_use_whole_disk()
1126 if (rval < 0) { in efi_use_whole_disk()
1129 return (rval); in efi_use_whole_disk()
1275 rval = call_blkpg_ioctl(fd, BLKPG_DEL_PARTITION, 0, 0, resv_index + 1); in efi_use_whole_disk()
1276 if (rval != 0) in efi_use_whole_disk()
1282 rval = call_blkpg_ioctl(fd, BLKPG_RESIZE_PARTITION, in efi_use_whole_disk()
1286 if (rval != 0) { in efi_use_whole_disk()
1288 "partition: %d\n", rval); in efi_use_whole_disk()
1313 if (rval == 0) { in efi_use_whole_disk()
1314 rval = efi_write(fd, efi_label); in efi_use_whole_disk()
1315 if (rval < 0 && efi_debug) { in efi_use_whole_disk()
1317 "to write label, rval=%d\n", rval); in efi_use_whole_disk()
1323 return (rval); in efi_use_whole_disk()
1337 int rval; in efi_write() local
1342 if ((rval = efi_get_info(fd, &dki_info)) != 0) in efi_write()
1343 return (rval); in efi_write()