From c84887d021bc0d66352ead42366bd45868e1e4df Mon Sep 17 00:00:00 2001 From: heyuanjie87 Date: Wed, 2 Sep 2015 22:00:24 +0800 Subject: 加入定时器设备 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- include/rtdef.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/rtdef.h b/include/rtdef.h index 2587df9c41..eda5d5da79 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -759,7 +759,8 @@ enum rt_device_class_type RT_Device_Class_Pipe, /**< Pipe device */ RT_Device_Class_Portal, /**< Portal device */ RT_Device_Class_Miscellaneous, /**< Miscellaneous device */ - RT_Device_Class_Unknown /**< unknown device */ + RT_Device_Class_HwTimer, /**< Hardware timer device */ + RT_Device_Class_Unknown /**< unknown device */ }; /** -- cgit v1.3.1 From 8f9bda579a4027cd88e44d6dcdfd61fc5d667a6f Mon Sep 17 00:00:00 2001 From: heyuanjie87 Date: Sun, 6 Sep 2015 15:18:15 +0800 Subject: 定义Timer设备类 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/finsh/cmd.c | 2 +- include/rtdef.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/components/finsh/cmd.c b/components/finsh/cmd.c index 6e2ca631e3..c42b412f23 100644 --- a/components/finsh/cmd.c +++ b/components/finsh/cmd.c @@ -467,8 +467,8 @@ static long _list_device(struct rt_list_node *list) "PM Pseudo Device", "Pipe", "Portal Device", + "Timer Device", "Miscellaneous Device", - "Hardware Timer Device", "Unknown" }; diff --git a/include/rtdef.h b/include/rtdef.h index eda5d5da79..a3dad27989 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -758,8 +758,8 @@ enum rt_device_class_type RT_Device_Class_PM, /**< PM pseudo device */ RT_Device_Class_Pipe, /**< Pipe device */ RT_Device_Class_Portal, /**< Portal device */ - RT_Device_Class_Miscellaneous, /**< Miscellaneous device */ - RT_Device_Class_HwTimer, /**< Hardware timer device */ + RT_Device_Class_Timer, /**< Timer device */ + RT_Device_Class_Miscellaneous, /**< Miscellaneous device */ RT_Device_Class_Unknown /**< unknown device */ }; -- cgit v1.3.1 From 7dfac0f78e546842b276806538a36066d61bd974 Mon Sep 17 00:00:00 2001 From: Bernard Xiong Date: Tue, 15 Sep 2015 12:11:07 +0000 Subject: rename .name section to .rodata.name section --- components/finsh/finsh.h | 8 ++++---- include/rtm.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/components/finsh/finsh.h b/components/finsh/finsh.h index 4f3a887bc3..71b788f9f3 100644 --- a/components/finsh/finsh.h +++ b/components/finsh/finsh.h @@ -229,8 +229,8 @@ struct finsh_sysvar* finsh_sysvar_lookup(const char* name); #else #define FINSH_FUNCTION_EXPORT_CMD(name, cmd, desc) \ - const char __fsym_##cmd##_name[] SECTION(".name") = #cmd; \ - const char __fsym_##cmd##_desc[] SECTION(".name") = #desc; \ + const char __fsym_##cmd##_name[] SECTION(".rodata.name") = #cmd; \ + const char __fsym_##cmd##_desc[] SECTION(".rodata.name") = #desc; \ const struct finsh_syscall __fsym_##cmd SECTION("FSymTab")= \ { \ __fsym_##cmd##_name, \ @@ -239,8 +239,8 @@ struct finsh_sysvar* finsh_sysvar_lookup(const char* name); }; #define FINSH_VAR_EXPORT(name, type, desc) \ - const char __vsym_##name##_name[] SECTION(".name") = #name; \ - const char __vsym_##name##_desc[] SECTION(".name") = #desc; \ + const char __vsym_##name##_name[] SECTION(".rodata.name") = #name; \ + const char __vsym_##name##_desc[] SECTION(".rodata.name") = #desc; \ const struct finsh_sysvar __vsym_##name SECTION("VSymTab")= \ { \ __vsym_##name##_name, \ diff --git a/include/rtm.h b/include/rtm.h index e888153a14..05419e4420 100644 --- a/include/rtm.h +++ b/include/rtm.h @@ -42,7 +42,7 @@ __declspec(allocate("RTMSymTab$f"))const char __rtmsym_##symbol##_name[] = "__vs #else #define RTM_EXPORT(symbol) \ -const char __rtmsym_##symbol##_name[] SECTION(".name") = #symbol; \ +const char __rtmsym_##symbol##_name[] SECTION(".rodata.name") = #symbol; \ const struct rt_module_symtab __rtmsym_##symbol SECTION("RTMSymTab")= \ { \ (void *)&symbol, \ -- cgit v1.3.1