Hi Zachary,

2011/8/8 Zachary Bedell <pendorbo...@gmail.com>:
> It appears that existing Grub code already links against libzfs for the 
> benefit of find_root_device_from_libzfs and other functions in getroot.c.  It 
> also appears that libzfs is not used outside this file.  That linkage 
> surprises me a bit as I would have expected GPL Grub linked against CDDL 
> libzfs to create a problem.

Not really.  This kind of use falls under the system library
exception, see section 1 of the GPL.

> Also libzfs is considered a private API and not intended to be linked 
>against, though admittedly what I propose (reading on-disk structures 
>directly) is arguably worse than accessing a private library.

I don't think you can figure out the disks corresponding to a zpool
just by reading disk structures.  You can guess, but only the kernel
knows for sure.

The other API that is available to us is /dev/zfs.  But is that device
meant to be used directly?  How stable is this interface?

-- 
Robert Millan

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to