source: trunk/libs/newlib/src/libgloss/or1k/boards/tmpl.S @ 444

Last change on this file since 444 was 444, checked in by satin@…, 6 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 1.8 KB
Line 
1/* tmpl.S -- Template for new boards.
2 *
3 * Copyright (c) 2014 Authors
4 *
5 * Contributor Stefan Wallentowitz <stefan.wallentowitz@saunalahti.fi>
6 *
7 * The authors hereby grant permission to use, copy, modify, distribute,
8 * and license this software and its documentation for any purpose, provided
9 * that existing copyright notices are retained in all copies and that this
10 * notice is included verbatim in any distributions. No written agreement,
11 * license, or royalty fee is required for any of the authorized uses.
12 * Modifications to this software may be copyrighted by their authors
13 * and need not follow the licensing terms described here, provided that
14 * the new terms are clearly indicated on the first page of each file where
15 * they apply.
16 */
17
18#include "../include/or1k-asm.h"
19#include "../include/or1k-nop.h"
20
21/*
22 * Define symbols to be used during startup - file is linked at compile time
23 *
24 */
25.weak _or1k_board_mem_base
26.weak _or1k_board_mem_size
27.weak _or1k_board_clk_freq
28
29// TODO: set memory base here
30_or1k_board_mem_base:   .long   0x0
31// TODO: set memory size here
32_or1k_board_mem_size:   .long   0x0
33
34// TODO: set board clock frequency here
35_or1k_board_clk_freq:   .long   50000000
36
37// TODO: UART configuration
38.weak _or1k_board_uart_base
39.weak _or1k_board_uart_baud
40.weak _or1k_board_uart_IRQ
41_or1k_board_uart_base:  .long   0x0
42_or1k_board_uart_baud:  .long   0
43_or1k_board_uart_IRQ:   .long   0
44
45// TODO: Board exit function, default: loop
46.weak _or1k_board_exit
47_or1k_board_exit:
48        l.nop OR1K_NOP_EXIT_SILENT
49.Lexitloop:
50        OR1K_DELAYED_NOP(l.j .Lexitloop)
51
52// TODO: Early initialization (if really needed!)
53.global _or1k_board_init_early
54_or1k_board_init_early:
55        OR1K_DELAYED_NOP(l.jr r9)
56
57// TODO: Board initialization
58.weak _or1k_board_init
59_or1k_board_init:
60        OR1K_DELAYED_NOP(l.jr r9)
Note: See TracBrowser for help on using the repository browser.