uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(16):使用head.s做为入口点

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

快乐虾

http://blog.csdn.net/lights_joy/

[email protected]

本文适用于

ADI bf561 DSP

优视BF561EVB开发板

uclinux-2008r1.5-rc3

Visual DSP++ 5.0(update 5)

欢迎转载,但请保留作者信息

创建uclinux工程时,默认的入口是uclinux _basiccrt.s,而我们需要用head.s做为入口,因此需要修改ldf文件中的相关定义。

uclinux.ldf文件中有这么几行:

$OBJECTS_CORE_A =

/*$VDSG<insert-user-objects-for-coreA-beginning> */

/* Text inserted between these $VDSG comments will be preserved */

/*$VDSG<insert-user-objects-for-coreA-beginning> */

"uclinux_basiccrt.doj"

, RT_LIB_NAME(profile561)

, $COMMAND_LINE_OBJECTS {!DualCoreMem("CoreB")}

, "cplbtab<?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /><chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="561" unitname="a">561a</chmetcnv>.doj"

, RT_OBJ_NAME(crtn561)

在此先删除uclinux _basiccrt.doj,于是就变成了

$OBJECTS_CORE_A =

/*$VDSG<insert-user-objects-for-coreA-beginning> */

/* Text inserted between these $VDSG comments will be preserved */

/*$VDSG<insert-user-objects-for-coreA-beginning> */

, RT_LIB_NAME(profile561)

, $COMMAND_LINE_OBJECTS {!DualCoreMem("CoreB")}

, "cplbtab<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="561" unitname="a">561a</chmetcnv>.doj"

, RT_OBJ_NAME(crtn561)

此外,还要在processor p0中保留__start的位置。在默认生成的LDF文件中,是这样的:

RESOLVE(start, 0xFFA00000)

KEEP(start,_main)

我们将其指向head.s中的__start,修改后变成:

RESOLVE(__start, 0xFFA00000)

KEEP(__start,_main)

当然,这样修改后会造成一系列的错误:

[Error li1021] The following symbols referenced in processor 'p0' could not be resolved:

'__bss_start [___bss_start]' referenced from 'corea.dlb[head.doj]'

'__bss_stop [___bss_stop]' referenced from 'corea.dlb[head.doj]'

'_sdata [__sdata]' referenced from 'corea.dlb[head.doj]'

'_stext [__stext]' referenced from 'corea.dlb[head.doj]'

'bf53x_relocate_l1_mem [_bf53x_relocate_l1_mem]' referenced from 'corea.dlb[head.doj]'

'cmdline_init [_cmdline_init]' referenced from 'corea.dlb[head.doj]'

'init_pda [_init_pda]' referenced from 'corea.dlb[head.doj]'

'init_thread_union [_init_thread_union]' referenced from 'corea.dlb[head.doj]'

'start_kernel [_start_kernel]' referenced from 'corea.dlb[head.doj]'

没关系,这正好说明我们的head.s已经开始起作用了。

1 参考资料

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(1):前言(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5移植(2):代码注释(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(3):vdsp项目创建(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(4):目录差异(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(5):'bf561.h'的问题(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(6):CONFIG_BFIN_KERNEL_CLOCK(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(7):CONFIG_MEM_MT48LC16M16A2TG_75(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(8):CONFIG_CLKIN_HZ(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(9):CONFIG_MEM_SIZE(<chsdate w:st="on" year="2009" month="1" day="12" islunardate="False" isrocdate="False">2009-1-12</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(10):CONFIG_FLASH_SPEED_BTT(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(11):__INIT(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(12):trace_buffer_init(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

uclinux-2008R1.5-RC3(bf561)到VDSP5的移植(13):ENDPROC(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

uclinux-2008R1.5-RC3(bf561)VDSP5的移植(14)__FINIT(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

uclinux-2008R1.5-RC3(bf561)VDSP5的移植(15)CONFIG_BANK_x(<chsdate w:st="on" year="2009" month="1" day="13" islunardate="False" isrocdate="False">2009-1-13</chsdate>)

你可能感兴趣的:(thread,xml,Microsoft,Flash,Office)