From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1SMHGq-0006Qd-CI for mharc-grub-devel@gnu.org; Mon, 23 Apr 2012 07:17:28 -0400 Received: from eggs.gnu.org ([208.118.235.92]:38639) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SMHGm-0006OO-UF for grub-devel@gnu.org; Mon, 23 Apr 2012 07:17:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SMHGj-0007yH-7C for grub-devel@gnu.org; Mon, 23 Apr 2012 07:17:24 -0400 Received: from mail-wi0-f177.google.com ([209.85.212.177]:45785) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SMHGi-0007xf-UF for grub-devel@gnu.org; Mon, 23 Apr 2012 07:17:21 -0400 Received: by wibhj13 with SMTP id hj13so2149830wib.12 for ; Mon, 23 Apr 2012 04:17:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:x-enigmail-version:content-type; bh=4DX1J5aToiD4fgqZ8C7+lGPe/eyaAivuGsBaOjg26HI=; b=k4sFF+17NRKWHipGmR9KpQsHXjiz2WmlkRTRFw89nzdt6adTo+JNNPXGvAsahIbGOB HcaL9neMo1H49mc38sdR5DGUS2nC2p0DfvtiHngJWzcGHrFZbtNsuBYPeNhgLI9VqLcX sfPm+dwQPzWVjmx6WnbVb1FwZDxps8VHEZxySL4ekAHjivix6HfL6+EyzR7evT22mVo4 PX+hGLhE7F1m9rKMbPEF8ZSeqWErMt9Ky/UwD3d5Iru5avItS05qAlMa4vlgF84x6OiF e93RfPlTTflnXPVbLx+4NKAabI/6SzvNVmSC4JNvEbuzB7raNdXkDVwf/XwM7qtcaqI+ 14xQ== Received: by 10.216.138.17 with SMTP id z17mr9831404wei.18.1335179838900; Mon, 23 Apr 2012 04:17:18 -0700 (PDT) Received: from fedora.x201.phnet (public-docking-etx-2-251.ethz.ch. [192.33.88.251]) by mx.google.com with ESMTPS id h8sm34157054wix.4.2012.04.23.04.17.17 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 23 Apr 2012 04:17:17 -0700 (PDT) Message-ID: <4F953A3B.3000708@gmail.com> Date: Mon, 23 Apr 2012 13:17:15 +0200 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1 MIME-Version: 1.0 To: The development of GNU GRUB Subject: Re: [PATCH,HURD] Fix grub-probe with userland partition support References: <20120422182439.GE4755@type.famille.thibault.fr> <4F951839.4070309@gmail.com> <20120423094030.GB4755@type.famille.thibault.fr> <4F9532B5.9050701@gmail.com> <20120423110627.GL4755@type.famille.thibault.fr> In-Reply-To: <20120423110627.GL4755@type.famille.thibault.fr> X-Enigmail-Version: 1.4 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enigA6FB8C56FA7CABB43DA8D9D3" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.212.177 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: Mon, 23 Apr 2012 11:17:26 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigA6FB8C56FA7CABB43DA8D9D3 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 23.04.2012 13:06, Samuel Thibault wrote: > Vladimir '=CF=86-coder/phcoder' Serbinenko, le Mon 23 Apr 2012 12:45:09= +0200, a =C3=A9crit : >> On 23.04.2012 11:40, Samuel Thibault wrote: >>> Vladimir '=CF=86-coder/phcoder' Serbinenko, le Mon 23 Apr 2012 10:52:= 09 +0200, a =C3=A9crit : >>>> map was never intended to be globally visible. At most perhaps >>>> "semi-local" due to difficulties of split between getroot.c and host= disk.c >>>> Moreover the behaviour of find_root_device must be independent of wh= at >>>> is already in map since we don't rely anymore at map being populated= at >>>> all and at entries only on as-needed basis. >>> How can I get the same information, then? (the unix path correspondin= g >>> to a disk opened with grub_disk_open()) >> The problem is bigger than just getting the device from a disk. The >> problem is that you assume that grub_disk_dev_iterate will go through >> the disk in question which isn't necessarily true. > And so? > > Our need is to iterate over all disks that GRUB sees, to match that wit= h > where the file resides. It looks like you have missed some of 2.00 developement. We auto-add the device to map if necessary right after find_root_devices so at find_root_devices the disk won't be seen yet but find_root_devices has to work nevertheless. This function has nothing to do with the rest of GRUB. It could be a standalone program with syntax like find_root_devices DIR Output: /dev/sda1 /dev/sdb2 Any of GRUB context is irrelevant. (and actually so is the GRUB partition view, but you can use partition functions as they are stateless but beware that their view is likely to be different from GRUB's one). > Samuel > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel --=20 Regards Vladimir '=CF=86-coder/phcoder' Serbinenko --------------enigA6FB8C56FA7CABB43DA8D9D3 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/ iF4EAREKAAYFAk+VOjsACgkQNak7dOguQgmZhwD+IlxxC4vlylCbAiKqQCWDCGHj 3wzyhy8ht6SHXzskoFEA/0LpUMBjyelVgHvL8hptd+C4/q/Nahq/eP7+7KVdmybC =G8qm -----END PGP SIGNATURE----- --------------enigA6FB8C56FA7CABB43DA8D9D3--