From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1UYlPO-00070d-8P for mharc-grub-devel@gnu.org; Sat, 04 May 2013 18:58:26 -0400 Received: from eggs.gnu.org ([208.118.235.92]:51945) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UYlPL-00070U-5r for grub-devel@gnu.org; Sat, 04 May 2013 18:58:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UYlPK-0006XM-4H for grub-devel@gnu.org; Sat, 04 May 2013 18:58:23 -0400 Received: from mail-ea0-x22c.google.com ([2a00:1450:4013:c01::22c]:48963) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UYlPJ-0006XH-UG for grub-devel@gnu.org; Sat, 04 May 2013 18:58:22 -0400 Received: by mail-ea0-f172.google.com with SMTP id r16so1199140ead.17 for ; Sat, 04 May 2013 15:58:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:x-enigmail-version:content-type; bh=AztZunaUgi4Z8PNkYB+fdCJ0tq695HfpsbT6oPnwgOM=; b=0ykmYtezFQs+yGt6UVuoJfG4XRFjxb3CgDNtHQ7g7MPY4pC9dtoNt7VmfjN+LO76my P0cok87p5F426KGZlBJXZuOtMN3tY0iyXKTGSBhTWwXGiUrc23mrTWCpbzEhR/eBkfNy i0cTMc6cDnUczhfL1PcGmwnM/Wt+KraYVyIAb6OhMNjpeX53rLavTOX0sQIaNf9YOgpQ YH0rB78cVEP1kOrc72QJRCDhKnCsF1fJfpwSHiVLvYdhb3fV4uPi7lD4um8ff+o+8aP9 Joe1VA4ooxHMC55tY0Vu1wypTnmRBiuqEL0CEww60lRjLgdWgC26n4bi1A5lWQ66Gjwt DB6g== X-Received: by 10.14.115.131 with SMTP id e3mr45171569eeh.43.1367708301026; Sat, 04 May 2013 15:58:21 -0700 (PDT) Received: from debian.x201.phnet (245-188.1-85.cust.bluewin.ch. [85.1.188.245]) by mx.google.com with ESMTPSA id bn53sm24198615eeb.7.2013.05.04.15.58.19 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 04 May 2013 15:58:20 -0700 (PDT) Message-ID: <5185928A.9060905@gmail.com> Date: Sun, 05 May 2013 00:58:18 +0200 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.12) Gecko/20130116 Icedove/10.0.12 MIME-Version: 1.0 To: grub-devel@gnu.org, Massimo Maggi Subject: Re: [PATCH 1/5] Fix reporting of RAIDZ vdevs in zfsinfo References: <510F96B1.6080509@massimo-maggi.eu> In-Reply-To: <510F96B1.6080509@massimo-maggi.eu> X-Enigmail-Version: 1.4.1 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enig9E7A290F533BE1670DF5FE96" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4013:c01::22c X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 04 May 2013 22:58:25 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig9E7A290F533BE1670DF5FE96 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable The patches look ok. The patches it's based on look like original work. However your patches are corrupted by your mailer beyond recovery. Can you resend them as attachements with changelog mentionning the origin? On 04.02.2013 12:08, Massimo Maggi wrote: > Author: Massimo Maggi > --- > grub-core/fs/zfs/zfsinfo.c | 20 +++++++++++++++----- > 1 file changed, 15 insertions(+), 5 deletions(-) >=20 > diff --git a/grub-core/fs/zfs/zfsinfo.c b/grub-core/fs/zfs/zfsinfo.c > index fdb587a..c96bf21 100644 > --- a/grub-core/fs/zfs/zfsinfo.c > +++ b/grub-core/fs/zfs/zfsinfo.c > @@ -132,21 +132,31 @@ print_vdev_info (char *nvlist, int tab) > grub_free (path); > return GRUB_ERR_NONE; > } > + char is_mirror=3D(grub_strcmp(type,VDEV_TYPE_MIRROR) =3D=3D 0); > + char is_raidz=3D(grub_strcmp(type,VDEV_TYPE_RAIDZ) =3D=3D 0); > - if (grub_strcmp (type, VDEV_TYPE_MIRROR) =3D=3D 0) > + if (is_mirror || is_raidz) > { > int nelm, i; > nelm =3D grub_zfs_nvlist_lookup_nvlist_array_get_nelm > (nvlist, ZPOOL_CONFIG_CHILDREN); > + if(is_mirror){ > + grub_puts_ (N_("This VDEV is a mirror")); > + } > + else if(is_raidz){ > + grub_uint64_t parity; > + grub_zfs_nvlist_lookup_uint64(nvlist,"nparity",&parity); > + grub_printf_ (N_("This VDEV is a RAIDZ%llu\n"),(unsigned long > long)parity); > + } > print_tabs (tab); > if (nelm <=3D 0) > { > - grub_puts_ (N_("Incorrect mirror")); > + grub_puts_ (N_("Incorrect VDEV")); > return GRUB_ERR_NONE; > } > - grub_printf_ (N_("Mirror with %d children\n"), nelm); > + grub_printf_ (N_("VDEV with %d children\n"), nelm); > print_state (nvlist, tab); > for (i =3D 0; i < nelm; i++) > { > @@ -162,14 +172,14 @@ print_vdev_info (char *nvlist, int tab) > total element number. And the number itself is fine, > only the element isn't. > */ > - grub_printf_ (N_("Mirror element number %d isn't correct\n"), i= ); > + grub_printf_ (N_("VDEV element number %d isn't correct\n"), i);= > continue; > } > /* TRANSLATORS: it's the element carying the number %d, not > total element number. This is used in enumeration > "Element number 1", "Element number 2", ... */ > - grub_printf_ (N_("Mirror element number %d:\n"), i); > + grub_printf_ (N_("VDEV element number %d:\n"), i); > print_vdev_info (child, tab + 1); > grub_free (child); >=20 >=20 >=20 > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel --------------enig9E7A290F533BE1670DF5FE96 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iF4EAREKAAYFAlGFkooACgkQNak7dOguQglqcQEAlZdWevwPbLwDyAvrCuzKuOPL +lL+YtvZ6aNmcSTHs78A+QE2NBAYwuECWhUp2DxmqVcmwyI8HL528X7ccqxSu1E6 =UyZS -----END PGP SIGNATURE----- --------------enig9E7A290F533BE1670DF5FE96--