浏览代码

将rt_soft_rtc_init设为私有函数

Meco Man 4 年之前
父节点
当前提交
43e9aec85e
共有 2 个文件被更改,包括 1 次插入3 次删除
  1. 0 2
      components/drivers/rtc/README.md
  2. 1 1
      components/drivers/rtc/soft_rtc.c

+ 0 - 2
components/drivers/rtc/README.md

@@ -76,5 +76,3 @@ msh />
 
 在 menuconfig 中启用 `RT_USING_SOFT_RTC` 配置。
 
-> 注意:如果没有使用组件自动初始化功能,则需手动调用 `int rt_soft_rtc_init(void)` ,完成该功能初始化。
-

+ 1 - 1
components/drivers/rtc/soft_rtc.c

@@ -104,7 +104,7 @@ const static struct rt_device_ops soft_rtc_ops =
 };
 #endif
 
-int rt_soft_rtc_init(void)
+static int rt_soft_rtc_init(void)
 {
     static rt_bool_t init_ok = RT_FALSE;
     struct tm time_new = SOFT_RTC_TIME_DEFAULT;