[libvirt] [PATCH v1 1/4] bhyve: detect 32 SATA devices per controller support

Fabian Freyer fabian.freyer at physik.tu-berlin.de
Tue Jan 24 18:05:42 UTC 2017


On 24 Jan 2017, at 16:31, Laine Stump wrote:
>> +    cmd = virCommandNew(binary);
>> +    virCommandAddArgList(cmd, "-s", "0,ahci", NULL);
>> +    virCommandSetErrorBuffer(cmd, &error);
>
> Too bad there isn't some way you could learn both of these with a 
> single run of the binary.
>
>> +    if (virCommandRun(cmd, &exit) < 0) {
>> +        ret = -1;
>> +        goto out;
>> +    }
>> +
>> +    if (strstr(error, "pci slot 0:0: unknown device \"ahci\"") == 
>> NULL)
>> +        *caps |= BHYVE_CAP_AHCI32SLOT;
>
> That seems like a fairly fragile check. Are you certain there aren't 
> older versions where the error string is different?
>
> Anyway, lacking any better check, ACK.

AFAIR there is a patch in the queue for that upstream 
(https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=210111), but there 
hasn’t been much movement there.




More information about the libvir-list mailing list