Hi,
I have a piece of bootloading code that is written in assembler and runs from flash. Its an adaptation of the provided code in the application note "SPRA999A1 - Creating a Second-Level Bootloader for FLASH Bootloading on TMS320C6000 Platform With Code Composer Studio".
We've added in CRC checking functionality into the assembler, using a lookup table for the crc table. The lookup table just contains data which is declared as follows in the middle of regular assembly code,
(....assembly code...)
(jump over "data" space")
crc_table:
.ushort 0x1234, 0x1223, 0x2334
.ushort 0x8765, 0x9876, 0xABCD
.ushort 0x1231...etc etc etc
(assembly code)
The problem is that it gives the following warning on compilation:
WARNING! at line 1038: [W9999] Placing data in a code section
(.bootload) is discouraged.
The data may be interpreted as
code. This section will not be
compressed.
The code works but the solution to just jump over the data table is not very elegant and we have a policy not to have any warnings in our projects. Does anyone have any ideas of how to place this crc table in flash memory, but not in the code section?
We also use the linker cmd file generated for us by the Configuration Tool., then the Hex Conversion Util (hex6x) to create the intel hex file with the –boot option to create a boot table.
I have tried making a new section purely for the table called .crctable in the assembly file and the relocating that into flash, but I can't get it to work, it always places the section into the Boot Table for relocation. How can I exclude it from the boot table without containing it in .bootload section?
CONTENTS: 42000000..42000cbf .bootload
42000cc0..4203ffff FILL = 00000000
42040000..420a9d37 BOOT TABLE
.text : btad=42046368 dest=86000000 size=00053a60
......etc....
.const : btad=420a6800 dest=86092140 size=0000302e
......etc....
.crctable : btad=420a9b2c dest=42001500 size=00000200
420a9d38..420bffff FILL = 00000000
All I want is the constant data to be in the .bootload section, but the compiler mustn't complain about it. Or even better just after the .bootload section.
Any help or ideas would be really appreciated!