On Mon, Aug 16, 2010 at 06:21:31PM +0200, Xavi Drudis Ferran wrote:
Xavi Drudis Ferran wrote:
1.- In order to get sb700_lpc_init in sb700_early_setup.c to work I've got to modifiy pci_locate_device in order to refrain from scanning some functions in pci bus 0.
Hm. Which fn?
Sorry, I should have said devices. I think it scans every function of every device, reg. 00 and I told it not to do so for any function of some devices (those with nothing attached in my board). I'll send the patch later.
Here's the patch. I'll attach lspci output with the propietary BIOS in order to compare with the excluded devices. I'm testing without the Nvidia VGA, though. With svn 5701 + the earlier patch patch.warnerror + patch.serial1 that I'll attach here, my mainboard outputs to serial and stops at setAMDMSR (after start other cores, so I might misread the log)
I don't know if it makes sense. That's not neccessarily the case. It depends on if the SB700 can have a different BDF on different boards.
I'd say no, but what do I know?
but then I wonder whether my change is acceptable for other mainboards,
No, I don't think it is.
Please don't commit this patch. It's just an illustration on what I did to have serial output, but it may break other boards, or (I don't think so) the same mainboard with other hardware attached.
It seems I have to sign off even if I'm asking not to be commited so:
Signed off by: Xavi Drudis Ferran xdrudis@tinet.cat
In general nothing should be hard coded that is not hard coded in documentation. Ie. if BDF *can* change, then it can not be hard coded. However, the BDF should already be available from devicetree.cb, and hopefully that can be used also for early setup.
Ah, I'll see how to access de devicetree.cb, then. But I think it was hardcoded in docs. They said dev 0 func 0x14 IIRC. I'll check again.
I'm rereading docs for SB700 linked from http://www.coreboot.org/Datasheets#AMD_SB700.2FSB710.2FSB750
And I only see hardcoded BDF in the docs (in diagrams, chapter titles, text and assembler examples).
So I thik I'll change sb700_early_init to use hardcoded BDF unless someone thinks otherwise.
Ok. I have to clean up the code a little and incorporate las weekend svn changes, and then I'll break the changes in patches and start sending them. Beware that they are not completely tested (my board does not boot yet).
It's getting late. I'll continue tomorrow.