[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#635393: detection of GEOM encryption devices (GELI)



Package: parted
Version: 2.3-7
Severity: wishlist
Tags: patch
User: debian-bsd@lists.debian.org
Usertags: kfreebsd

Please consider this patch to add detection of GEOM encryption devices (GELI)
to Parted.

-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: kfreebsd-amd64 (x86_64)

Kernel: kFreeBSD 8.2-1-amd64
Locale: LANG=ca_AD.UTF-8, LC_CTYPE=ca_AD.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages parted depends on:
ii  libblkid1                     2.19.1-4   block device id library
ii  libc0.1                       2.13-10    Embedded GNU C Library: Shared lib
ii  libncurses5                   5.9-1      shared libraries for terminal hand
ii  libparted0debian1             2.3-7      disk partition manipulator - share
ii  libreadline6                  6.2-2      GNU readline and history libraries
ii  libuuid1                      2.19.1-4   Universally Unique ID library

parted recommends no packages.

Versions of packages parted suggests:
pn  parted-doc                    <none>     (no description available)

-- no debconf information
=== modified file 'libparted/arch/freebsd.c'
--- libparted/arch/freebsd.c	2011-07-25 17:55:28 +0000
+++ libparted/arch/freebsd.c	2011-07-25 17:59:10 +0000
@@ -1058,6 +1058,8 @@
 {
 	size_t listsize;
 	char *disklist, *pdisklist, *psave;
+	char buf[PATH_MAX];
+	struct stat st;
 
 	if (sysctlbyname("kern.disks", NULL, &listsize, NULL, 0) != 0) {
 		ped_exception_throw (
@@ -1091,6 +1093,10 @@
 		strncat (dev_name, token, sizeof(dev_name) - strlen(_PATH_DEV) - 1);
 		dev_name[sizeof(dev_name) - 1] = '\0';
 		_ped_device_probe (dev_name);
+
+		snprintf (buf, sizeof (buf), "%s.eli", dev_name);
+		if (stat (buf, &st) == 0)
+			_ped_device_probe (buf);
 	}
 
 	free(disklist);


Reply to: