| 1 | /* Copyright (c) 2012-2013 Red Hat Incorporated. |
|---|
| 2 | All rights reserved. |
|---|
| 3 | |
|---|
| 4 | Redistribution and use in source and binary forms, with or without |
|---|
| 5 | modification, are permitted provided that the following conditions |
|---|
| 6 | are met: |
|---|
| 7 | |
|---|
| 8 | Redistributions of source code must retain the above copyright |
|---|
| 9 | notice, this list of conditions and the following disclaimer. |
|---|
| 10 | |
|---|
| 11 | Redistributions in binary form must reproduce the above copyright |
|---|
| 12 | notice, this list of conditions and the following disclaimer in the |
|---|
| 13 | documentation and/or other materials provided with the distribution. |
|---|
| 14 | |
|---|
| 15 | The name of Red Hat Incorporated may not be used to endorse |
|---|
| 16 | or promote products derived from this software without specific |
|---|
| 17 | prior written permission. |
|---|
| 18 | |
|---|
| 19 | This software is provided by the copyright holders and contributors |
|---|
| 20 | "AS IS" and any express or implied warranties, including, but not |
|---|
| 21 | limited to, the implied warranties of merchantability and fitness for |
|---|
| 22 | a particular purpose are disclaimed. In no event shall Red Hat |
|---|
| 23 | incorporated be liable for any direct, indirect, incidental, special, |
|---|
| 24 | exemplary, or consequential damages (including, but not limited to, |
|---|
| 25 | procurement of substitute goods or services; loss of use, data, or |
|---|
| 26 | profits; or business interruption) however caused and on any theory of |
|---|
| 27 | liability, whether in contract, strict liability, or tort (including |
|---|
| 28 | negligence or otherwise) arising in any way out of the use of this |
|---|
| 29 | software, even if advised of the possibility of such damage. */ |
|---|
| 30 | |
|---|
| 31 | #include "memmodel.h" |
|---|
| 32 | |
|---|
| 33 | .section ".crt_bss", "ax", @progbits |
|---|
| 34 | |
|---|
| 35 | .global __crt0_init_bss |
|---|
| 36 | __crt0_init_bss: |
|---|
| 37 | |
|---|
| 38 | mov_ #__bssstart, R12 |
|---|
| 39 | clr.w R13 |
|---|
| 40 | mov.w #__bsssize, R14 |
|---|
| 41 | #ifdef __MSP430X_LARGE__ |
|---|
| 42 | clr.w R15 ; We assume that __bsssize is never > 64M |
|---|
| 43 | #endif |
|---|
| 44 | call_ #memset |
|---|