[U-Boot] board_pci_pre_scan() and board_pci_post_scan()
Simon Glass
sjg at chromium.org
Mon Aug 3 20:52:14 CEST 2015
Hi Bin,
On 2 August 2015 at 20:03, Bin Meng <bmeng.cn at gmail.com> wrote:
> Hi Simon,
>
> On Mon, Aug 3, 2015 at 6:31 AM, Simon Glass <sjg at chromium.org> wrote:
>> Hi Bin,
>>
>> On 27 July 2015 at 01:45, Bin Meng <bmeng.cn at gmail.com> wrote:
>>> Hi Simon,
>>>
>>> With driver model pci conversion on x86 boards, we now missed the call
>>> to board_pci_pre_scan() and board_pci_post_scan() which are called in
>>> the non-dm path. For example, board_pci_post_scan() in
>>> arch/x86/lib/fsp/fsp_common.c is not called to do any work as
>>> requested by FSP after pci enumeration.
>>>
>>> I am not sure where we could insert these call back in the dm. Do you
>>> have any possible solution on this?
>>
>> I know that the post-scan is needed for FSP - and in fact for
>> Minnowmax I added in back in a recent patch[1]. What is the pre-scan
>> used for?
>>
>> Regards,
>> Simon
>>
>> [1] http://patchwork.ozlabs.org/patch/500864/
>
> I see fsp_init_phase_pci() is called in arch_misc_init() which is
> really late in your patch. According to FSP spec, we should call this
> as soon as pci bus is enumerated. The original non-dm codes does this
> correctly. As for pre-scan, so far it does nothing. I believe we can
> drop it.
What does the FSP actually do with this? Also we may enumerate it
twice with your recent patches.
pci_uclass_post_probe() is the place where we kick off and complete
scanning of the bus. I'm open to options on this one, but perhaps if
we can forcing a bus problem as per your recent patch then we could
just call the FSP function there?
Regards,
Simon
More information about the U-Boot
mailing list