[U-Boot] [PATCH 3/5] x86: queensbay: Support pre-relocation dm pci
Simon Glass
sjg at chromium.org
Wed Aug 5 16:39:39 CEST 2015
Hi Bin,
On 2 August 2015 at 19:52, 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:33, Bin Meng <bmeng.cn at gmail.com> wrote:
>>> Increase CONFIG_MALLOC_F_LEN so that dm pci does not fail with -ENOMEM
>>> before relocation. This makes pci uart work again on Intel Crown Bay.
>>>
>>> Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
>>> ---
>>>
>>> arch/x86/cpu/queensbay/Kconfig | 3 +++
>>> arch/x86/cpu/queensbay/tnc.c | 13 +++++++++++++
>>> arch/x86/dts/crownbay.dts | 2 --
>>> 3 files changed, 16 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/arch/x86/cpu/queensbay/Kconfig b/arch/x86/cpu/queensbay/Kconfig
>>> index fbf85f2..8eb619c 100644
>>> --- a/arch/x86/cpu/queensbay/Kconfig
>>> +++ b/arch/x86/cpu/queensbay/Kconfig
>>> @@ -42,4 +42,7 @@ config CPU_ADDR_BITS
>>> int
>>> default 32
>>>
>>> +config SYS_MALLOC_F_LEN
>>> + default 0x8000
>>
>> 32KB? Wow that's a huge amount. How much does it actually use? Perhaps
>> we should change PCI so that it respects the u-boot,dm-pre-reloc
>> property?
>>
>
> I just add a zero to the original value :) I did not measure the
> actual memory consumption since after fsp_init() we have plenty of
> memory to be used as the stack. For queensbay platform, it has lots of
> pci devices each of which will need allocate some memory for dm pci to
> use.
I think it is worth checking this and using a value closer to what you
need. board_init_f.c has a debug output for it I think.
Also I wonder if we can avoid creating PCI devices for everything
pre-relocation, when we only need serial?
Regards,
SImon
More information about the U-Boot
mailing list