[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
64/67: syscalls: 'device-in-use?' returns #f upon EINVAL.
From: |
guix-commits |
Subject: |
64/67: syscalls: 'device-in-use?' returns #f upon EINVAL. |
Date: |
Wed, 16 Jan 2019 19:00:45 -0500 (EST) |
civodul pushed a commit to branch wip-newt-installer
in repository guix.
commit fc87e5bcd651f4d92204c9730f957c660bf9d0a8
Author: Ludovic Courtès <address@hidden>
Date: Wed Jan 16 17:43:52 2019 +0100
syscalls: 'device-in-use?' returns #f upon EINVAL.
This mirrors the behavior of the 'fdisk_device_is_used' function of
util-linux.
* guix/build/syscalls.scm (device-in-use?): Return #f upon EINVAL.
---
guix/build/syscalls.scm | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/guix/build/syscalls.scm b/guix/build/syscalls.scm
index 94d335b..66d63a2 100644
--- a/guix/build/syscalls.scm
+++ b/guix/build/syscalls.scm
@@ -701,6 +701,11 @@ backend device."
#f)
((= err EBUSY)
#t)
+ ((= err EINVAL)
+ ;; We get EINVAL for devices that have the GENHD_FL_NO_PART_SCAN flag
+ ;; set in the kernel, in particular loopback devices, though we do seem
+ ;; to get it for SCSI storage (/dev/sr0) on QEMU.
+ #f)
(else
(throw 'system-error "ioctl" "~A"
(list (strerror err))
- 65/67: installer: Adjust messages on the final page., (continued)
- 65/67: installer: Adjust messages on the final page., guix-commits, 2019/01/16
- 66/67: installer: "formating" → "formatting"., guix-commits, 2019/01/16
- 12/67: installer: Move everything to the build side., guix-commits, 2019/01/16
- 39/67: installer: Turn "Cancel" buttons into "Exit" buttons., guix-commits, 2019/01/16
- 23/67: installer: Do not ask for keyboard model., guix-commits, 2019/01/16
- 62/67: installer: partition: Add encryption password confirmation., guix-commits, 2019/01/16
- 60/67: installer: Remove debug popup., guix-commits, 2019/01/16
- 54/67: installer: parted: Use read-luks-partition-uuid instead of find-partition-by-luks-uuid., guix-commits, 2019/01/16
- 59/67: installer: welcome: Put "Graphical installer" ahead., guix-commits, 2019/01/16
- 55/67: installer: Various renamings., guix-commits, 2019/01/16
- 64/67: syscalls: 'device-in-use?' returns #f upon EINVAL.,
guix-commits <=
- 42/67: installer: network: Do not show an empty technology list., guix-commits, 2019/01/16
- 41/67: installer: keymap: Fix keymap selection of layouts with not variant., guix-commits, 2019/01/16
- 58/67: installer: Rename "Ok" buttons to "OK"., guix-commits, 2019/01/16
- 67/67: installer: Fix manual partitioning., guix-commits, 2019/01/16
- 61/67: installer: keymap: Put English layout and international variant ahead., guix-commits, 2019/01/16
- 56/67: installer: Various renamins follow-up., guix-commits, 2019/01/16
- 63/67: syscalls: 'device-in-use?' does not create a port., guix-commits, 2019/01/16
- 31/67: installer: Add partitioning support., guix-commits, 2019/01/16
- 51/67: installer: partionment: Add encryption support., guix-commits, 2019/01/16
- 04/67: gnu: Add graphical installer support., guix-commits, 2019/01/16