Skip to content

Commit 3b1d4e9

Browse files
authored
fix Compilation error in "driver.c", "completion_up.c", "syslog.c" and "dlmodule.c". (#9093)
1 parent 071b3d9 commit 3b1d4e9

File tree

5 files changed

+7
-6
lines changed

5 files changed

+7
-6
lines changed

Diff for: components/drivers/core/driver.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,4 @@ rt_err_t rt_driver_unregister(rt_driver_t drv)
5050

5151
return ret;
5252
}
53-
RTM_EXPORT(rt_driver_register);
53+
RTM_EXPORT(rt_driver_unregister);

Diff for: components/drivers/ipc/completion_up.c

-1
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,6 @@ rt_err_t rt_completion_wait_flags(struct rt_completion *completion,
147147

148148
return result;
149149
}
150-
RTM_EXPORT(rt_completion_wait);
151150

152151
/**
153152
* @brief This function indicates a completion has done and wakeup the thread

Diff for: components/libc/posix/libdl/dlmodule.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ static void _dlmodule_exit(void)
128128
rt_thread_t thread = (rt_thread_t)object;
129129

130130
/* stop timer and suspend thread*/
131-
if ((thread->stat & RT_THREAD_STAT_MASK) != RT_THREAD_CLOSE &&
132-
(thread->stat & RT_THREAD_STAT_MASK) != RT_THREAD_INIT)
131+
if ((RT_SCHED_CTX(thread).stat & RT_THREAD_STAT_MASK) != RT_THREAD_CLOSE &&
132+
(RT_SCHED_CTX(thread).stat & RT_THREAD_STAT_MASK) != RT_THREAD_INIT)
133133
{
134134
rt_timer_stop(&(thread->thread_timer));
135135
rt_thread_suspend(thread);
@@ -770,7 +770,7 @@ void dlmodule_exit(int ret_code)
770770
/* the stat of module was changed to CLOSING in _dlmodule_exit */
771771

772772
thread = module->main_thread;
773-
if ((thread->stat & RT_THREAD_STAT_MASK) == RT_THREAD_CLOSE)
773+
if ((RT_SCHED_CTX(thread).stat & RT_THREAD_STAT_MASK) == RT_THREAD_CLOSE)
774774
{
775775
/* main thread already closed */
776776
rt_exit_critical();

Diff for: components/utilities/ulog/syslog/syslog.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ void vsyslog(int priority, const char *format, va_list args)
9494
priority |= local_facility;
9595
}
9696

97-
ulog_voutput(priority, local_ident, RT_TRUE, format, args);
97+
ulog_voutput(priority, local_ident, RT_TRUE, RT_NULL, 0, 0, 0, format, args);
9898
}
9999

100100
/**

Diff for: components/utilities/ulog/ulog.h

+2
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ void ulog_hexdump(const char *tag, rt_size_t width, const rt_uint8_t *buf, rt_si
9292
/*
9393
* Another log output API. This API is more difficult to use than LOG_X API.
9494
*/
95+
void ulog_voutput(rt_uint32_t level, const char *tag, rt_bool_t newline, const rt_uint8_t *hex_buf,
96+
rt_size_t hex_size, rt_size_t hex_width, rt_base_t hex_addr, const char *format, va_list args);
9597
void ulog_output(rt_uint32_t level, const char *tag, rt_bool_t newline, const char *format, ...);
9698
void ulog_raw(const char *format, ...);
9799

0 commit comments

Comments
 (0)