source: rtems/c/src/lib/libbsp/powerpc/shared/startup/zerobss.c @ cc981e1

4.104.114.95
Last change on this file since cc981e1 was cc981e1, checked in by Ralf Corsepius <ralf.corsepius@…>, on 08/20/08 at 05:47:08

Add missing prototypes.

  • Property mode set to 100644
File size: 937 bytes
Line 
1/*
2 *  zero the various bss areas.
3 *
4 *  COPYRIGHT (c) 1989-1998.
5 *  On-Line Applications Research Corporation (OAR).
6 *
7 *  The license and distribution terms for this file may be
8 *  found in the file LICENSE in this distribution or at
9 *  http://www.rtems.com/license/LICENSE.
10 *
11 *  Modified to support the MCP750.
12 *  Modifications Copyright (C) 1999 Eric Valette. valette@crf.canon.fr
13 *
14 *  $Id$
15 */
16
17#include <string.h>
18
19void zero_bss(void)
20{
21  /* prevent these from being accessed in the short data areas */
22  extern unsigned long __bss_start[], __SBSS_START__[], __SBSS_END__[];
23  extern unsigned long __SBSS2_START__[], __SBSS2_END__[];
24  extern unsigned long __bss_end[];
25  memset(__SBSS_START__, 0, ((unsigned) __SBSS_END__) - ((unsigned)__SBSS_START__));
26  memset(__SBSS2_START__, 0, ((unsigned) __SBSS2_END__) - ((unsigned)__SBSS2_START__));
27  memset(__bss_start, 0, ((unsigned) __bss_end) - ((unsigned)__bss_start));
28}
Note: See TracBrowser for help on using the repository browser.