瀏覽代碼

rt_hw_cpu_reset: remove all other rt_weak

Meco Man 1 年之前
父節點
當前提交
cb810dfe75

+ 1 - 1
bsp/raspberry-pico/libcpu/cpuport.c

@@ -278,7 +278,7 @@ void rt_hw_hard_fault_exception(struct exception_stack_frame *contex)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR  = SCB_RESET_VALUE;//((0x5FAUL << SCB_AIRCR_VECTKEY_Pos) |SCB_AIRCR_SYSRESETREQ_Msk);
 }

+ 1 - 1
libcpu/arm/AT91SAM7S/cpu.c

@@ -20,7 +20,7 @@
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 }
 

+ 1 - 1
libcpu/arm/AT91SAM7X/cpu.c

@@ -20,7 +20,7 @@
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 }
 

+ 1 - 1
libcpu/arm/arm926/cpuport.c

@@ -146,7 +146,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 
     rt_kprintf("Restarting system...\n");

+ 1 - 1
libcpu/arm/armv6/cpuport.c

@@ -147,7 +147,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 
     rt_kprintf("Restarting system...\n");

+ 1 - 1
libcpu/arm/cortex-m0/cpuport.c

@@ -131,7 +131,7 @@ void rt_hw_hard_fault_exception(struct exception_stack_frame *contex)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR  = SCB_RESET_VALUE;//((0x5FAUL << SCB_AIRCR_VECTKEY_Pos) |SCB_AIRCR_SYSRESETREQ_Msk);
 }

+ 1 - 1
libcpu/arm/cortex-m23/cpuport.c

@@ -132,7 +132,7 @@ void rt_hw_hard_fault_exception(struct exception_stack_frame *contex)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR  = SCB_RESET_VALUE;//((0x5FAUL << SCB_AIRCR_VECTKEY_Pos) |SCB_AIRCR_SYSRESETREQ_Msk);
 }

+ 1 - 1
libcpu/arm/cortex-m3/cpuport.c

@@ -356,7 +356,7 @@ rt_weak void rt_hw_cpu_shutdown(void)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR = SCB_RESET_VALUE;
 }

+ 1 - 1
libcpu/arm/cortex-m33/cpuport.c

@@ -498,7 +498,7 @@ rt_weak void rt_hw_cpu_shutdown(void)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR = SCB_RESET_VALUE;
 }

+ 1 - 1
libcpu/arm/cortex-m4/cpuport.c

@@ -441,7 +441,7 @@ rt_weak void rt_hw_cpu_shutdown(void)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR = SCB_RESET_VALUE;
 }

+ 1 - 1
libcpu/arm/cortex-m7/cpuport.c

@@ -440,7 +440,7 @@ rt_weak void rt_hw_cpu_shutdown(void)
 /**
  * reset CPU
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     SCB_AIRCR = SCB_RESET_VALUE;
 }

+ 1 - 1
libcpu/arm/cortex-r4/cpu.c

@@ -20,7 +20,7 @@
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 }
 

+ 1 - 1
libcpu/arm/dm36x/cpuport.c

@@ -145,7 +145,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 
     rt_kprintf("Restarting system...\n");

+ 1 - 1
libcpu/arm/lpc214x/cpuport.c

@@ -163,7 +163,7 @@ rt_isr_handler_t rt_hw_interrupt_install(int vector, rt_isr_handler_t handler,
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
 }
 

+ 1 - 1
libcpu/arm/lpc24xx/cpu.c

@@ -20,7 +20,7 @@
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 }
 

+ 1 - 1
libcpu/arm/s3c24x0/cpu.c

@@ -148,7 +148,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
     /* Disable all interrupt except the WDT */
     INTMSK = (~((rt_uint32_t)1 << INTWDT));

+ 1 - 1
libcpu/arm/s3c44b0/cpu.c

@@ -100,7 +100,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 }
 

+ 1 - 1
libcpu/arm/sep4020/cpu.c

@@ -152,7 +152,7 @@ rt_base_t rt_hw_cpu_dcache_status()
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 
     /* enable watchdog */

+ 0 - 9
libcpu/avr32/uc3/cpu.c

@@ -15,15 +15,6 @@
  */
 /*@{*/
 
-/**
- * reset cpu by dog's time-out
- *
- */
-rt_weak void rt_hw_cpu_reset()
-{
-    /*NOTREACHED*/
-}
-
 /**
  *  shutdown CPU
  *

+ 1 - 1
libcpu/mips/gs232/cpuport.c

@@ -23,7 +23,7 @@
  * this function will reset CPU
  *
  */
-rt_weak void rt_hw_cpu_reset(void)
+void rt_hw_cpu_reset(void)
 {
     /* open the watch-dog */
     WDT_EN = 0x01;      /* watch dog enable */

+ 1 - 1
libcpu/unicore32/sep6200/cpu.c

@@ -245,7 +245,7 @@ static void sep6200_poweroff(void)
  * reset cpu by dog's time-out
  *
  */
-rt_weak void rt_hw_cpu_reset()
+void rt_hw_cpu_reset()
 {
 
     rt_kprintf("Soft reset, Restarting system...\n");

+ 0 - 8
libcpu/xilinx/microblaze/cpu.c

@@ -10,14 +10,6 @@
 
 #include <rtthread.h>
 
-/**
- * this function will reset CPU
- *
- */
-rt_weak void rt_hw_cpu_reset()
-{
-}
-
 /**
  * this function will shutdown CPU
  *

+ 7 - 7
src/kservice.c

@@ -66,20 +66,20 @@ static rt_device_t _console_device = RT_NULL;
 rt_weak void rt_hw_us_delay(rt_uint32_t us)
 {
     (void) us;
-    LOG_D("rt_hw_us_delay() doesn't support for this board."
+    LOG_W("rt_hw_us_delay() doesn't support for this board."
         "Please consider implementing rt_hw_us_delay() in another file.");
 }
 
-rt_weak const char *rt_hw_cpu_arch(void)
+rt_weak void rt_hw_cpu_reset(void)
 {
-    return "unknown";
+    LOG_W("rt_hw_cpu_reset() doesn't support for this board."
+        "Please consider implementing rt_hw_cpu_reset() in another file.");
+    return;
 }
 
-rt_weak void rt_hw_cpu_reset(void)
+rt_weak const char *rt_hw_cpu_arch(void)
 {
-    LOG_D("rt_hw_cpu_reset() doesn't support for this board."
-        "Please consider implementing rt_hw_cpu_reset() in another file.");
-    return ;
+    return "unknown";
 }
 
 static const char* rt_errno_strs[] =