[U-Boot] [PATCH 00/12] sh: change arch and boards code to generic board

Nobuhiro Iwamatsu iwamatsu at nigauri.org
Fri Sep 16 03:11:02 CEST 2016


Hi,

Sorry, reply is late..

I will check your patches this weekend.

Best regards,
  Nobuhiro

2016-08-31 18:44 GMT+09:00 Vladimir Zapolskiy <vz at mleia.com>:
> On 06.08.2016 21:21, Vladimir Zapolskiy wrote:
>> The changeset implements initial support of relocatable U-Boot code
>> for SH2/SH3/SH4 architectures and boards, as weel as it restores
>> a possibility to boot U-Boot on SH boards, which has not been converted
>> to generic board in time (for more details see commit f41e6088eb1
>> ("sh: Fix build errors for generic board")). Special attention from
>> maintainers of all touched boards is required, due to inaccessibility
>> of hardware for me it would be a troublesome task.
>>
>> Now code/data initialization and relocation in general resemble the
>> procedure on ARM with minor peculiarities (same one relocation from a
>> storage device if calculated reloc_off == 0, otherwise two relocations),
>> however please note that the change does *not* add PIE support (only PIC),
>> so it may end up that there are persistent pointers to some non-relocated
>> data, this point requires better investion.
>>
>> There is a runtime dependency on one generic change in common/board_f.c,
>> see patch https://patchwork.ozlabs.org/patch/656371/ , also only r2dplus
>> board is actually converted to support new arcitectural changes,
>> application of patch 12/12 depends on SH7751 PCI fixes found at
>> https://patchwork.ozlabs.org/patch/656373/ :
>>
>>   -#define CONFIG_SYS_TEXT_BASE           0x8FFC0000
>>   +#define CONFIG_SYS_TEXT_BASE           0x8FE00000
>>
>> This r2dplus board change allows immediately check the correctness of
>> the series on a r2dplus qemu target, note that the second copy is
>> not avoided in this case, also for simplicity SDRAM area up to text base
>> is large enough to store malloc pool and two copies of loaded code/data.
>>
>> Board maintainers may pay attention to CONFIG_SYS_MALLOC_CLEAR_ON_INIT,
>> CONFIG_NEEDS_MANUAL_RELOC, CONFIG_SYS_GENERIC_GLOBAL_DATA etc. options.
>> To let know about the change and to continue with the completion of
>> the final step of board conversions to generic board I include all
>> SH2/SH3/SH4 board maintainers into Cc list, please update your board
>> configs appropriately.
>>
>> The change was tested on one custom SH4 (SH7551R) board, r2dplus qemu
>> target (see also SH7751 PCI change under review), the rest of the boards
>> are compile tested only.
>>
>> Multiple kudos to Simon for great patience and a decision to not remove
>> the code.
>>
>> Any further improvements are welcome, especially it's worth to mention
>> the anticipated convertion to PIE.
>>
>> Vladimir Zapolskiy (12):
>>   sh4: use single u-boot linker script for all boards
>>   sh: place board lowlevel_init code in the beginning of .text
>>   sh: define entry point and reloc_dst inside a linker script
>>   sh: add MEMORY command to a shared linker script
>>   sh: remove undefined DEBUG preprocessor token from board config files
>>   sh: define CONFIG_DISPLAY_BOARDINFO to print board information
>>   sh: add common dram_init() function for all boards
>>   sh: add shared relocate_code() function and call board_init_r()
>>   sh4: fix start.S by calling board_init_f() after first code relocation
>>   sh: share the correct version of start.S among all cpus
>>   sh: generate position independent code for all platforms
>>   r2dplus: fixup CONFIG_SYS_TEXT_BASE to account arch/sh changes
>>
>
> Ping.
>
> --
> Best wishes,
> Vladimir



-- 
Nobuhiro Iwamatsu
   iwamatsu at {nigauri.org / debian.org}
   GPG ID: 40AD1FA6


More information about the U-Boot mailing list