[coreboot] [PATCH] v3: improve PCI device doxygen comments and printks

Stefan Reinauer stepan at coresystems.de
Mon Aug 18 13:26:10 CEST 2008


Carl-Daniel Hailfinger wrote:
>>> + * - known knowns. In this case the device is in the tree, i.e. not NULL,
>>> + * and we know it's there: it's soldered down or part of the on-chip
>>> + * hardware. In this case dev is not NULL.
>>> + * - known unknowns. This is a device that might be there, but we don't
>>> + * know. So we have to probe it. It's in the dts, which is why
>>> + * it is a known unknown.
>>>   
>>>     
>>>       
>> How s the function called for the known knowns? Those are neither PCI
>>   
>>     
>
> Did you mean "called for the known UNknowns"?
>   
No.

1. The known unknowns ("listed, or expected pci devices") are called
from the dts, as you write.
2. The unknown unknowns ("scanned pci devices") are not in the dts but
scanned.

So what's the third case? A device is both listed in the dts and found
while scanning? Are those "expected and found"?

>>> @@ -1011,8 +1029,8 @@
>>>  		if ((id == 0xffffffff) || (id == 0x00000000) ||
>>>  		    (id == 0x0000ffff) || (id == 0xffff0000)) {
>>>  			if (dev->enabled) {
>>> -				printk(BIOS_INFO,
>>> -				       "Disabling static device: %s\n",
>>> +				printk(BIOS_INFO, "PCI: Static device not "
>>> +				       "found, setting enabled=0: %s\n",
>>>  				       dev_path(dev));
>>>   
>>>     
>>>       
>> I dislike this change of output. It's not a BIOS_DEBUG message.
>>   
>>     
>
> Do you dislike the severity level (same as before) or the new wording
> (the old wording was wrong)?
>   

Why did you consider it wrong?

Either the message should stay or the level should be raised to debug.
Not sure. "Setting enabled=0" implies you have to understand the code in
order to understand the message. This is bad for BIOS_INFO type messages
(Imho, for everything more "severe" than DEBUG)



-- 
coresystems GmbH • Brahmsstr. 16 • D-79104 Freiburg i. Br.
      Tel.: +49 761 7668825 • Fax: +49 761 7664613
Email: info at coresystems.dehttp://www.coresystems.de/
Registergericht: Amtsgericht Freiburg • HRB 7656
Geschäftsführer: Stefan Reinauer • Ust-IdNr.: DE245674866





More information about the coreboot mailing list