Ignore:
Timestamp:
Apr 22, 2014, 7:45:39 AM (7 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, 5, master
Children:
a531683
Parents:
e2782684
git-author:
Sebastian Huber <sebastian.huber@…> (04/22/14 07:45:39)
git-committer:
Sebastian Huber <sebastian.huber@…> (04/22/14 07:51:17)
Message:

bsps: Fix TLS support in linker command files

The TLS section symbols had wrong values in case of an empty TLS data
section and a nonempty TLS BSS section.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/haleakala/startup/linkcmds

    re2782684 rd60e760  
    155155
    156156  _TLS_Data_size = _TLS_Data_end - _TLS_Data_begin;
     157  _TLS_Data_begin = _TLS_Data_size != 0 ? _TLS_Data_begin : _TLS_BSS_begin;
     158  _TLS_Data_end = _TLS_Data_size != 0 ? _TLS_Data_end : _TLS_BSS_begin;
    157159  _TLS_BSS_size = _TLS_BSS_end - _TLS_BSS_begin;
    158160  _TLS_Size = _TLS_BSS_end - _TLS_Data_begin;
    159   _TLS_Alignment = ALIGNOF (.tdata);
     161  _TLS_Alignment = MAX (ALIGNOF (.tdata), ALIGNOF (.tbss));
    160162
    161163  .jcr : { KEEP (*(.jcr)) } >RAM
Note: See TracChangeset for help on using the changeset viewer.