Uclinux-2008r1-rc8 (bf561) to VDSP5 Transplantation (39): Link rearrangement

Source: Internet
Author: User

In the previous implementation, there is no manual SDRAM segmentation, when the kernel Hour has not found the problem, but when the kernel is getting larger, it began to appear problems. The main performance is VDSP5 in the link, will automatically some relatively small variables or code snippets into the space, even in the Output_section plus force_contiguity also have no effect.

Like what

___per_cpu_start = .;
INPUT_SECTIONS($LIBRARIES_UCLINUX(.data.percpu))
___per_cpu_end = .;

Finally found that. The contents of DATA.PERCPU were moved to other corners, while __per_cpu_start and __per_cpu_end all pointed to the same place, which inevitably caused the kernel to fail.

To solve this problem, the SDRAM is segmented by hand directly in the LDF file:

MEM_SDRAM_TEXT          { TYPE(RAM) START(0x00004000) END(0x00013fff) WIDTH(8) }
MEM_SDRAM_RODATA        { TYPE(RAM) START(0x00014000) END(0x00023fff) WIDTH(8) }
MEM_SDRAM_DATA          { TYPE(RAM) START(0x00034000) END(0x00043fff) WIDTH(8) }
MEM_SDRAM_INIT_TEXT     { TYPE(RAM) START(0x00044000) END(0x00053fff) WIDTH(8) }
MEM_SDRAM_INIT_PERCPU   { TYPE(RAM) START(0x00054000) END(0x00063fff) WIDTH(8) }
MEM_SDRAM               { TYPE(RAM) START(0x00064000) END(0x03ffffff) WIDTH(8) }

Then put the code or data of these segments into the appropriate memory space.

When the kernel increases, manually adjust the memory range above.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.