Re: [Qemu-devel] [PATCH 3/3] Check pci slot number in parse_pci_devfn

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

 



On Tue, Aug 24, 2010 at 03:04:44PM +0300, Avi Kivity wrote:
>  On 08/24/2010 03:07 PM, Isaku Yamahata wrote:
>> On Tue, Aug 24, 2010 at 02:42:18PM +0300, Avi Kivity wrote:
>>>   On 08/24/2010 02:35 PM, Isaku Yamahata wrote:
>>>> Add Cc: mst@xxxxxxxxxxx
>>>>
>>>> MAX_PCI_SLOTS should be in pci.h instead of qdev.h?
>>>> And the name should be start with PCI_ prefix for consistency?
>>>>
>>>> Except that, the patches look okay.
>>>>
>>> These aren't slots, are they?  They are functions.
>> The function checks if given $slot.$fn (or $slot) is valid.
>> So it's slots. max 32.
>
> +    assert(devfn<  PCIBUS_MAX_DEVICES);
>
>
> Looks like we're comparing a function number to PCIBUS_MAX_DEVICES.

Ah, you're talking about 2/3. I talked about 3/3.
You're right. The name is misleading.
PCIBUS_MAX_FUNCTIONS? Or suggestions?
-- 
yamahata
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux