[SeaBIOS] [PATCH v2 3/3] pci: recognize RH PCI legacy bridge resource reservation capability

Liu, Jing2 jing2.liu at linux.intel.com
Fri Aug 24 10:08:57 CEST 2018



On 8/24/2018 4:02 PM, Laszlo Ersek wrote:
> On 08/24/18 09:48, Liu, Jing2 wrote:
[...]
>>>>>>>> +    if (pci_config_readw(bdf, PCI_VENDOR_ID) !=
>>>>>>>> PCI_VENDOR_ID_REDHAT) {
>>>>>>>> +        dprintf(1, "PCI: QEMU resource reserve cap vendor ID
>>>>>>>> doesn't
>>>>>>>> match.\n");
>>>>>>>
>>>>>>> I'd suggest to use a higher debug level for this one, 3 would be a
>>>>>>> good
>>>>>>> pick I think.  level 1 messages are printed by default, and we should
>>>>>>> not spam the log just because there is a non-qemu bridge present
>>>>>>> in the
>>>>>>> system.
>>>>>> OK. Will do that.
>>>>>
>>>>> With the debug level update, I'm ready to give my R-b for this series.
>>>>>
>>>> Thanks for your feedback!
>>>> So do I need update another version and with your R-b?
>>>
>>> I imagine you'd post v3 with the update Gerd requested for the debug
>>> level(s), and then I'd respond with my R-b. (Obviously I'm not a SeaBIOS
>>> maintainer so that'll not be "decisive" by any means.)
>>>
>> Oh, BTW, I am considering, if only dismatch vendor-id stands for
>> "non-qemu bridge" or dismatch both vid and did? I guess I need change both.
> 
> I don't understand. Can you post an incremental diff in this thread just
> for illustration?

We check vendor-id/device-id and report when dismatch.
My question is,
Gerd suggested "not spam the log just because there is a non-qemu bridge 
present", so I think if both vendor-id and device-id dismatch means 
non-qemu bridge present?

+    if (pci_config_readw(bdf, PCI_VENDOR_ID) != PCI_VENDOR_ID_REDHAT) {
+        dprintf(3, "PCI: QEMU resource reserve cap vendor ID doesn't 
match.\n");
+        return 0;
+    }
+
+    device_id = pci_config_readw(bdf, PCI_DEVICE_ID);
+
+    if (device_id != PCI_DEVICE_ID_REDHAT_ROOT_PORT &&
+        device_id != PCI_DEVICE_ID_REDHAT_BRIDGE) {
+        dprintf(3, "PCI: QEMU resource reserve cap device ID doesn't 
match.\n");
+        return 0;
+    }

> 
> Thanks
> Laszlo
> 



More information about the SeaBIOS mailing list