Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
wwsmg1
rt-thread
提交
bcae1965
R
rt-thread
项目概览
wwsmg1
/
rt-thread
与 Fork 源项目一致
Fork自
RT-Thread / rt-thread
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rt-thread
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
bcae1965
编写于
4月 17, 2020
作者:
B
bigmagic
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[bsp\raspi4]move io to `iomap.h`
上级
098eccc0
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
21 addition
and
19 deletion
+21
-19
bsp/raspberry-pi/raspi4/driver/board.c
bsp/raspberry-pi/raspi4/driver/board.c
+2
-6
bsp/raspberry-pi/raspi4/driver/board.h
bsp/raspberry-pi/raspi4/driver/board.h
+1
-1
bsp/raspberry-pi/raspi4/driver/drv_gpio.h
bsp/raspberry-pi/raspi4/driver/drv_gpio.h
+0
-2
bsp/raspberry-pi/raspi4/driver/drv_uart.c
bsp/raspberry-pi/raspi4/driver/drv_uart.c
+0
-6
bsp/raspberry-pi/raspi4/driver/drv_uart.h
bsp/raspberry-pi/raspi4/driver/drv_uart.h
+0
-1
bsp/raspberry-pi/raspi4/driver/iomap.h
bsp/raspberry-pi/raspi4/driver/iomap.h
+18
-3
未找到文件。
bsp/raspberry-pi/raspi4/driver/board.c
浏览文件 @
bcae1965
...
...
@@ -18,10 +18,6 @@
#include "mmu.h"
static
rt_uint64_t
timerStep
;
// 0x40, 0x44, 0x48, 0x4c: Core 0~3 Timers interrupt control
#define CORE0_TIMER_IRQ_CTRL HWREG32(0xFF800040)
#define TIMER_IRQ 30
#define NON_SECURE_TIMER_IRQ (1 << 1)
int
rt_hw_get_gtimer_frq
(
void
);
void
rt_hw_set_gtimer_val
(
rt_uint64_t
value
);
...
...
@@ -29,7 +25,7 @@ int rt_hw_get_gtimer_val(void);
int
rt_hw_get_cntpct_val
(
void
);
void
rt_hw_gtimer_enable
(
void
);
void
core0_timer_enable_interrupt_controller
()
void
core0_timer_enable_interrupt_controller
(
void
)
{
CORE0_TIMER_IRQ_CTRL
|=
NON_SECURE_TIMER_IRQ
;
}
...
...
@@ -94,4 +90,4 @@ void rt_hw_board_init(void)
#ifdef RT_USING_COMPONENTS_INIT
rt_components_board_init
();
#endif
}
\ No newline at end of file
}
bsp/raspberry-pi/raspi4/driver/board.h
浏览文件 @
bcae1965
...
...
@@ -12,6 +12,7 @@
#define BOARD_H__
#include <stdint.h>
#include "iomap.h"
extern
unsigned
char
__bss_start
;
extern
unsigned
char
__bss_end
;
...
...
@@ -22,4 +23,3 @@ extern unsigned char __bss_end;
void
rt_hw_board_init
(
void
);
#endif
bsp/raspberry-pi/raspi4/driver/drv_gpio.h
浏览文件 @
bcae1965
...
...
@@ -17,8 +17,6 @@
#include "board.h"
#include "interrupt.h"
#define GPIO_BASE (0xFE000000 + 0x00200000)
#define GPIO_REG_GPFSEL0(BASE) HWREG32(BASE + 0x00)
#define GPIO_REG_GPFSEL1(BASE) HWREG32(BASE + 0x04)
#define GPIO_REG_GPFSEL2(BASE) HWREG32(BASE + 0x08)
...
...
bsp/raspberry-pi/raspi4/driver/drv_uart.c
浏览文件 @
bcae1965
...
...
@@ -16,12 +16,6 @@
#include "drv_uart.h"
#include "drv_gpio.h"
#define UART0_BASE (0xFE000000 + 0x00201000)
#define PL011_BASE UART0_BASE
#define IRQ_PL011 (121 + 32)
#define UART_REFERENCE_CLOCK 48000000
struct
hw_uart_device
{
rt_ubase_t
hw_base
;
...
...
bsp/raspberry-pi/raspi4/driver/drv_uart.h
浏览文件 @
bcae1965
...
...
@@ -81,4 +81,3 @@
int
rt_hw_uart_init
(
void
);
#endif
/* DRV_UART_H__ */
bsp/raspberry-pi/raspi4/driver/iomap.h
浏览文件 @
bcae1965
#ifndef __RASPI4_H__
#define __RASPI4_H__
#define ARM_GIC_NR_IRQS 512
#define INTC_BASE 0xff800000
//gpio
#define GPIO_BASE (0xFE000000 + 0x00200000)
//uart
#define UART0_BASE (0xFE000000 + 0x00201000)
#define PL011_BASE UART0_BASE
#define IRQ_PL011 (121 + 32)
#define UART_REFERENCE_CLOCK (48000000)
// 0x40, 0x44, 0x48, 0x4c: Core 0~3 Timers interrupt control
#define CORE0_TIMER_IRQ_CTRL HWREG32(0xFF800040)
#define TIMER_IRQ 30
#define NON_SECURE_TIMER_IRQ (1 << 1)
//gic max
#define ARM_GIC_NR_IRQS (512)
#define INTC_BASE (0xff800000)
#define GIC_V2_DISTRIBUTOR_BASE (INTC_BASE + 0x00041000)
#define GIC_V2_CPU_INTERFACE_BASE (INTC_BASE + 0x00042000)
#define GIC_V2_HYPERVISOR_BASE (INTC_BASE + 0x00044000)
...
...
@@ -11,4 +26,4 @@
#define GIC_PL400_DISTRIBUTOR_PPTR GIC_V2_DISTRIBUTOR_BASE
#define GIC_PL400_CONTROLLER_PPTR GIC_V2_CPU_INTERFACE_BASE
#endif
\ No newline at end of file
#endif
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录