You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ma...@apache.org on 2016/11/04 20:07:38 UTC
[1/2] incubator-mynewt-core git commit: uart driver;
drop apis UART_HW_IMPL
Repository: incubator-mynewt-core
Updated Branches:
refs/heads/develop 8c76465eb -> 4adb6a179
uart driver; drop apis UART_HW_IMPL
Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/4adb6a17
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/4adb6a17
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/4adb6a17
Branch: refs/heads/develop
Commit: 4adb6a179f069f61fde70329a9d671fce602238e
Parents: 4ae8e57
Author: Marko Kiiskila <ma...@runtime.io>
Authored: Fri Nov 4 13:04:45 2016 -0700
Committer: Marko Kiiskila <ma...@runtime.io>
Committed: Fri Nov 4 13:07:24 2016 -0700
----------------------------------------------------------------------
hw/drivers/uart/pkg.yml | 1 -
hw/drivers/uart/uart_bitbang/pkg.yml | 1 -
hw/drivers/uart/uart_hal/pkg.yml | 1 -
3 files changed, 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4adb6a17/hw/drivers/uart/pkg.yml
----------------------------------------------------------------------
diff --git a/hw/drivers/uart/pkg.yml b/hw/drivers/uart/pkg.yml
index 2dcab3e..f47912c 100644
--- a/hw/drivers/uart/pkg.yml
+++ b/hw/drivers/uart/pkg.yml
@@ -24,4 +24,3 @@ pkg.homepage: "http://mynewt.apache.org/"
pkg.keywords:
pkg.deps:
pkg.req_apis:
- - UART_HW_IMPL
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4adb6a17/hw/drivers/uart/uart_bitbang/pkg.yml
----------------------------------------------------------------------
diff --git a/hw/drivers/uart/uart_bitbang/pkg.yml b/hw/drivers/uart/uart_bitbang/pkg.yml
index a3ac136..f83a8df 100644
--- a/hw/drivers/uart/uart_bitbang/pkg.yml
+++ b/hw/drivers/uart/uart_bitbang/pkg.yml
@@ -23,7 +23,6 @@ pkg.author: "Apache Mynewt <de...@mynewt.incubator.apache.org>"
pkg.homepage: "http://mynewt.apache.org/"
pkg.keywords:
pkg.apis:
- - UART_HW_IMPL
pkg.deps:
- hw/hal
- hw/drivers/uart
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4adb6a17/hw/drivers/uart/uart_hal/pkg.yml
----------------------------------------------------------------------
diff --git a/hw/drivers/uart/uart_hal/pkg.yml b/hw/drivers/uart/uart_hal/pkg.yml
index 63523ef..e1abe6a 100644
--- a/hw/drivers/uart/uart_hal/pkg.yml
+++ b/hw/drivers/uart/uart_hal/pkg.yml
@@ -23,7 +23,6 @@ pkg.author: "Apache Mynewt <de...@mynewt.incubator.apache.org>"
pkg.homepage: "http://mynewt.apache.org/"
pkg.keywords:
pkg.apis:
- - UART_HW_IMPL
pkg.deps:
- hw/hal
- hw/drivers/uart
[2/2] incubator-mynewt-core git commit: MYNEWT-403;
prefix system_start/system_reset with hal_.
Posted by ma...@apache.org.
MYNEWT-403; prefix system_start/system_reset with hal_.
Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/4ae8e579
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/4ae8e579
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/4ae8e579
Branch: refs/heads/develop
Commit: 4ae8e57946e95a55468f7f1b729b0194616d1998
Parents: 8c76465
Author: Marko Kiiskila <ma...@runtime.io>
Authored: Fri Nov 4 13:04:01 2016 -0700
Committer: Marko Kiiskila <ma...@runtime.io>
Committed: Fri Nov 4 13:07:24 2016 -0700
----------------------------------------------------------------------
apps/boot/src/boot.c | 2 +-
apps/slinky/src/main.c | 2 +-
apps/slinky_oic/src/main.c | 2 +-
boot/split/include/split/split.h | 2 +-
hw/hal/include/hal/hal_system.h | 6 +++---
hw/hal/src/hal_common.c | 2 +-
hw/mcu/native/src/hal_system.c | 2 +-
hw/mcu/nordic/nrf51xxx/src/hal_system.c | 4 ++--
hw/mcu/nordic/nrf51xxx/src/hal_system_start.c | 4 ++--
hw/mcu/nordic/nrf52xxx/src/hal_system.c | 6 +++---
hw/mcu/nordic/nrf52xxx/src/hal_system_start.c | 4 ++--
hw/mcu/nxp/MK64F12/src/hal_system.c | 6 +++---
hw/mcu/nxp/MK64F12/src/hal_system_start.c | 2 +-
hw/mcu/stm/stm32f4xx/src/hal_system.c | 6 +++---
hw/mcu/stm/stm32f4xx/src/hal_system_start.c | 2 +-
kernel/os/src/arch/cortex_m0/os_fault.c | 6 +++---
kernel/os/src/arch/cortex_m4/os_fault.c | 6 +++---
mgmt/newtmgr/nmgr_os/src/newtmgr_os.c | 2 +-
test/testutil/src/testutil.c | 2 +-
19 files changed, 34 insertions(+), 34 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/apps/boot/src/boot.c
----------------------------------------------------------------------
diff --git a/apps/boot/src/boot.c b/apps/boot/src/boot.c
index 5d0e9a9..43280c1 100755
--- a/apps/boot/src/boot.c
+++ b/apps/boot/src/boot.c
@@ -76,7 +76,7 @@ main(void)
rc = boot_go(&rsp);
assert(rc == 0);
- system_start((void *)(rsp.br_image_addr + rsp.br_hdr->ih_hdr_size));
+ hal_system_start((void *)(rsp.br_image_addr + rsp.br_hdr->ih_hdr_size));
return 0;
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/apps/slinky/src/main.c
----------------------------------------------------------------------
diff --git a/apps/slinky/src/main.c b/apps/slinky/src/main.c
index abda19c..f4da51e 100755
--- a/apps/slinky/src/main.c
+++ b/apps/slinky/src/main.c
@@ -309,7 +309,7 @@ main(int argc, char **argv)
void *entry;
rc = split_app_go(&entry, true);
if(rc == 0) {
- system_start(entry);
+ hal_system_start(entry);
}
}
#endif
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/apps/slinky_oic/src/main.c
----------------------------------------------------------------------
diff --git a/apps/slinky_oic/src/main.c b/apps/slinky_oic/src/main.c
index 1faba3c..3f31f04 100755
--- a/apps/slinky_oic/src/main.c
+++ b/apps/slinky_oic/src/main.c
@@ -299,7 +299,7 @@ main(int argc, char **argv)
void *entry;
rc = split_app_go(&entry, true);
if(rc == 0) {
- system_start(entry);
+ hal_system_start(entry);
}
}
#endif
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/boot/split/include/split/split.h
----------------------------------------------------------------------
diff --git a/boot/split/include/split/split.h b/boot/split/include/split/split.h
index 88f752c..e1341d7 100644
--- a/boot/split/include/split/split.h
+++ b/boot/split/include/split/split.h
@@ -60,7 +60,7 @@ void split_app_init(void);
* If the application is configured to be run (and valid)
* returns zero and puts the entry data into entry. NOTE:
* Entry data is not a function pointer, but a pointer
- * suitable to call system_start
+ * suitable to call hal_system_start
*
* If toBoot is true, also performs the necessary steps
* to prepare to boot. An application may set toBoot to
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/hal/include/hal/hal_system.h
----------------------------------------------------------------------
diff --git a/hw/hal/include/hal/hal_system.h b/hw/hal/include/hal/hal_system.h
index 430c9fd..9a85946 100644
--- a/hw/hal/include/hal/hal_system.h
+++ b/hw/hal/include/hal/hal_system.h
@@ -27,17 +27,17 @@ extern "C" {
/*
* System reset.
*/
-void system_reset(void) __attribute((noreturn));
+void hal_system_reset(void) __attribute((noreturn));
/*
* Called by bootloader to start loaded program.
*/
-void system_start(void *img_start) __attribute((noreturn));
+void hal_system_start(void *img_start) __attribute((noreturn));
/*
* Returns non-zero if there is a HW debugger attached.
*/
-int system_debugger_connected(void);
+int hal_debugger_connected(void);
#ifdef __cplusplus
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/hal/src/hal_common.c
----------------------------------------------------------------------
diff --git a/hw/hal/src/hal_common.c b/hw/hal/src/hal_common.c
index e1d64b9..c8e61c8 100644
--- a/hw/hal/src/hal_common.c
+++ b/hw/hal/src/hal_common.c
@@ -24,5 +24,5 @@ void _exit(int status);
void
_exit(int status)
{
- system_reset();
+ hal_system_reset();
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/native/src/hal_system.c
----------------------------------------------------------------------
diff --git a/hw/mcu/native/src/hal_system.c b/hw/mcu/native/src/hal_system.c
index fca9db5..ca16433 100644
--- a/hw/mcu/native/src/hal_system.c
+++ b/hw/mcu/native/src/hal_system.c
@@ -25,7 +25,7 @@
#include "mcu/mcu_sim.h"
void
-system_reset(void)
+hal_system_reset(void)
{
while(1);
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nordic/nrf51xxx/src/hal_system.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nordic/nrf51xxx/src/hal_system.c b/hw/mcu/nordic/nrf51xxx/src/hal_system.c
index 66864ea..62379a7 100644
--- a/hw/mcu/nordic/nrf51xxx/src/hal_system.c
+++ b/hw/mcu/nordic/nrf51xxx/src/hal_system.c
@@ -21,7 +21,7 @@
#include "hal/hal_system.h"
void
-system_reset(void)
+hal_system_reset(void)
{
while (1) {
NVIC_SystemReset();
@@ -29,7 +29,7 @@ system_reset(void)
}
int
-system_debugger_connected(void)
+hal_debugger_connected(void)
{
/* XXX is there a way? */
return 0;
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nordic/nrf51xxx/src/hal_system_start.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nordic/nrf51xxx/src/hal_system_start.c b/hw/mcu/nordic/nrf51xxx/src/hal_system_start.c
index 66a8cae..9152edc 100644
--- a/hw/mcu/nordic/nrf51xxx/src/hal_system_start.c
+++ b/hw/mcu/nordic/nrf51xxx/src/hal_system_start.c
@@ -6,7 +6,7 @@
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
@@ -27,7 +27,7 @@
* @param hdr The header for the image to boot.
*/
void
-system_start(void *img_start)
+hal_system_start(void *img_start)
{
typedef void jump_fn(void);
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nordic/nrf52xxx/src/hal_system.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nordic/nrf52xxx/src/hal_system.c b/hw/mcu/nordic/nrf52xxx/src/hal_system.c
index e9ce365..b82a7a4 100644
--- a/hw/mcu/nordic/nrf52xxx/src/hal_system.c
+++ b/hw/mcu/nordic/nrf52xxx/src/hal_system.c
@@ -21,10 +21,10 @@
#include "hal/hal_system.h"
void
-system_reset(void)
+hal_system_reset(void)
{
while (1) {
- if (system_debugger_connected()) {
+ if (hal_debugger_connected()) {
/*
* If debugger is attached, breakpoint here.
*/
@@ -35,7 +35,7 @@ system_reset(void)
}
int
-system_debugger_connected(void)
+hal_debugger_connected(void)
{
return CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk;
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nordic/nrf52xxx/src/hal_system_start.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nordic/nrf52xxx/src/hal_system_start.c b/hw/mcu/nordic/nrf52xxx/src/hal_system_start.c
index 9a7c5b2..4a9e0fa 100644
--- a/hw/mcu/nordic/nrf52xxx/src/hal_system_start.c
+++ b/hw/mcu/nordic/nrf52xxx/src/hal_system_start.c
@@ -6,7 +6,7 @@
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
@@ -27,7 +27,7 @@
* @param hdr The header for the image to boot.
*/
void
-system_start(void *img_start)
+hal_system_start(void *img_start)
{
typedef void jump_fn(void);
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nxp/MK64F12/src/hal_system.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nxp/MK64F12/src/hal_system.c b/hw/mcu/nxp/MK64F12/src/hal_system.c
index 673917f..3cd7511 100644
--- a/hw/mcu/nxp/MK64F12/src/hal_system.c
+++ b/hw/mcu/nxp/MK64F12/src/hal_system.c
@@ -20,15 +20,15 @@
#include <mcu/cortex_m4.h>
#include "hal/hal_system.h"
-int system_debugger_connected(void)
+int hal_debugger_connected(void)
{
return CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk;
}
-void system_reset(void)
+void hal_system_reset(void)
{
while (1) {
- if (system_debugger_connected()) {
+ if (hal_debugger_connected()) {
/*
* If debugger is attached, breakpoint here.
*/
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/nxp/MK64F12/src/hal_system_start.c
----------------------------------------------------------------------
diff --git a/hw/mcu/nxp/MK64F12/src/hal_system_start.c b/hw/mcu/nxp/MK64F12/src/hal_system_start.c
index 31a4a62..fc63e46 100644
--- a/hw/mcu/nxp/MK64F12/src/hal_system_start.c
+++ b/hw/mcu/nxp/MK64F12/src/hal_system_start.c
@@ -27,7 +27,7 @@
* @param hdr The header for the image to boot.
*/
void
-system_start(void *img_start)
+hal_system_start(void *img_start)
{
/* Turn off interrupts. */
__disable_irq();
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/stm/stm32f4xx/src/hal_system.c
----------------------------------------------------------------------
diff --git a/hw/mcu/stm/stm32f4xx/src/hal_system.c b/hw/mcu/stm/stm32f4xx/src/hal_system.c
index a27606f..2167830 100644
--- a/hw/mcu/stm/stm32f4xx/src/hal_system.c
+++ b/hw/mcu/stm/stm32f4xx/src/hal_system.c
@@ -23,10 +23,10 @@
#include "stm32f4xx_hal_def.h"
void
-system_reset(void)
+hal_system_reset(void)
{
while (1) {
- if (system_debugger_connected()) {
+ if (hal_debugger_connected()) {
/*
* If debugger is attached, breakpoint here.
*/
@@ -37,7 +37,7 @@ system_reset(void)
}
int
-system_debugger_connected(void)
+hal_debugger_connected(void)
{
return CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk;
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/hw/mcu/stm/stm32f4xx/src/hal_system_start.c
----------------------------------------------------------------------
diff --git a/hw/mcu/stm/stm32f4xx/src/hal_system_start.c b/hw/mcu/stm/stm32f4xx/src/hal_system_start.c
index ddfe8eb..42c85a0 100644
--- a/hw/mcu/stm/stm32f4xx/src/hal_system_start.c
+++ b/hw/mcu/stm/stm32f4xx/src/hal_system_start.c
@@ -28,7 +28,7 @@
* @param hdr The header for the image to boot.
*/
void
-system_start(void *img_start)
+hal_system_start(void *img_start)
{
typedef void jump_fn(void);
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/kernel/os/src/arch/cortex_m0/os_fault.c
----------------------------------------------------------------------
diff --git a/kernel/os/src/arch/cortex_m0/os_fault.c b/kernel/os/src/arch/cortex_m0/os_fault.c
index 8c89144..952ef69 100644
--- a/kernel/os/src/arch/cortex_m0/os_fault.c
+++ b/kernel/os/src/arch/cortex_m0/os_fault.c
@@ -119,7 +119,7 @@ __assert_func(const char *file, int line, const char *func, const char *e)
(void)sr;
console_blocking_mode();
console_printf("Assert %s; failed in %s:%d\n", e ? e : "", file, line);
- if (system_debugger_connected()) {
+ if (hal_debugger_connected()) {
/*
* If debugger is attached, breakpoint before the trap.
*/
@@ -127,7 +127,7 @@ __assert_func(const char *file, int line, const char *func, const char *e)
}
SCB->ICSR = SCB_ICSR_NMIPENDSET_Msk;
/* Exception happens right away. Next line not executed. */
- system_reset();
+ hal_system_reset();
}
void
@@ -153,6 +153,6 @@ os_default_irq(struct trap_frame *tf)
trap_to_coredump(tf, ®s);
coredump_dump(®s, sizeof(regs));
#endif
- system_reset();
+ hal_system_reset();
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/kernel/os/src/arch/cortex_m4/os_fault.c
----------------------------------------------------------------------
diff --git a/kernel/os/src/arch/cortex_m4/os_fault.c b/kernel/os/src/arch/cortex_m4/os_fault.c
index 1f7e2fa..ad60ac8 100644
--- a/kernel/os/src/arch/cortex_m4/os_fault.c
+++ b/kernel/os/src/arch/cortex_m4/os_fault.c
@@ -119,7 +119,7 @@ __assert_func(const char *file, int line, const char *func, const char *e)
(void)sr;
console_blocking_mode();
console_printf("Assert %s; failed in %s:%d\n", e ? e : "", file, line);
- if (system_debugger_connected()) {
+ if (hal_debugger_connected()) {
/*
* If debugger is attached, breakpoint before the trap.
*/
@@ -127,7 +127,7 @@ __assert_func(const char *file, int line, const char *func, const char *e)
}
SCB->ICSR = SCB_ICSR_NMIPENDSET_Msk;
asm("isb");
- system_reset();
+ hal_system_reset();
}
void
@@ -156,5 +156,5 @@ os_default_irq(struct trap_frame *tf)
trap_to_coredump(tf, ®s);
coredump_dump(®s, sizeof(regs));
#endif
- system_reset();
+ hal_system_reset();
}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/mgmt/newtmgr/nmgr_os/src/newtmgr_os.c
----------------------------------------------------------------------
diff --git a/mgmt/newtmgr/nmgr_os/src/newtmgr_os.c b/mgmt/newtmgr/nmgr_os/src/newtmgr_os.c
index ae8cd4e..1dddcc3 100644
--- a/mgmt/newtmgr/nmgr_os/src/newtmgr_os.c
+++ b/mgmt/newtmgr/nmgr_os/src/newtmgr_os.c
@@ -315,7 +315,7 @@ out:
static void
nmgr_reset_tmo(struct os_event *ev)
{
- system_reset();
+ hal_system_reset();
}
static int
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4ae8e579/test/testutil/src/testutil.c
----------------------------------------------------------------------
diff --git a/test/testutil/src/testutil.c b/test/testutil/src/testutil.c
index 1c7a29c..8a560db 100644
--- a/test/testutil/src/testutil.c
+++ b/test/testutil/src/testutil.c
@@ -53,7 +53,7 @@ tu_arch_restart(void)
os_arch_os_stop();
tu_case_abort();
#else
- system_reset();
+ hal_system_reset();
#endif
}