Skip to content

Commit 62bc4ba

Browse files
lygstateRbb666
authored andcommitted
Remove rarely used rt_time_t
next_delay should be rt_tick_t Use time_t for RT_DEVICE_CTRL_RTC_GET_TIME
1 parent d58958e commit 62bc4ba

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

bsp/fujitsu/mb9x/mb9bf500r/key.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ static void key_io_init(void)
3030
static void key_thread_entry(void *parameter)
3131
{
3232
#ifdef RT_USING_RTGUI
33-
rt_time_t next_delay;
33+
rt_tick_t next_delay;
3434
rt_uint8_t i;
3535

3636
struct rtgui_event_kbd kbd_event;
@@ -106,7 +106,7 @@ static void key_thread_entry(void *parameter)
106106
}
107107
#else
108108
extern struct rt_messagequeue mq;
109-
rt_time_t next_delay;
109+
rt_tick_t next_delay;
110110
struct lcd_msg msg;
111111
msg.type = KEY_MSG;
112112

include/rttypes.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@ typedef rt_ubase_t rt_uintptr_t; /**< Type for unsigned
8888
#endif /* defined(RT_USING_LIBC) && !defined(RT_USING_NANO) */
8989

9090
typedef rt_base_t rt_err_t; /**< Type for error number */
91-
typedef rt_uint32_t rt_time_t; /**< Type for time stamp */
9291
typedef rt_uint32_t rt_tick_t; /**< Type for tick count */
9392
typedef rt_base_t rt_flag_t; /**< Type for flags */
9493
typedef rt_ubase_t rt_dev_t; /**< Type for device */

libcpu/arm/s3c24x0/rtc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ static rt_err_t rtc_control(rt_device_t dev, int cmd, void *args)
136136
case RT_DEVICE_CTRL_RTC_GET_TIME:
137137
/* read device */
138138
rt_hw_rtc_get(&tmp);
139-
*((rt_time_t *)args) = timegm(&tmp);
139+
*time = timegm(&tmp);
140140
break;
141141

142142
case RT_DEVICE_CTRL_RTC_SET_TIME:

0 commit comments

Comments
 (0)