summaryrefslogtreecommitdiff
path: root/bsp/gd32vf103v-eval/libraries/n22/env_Eclipse/init.c
blob: 4a959cd9a6908630751b0b4c61d53b8401c3d961 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//See LICENSE for license details.
#include <gd32vf103.h>
#include <stdint.h>
#include <stdio.h>
#include <unistd.h>
#include "riscv_encoding.h"
#include "n22_func.h"

void _init() {

}

void _fini() {
}

void riscv_clock_init(void) {
    SystemInit();

    //ECLIC init
    eclic_init(ECLIC_NUM_INTERRUPTS);
    eclic_mode_enable();
    set_csr(mstatus, MSTATUS_MIE);

}