HI Ian
Like you, our company has used HSC12X for years and I am getting to grips with Kinetis for a new project (specifically the KL26).
As you noted, there is no direct equivalent of the #pragma DATA_SEG.
The downside of the method you have used is that you have to insert the __attribute__ ((section(".mydata"))) statement into every declaration for constants.
The alternative is to use the linker file to put all constant data from a given source file into the specified memory area as follows:
1. Put your constant data into a separate source file. In my project, it's called "changer_data.c"
It can be defined simply as "const byte ramFlashCodes[4];" etc.
2. in the MEMORY{} block define a segment of memory where the data will be stored.
E.g. m_changer_data (R) : ORIGIN = 0x00003600, LENGTH = 0x00001000
3. In the SECTIONS{} segment, add a statement that directs all output from the source file with the constant data to this segment. E.g.
.m_changer_data_seg :
{
. = ALIGN(4);
*changer_data.o (.rodata .rodata*)
. = ALIGN(4);
} > m_changer_data
This will take all the compiled output from "changer_data.c" and link it into the m_changer_data area of memory.
I got this from another post by Eric Styger at Putting Code of Files into Special Section with the GNU Linker | MCU on Eclipse
Hope this helps