Lines Matching refs:loop
353 static int attach_empty_file(int loop, int nr) { in attach_empty_file() argument
370 if (flock(loop, LOCK_EX) < 0) in attach_empty_file()
373 if (ioctl(loop, LOOP_SET_FD, fd) < 0) in attach_empty_file()
376 if (ioctl(loop, LOOP_SET_STATUS64, &(struct loop_info64) { in attach_empty_file()
383 if (ioctl(loop, LOOP_CLR_FD) < 0) in attach_empty_file()
516 _cleanup_close_ int loop = -1; in loop_device_make_internal() local
536 loop = open(loopdev, O_CLOEXEC|O_NONBLOCK|O_NOCTTY|open_flags); in loop_device_make_internal()
537 if (loop < 0) { in loop_device_make_internal()
543 … r = loop_configure(loop, nr, &config, &try_loop_configure, &seqnum, ×tamp); in loop_device_make_internal()
545 loop_with_fd = TAKE_FD(loop); in loop_device_make_internal()
550 r = attach_empty_file(loop, nr); in loop_device_make_internal()
567 loop = safe_close(loop); in loop_device_make_internal()