arch/x86_64: Remove FAR from chip folder

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-04-17 20:44:07 +08:00 committed by Petro Karashchenko
parent af00e016e9
commit 0bd9a66305
8 changed files with 23 additions and 23 deletions

View File

@ -67,7 +67,7 @@ const uintptr_t g_idle_topstack = (uintptr_t)&_ebss +
*
****************************************************************************/
void up_allocate_heap(FAR void **heap_start, size_t *heap_size)
void up_allocate_heap(void **heap_start, size_t *heap_size)
{
board_autoled_on(LED_HEAPALLOCATE);

View File

@ -89,7 +89,7 @@ static void x86_64_stackdump(uint64_t sp, uint64_t stack_top)
****************************************************************************/
#ifdef CONFIG_ARCH_USBDUMP
static int usbtrace_syslog(FAR const char *fmt, ...)
static int usbtrace_syslog(const char *fmt, ...)
{
va_list ap;
@ -101,7 +101,7 @@ static int usbtrace_syslog(FAR const char *fmt, ...)
return OK;
}
static int assert_tracecallback(FAR struct usbtrace_s *trace, FAR void *arg)
static int assert_tracecallback(struct usbtrace_s *trace, void *arg)
{
usbtrace_trprintf(usbtrace_syslog, trace->event, trace->value);
return 0;
@ -115,7 +115,7 @@ static int assert_tracecallback(FAR struct usbtrace_s *trace, FAR void *arg)
#ifdef CONFIG_ARCH_STACKDUMP
static void up_dumpstate(void)
{
FAR struct tcb_s *rtcb = running_task();
struct tcb_s *rtcb = running_task();
uint64_t sp = up_getsp();
uint64_t ustackbase;
uint64_t ustacksize;

View File

@ -61,9 +61,9 @@
****************************************************************************/
#ifdef CONFIG_DUMP_ON_EXIT
static void _up_dumponexit(FAR struct tcb_s *tcb, FAR void *arg)
static void _up_dumponexit(struct tcb_s *tcb, void *arg)
{
FAR struct filelist *filelist;
struct filelist *filelist;
int i;
int j;

View File

@ -27,10 +27,10 @@
*
* void sim_timer_initialize(void): Initializes the timer facilities.
* Called early in the initialization sequence (by up_initialize()).
* int up_timer_gettime(FAR struct timespec *ts): Returns the current
* int up_timer_gettime(struct timespec *ts): Returns the current
* time from the platform specific time source.
* int up_timer_cancel(void): Cancels the interval timer.
* int up_timer_start(FAR const struct timespec *ts): Start (or re-starts)
* int up_timer_start(const struct timespec *ts): Start (or re-starts)
* the interval timer.
*
* The RTOS will provide the following interfaces for use by the platform-
@ -137,14 +137,14 @@ void up_timer_initialize(void)
return;
}
static inline uint64_t up_ts2tick(FAR const struct timespec *ts)
static inline uint64_t up_ts2tick(const struct timespec *ts)
{
return ROUND_INT_DIV((uint64_t)ts->tv_nsec * x86_64_timer_freq,
NS_PER_SEC) +
(uint64_t)ts->tv_sec * x86_64_timer_freq;
}
static inline void up_tick2ts(uint64_t tick, FAR struct timespec *ts)
static inline void up_tick2ts(uint64_t tick, struct timespec *ts)
{
ts->tv_sec = (tick / x86_64_timer_freq);
ts->tv_nsec = (uint64_t)(ROUND_INT_DIV((tick % x86_64_timer_freq) *
@ -182,7 +182,7 @@ static inline void up_tmr_sync_down(void)
* sim_timer_initialize() was called). This function is functionally
* equivalent to:
*
* int clock_gettime(clockid_t clockid, FAR struct timespec *ts);
* int clock_gettime(clockid_t clockid, struct timespec *ts);
*
* when clockid is CLOCK_MONOTONIC.
*
@ -207,7 +207,7 @@ static inline void up_tmr_sync_down(void)
*
****************************************************************************/
int up_timer_gettime(FAR struct timespec *ts)
int up_timer_gettime(struct timespec *ts)
{
uint64_t diff = (rdtsc() - g_start_tsc);
up_tick2ts(diff, ts);
@ -247,7 +247,7 @@ int up_timer_gettime(FAR struct timespec *ts)
*
****************************************************************************/
int up_timer_cancel(FAR struct timespec *ts)
int up_timer_cancel(struct timespec *ts)
{
up_tmr_sync_up();
@ -298,7 +298,7 @@ int up_timer_cancel(FAR struct timespec *ts)
*
****************************************************************************/
int up_timer_start(FAR const struct timespec *ts)
int up_timer_start(const struct timespec *ts)
{
uint64_t ticks;
@ -375,7 +375,7 @@ void up_timer_expire(void)
*
****************************************************************************/
int up_alarm_cancel(FAR struct timespec *ts)
int up_alarm_cancel(struct timespec *ts)
{
up_tmr_sync_up();
@ -418,7 +418,7 @@ int up_alarm_cancel(FAR struct timespec *ts)
*
****************************************************************************/
int up_alarm_start(FAR const struct timespec *ts)
int up_alarm_start(const struct timespec *ts)
{
uint64_t ticks;

View File

@ -88,7 +88,7 @@
*
****************************************************************************/
int up_create_stack(FAR struct tcb_s *tcb, size_t stack_size, uint8_t ttype)
int up_create_stack(struct tcb_s *tcb, size_t stack_size, uint8_t ttype)
{
#ifdef CONFIG_TLS_ALIGNED
/* The allocated stack size must not exceed the maximum possible for the

View File

@ -77,7 +77,7 @@
*
****************************************************************************/
void up_release_stack(FAR struct tcb_s *dtcb, uint8_t ttype)
void up_release_stack(struct tcb_s *dtcb, uint8_t ttype)
{
/* Is there a stack allocated? */

View File

@ -139,7 +139,7 @@ int up_rtc_initialize(void)
*
************************************************************************************/
int up_rtc_gettime(FAR struct timespec *tp)
int up_rtc_gettime(struct timespec *tp)
{
uint64_t tmp;
@ -165,7 +165,7 @@ int up_rtc_gettime(FAR struct timespec *tp)
*
************************************************************************************/
int up_rtc_settime(FAR const struct timespec *tp)
int up_rtc_settime(const struct timespec *tp)
{
/* What so ever.. */

View File

@ -69,9 +69,9 @@
*
****************************************************************************/
FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
void *up_stack_frame(struct tcb_s *tcb, size_t frame_size)
{
FAR void *ret;
void *ret;
/* Align the frame_size */
@ -89,7 +89,7 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
/* Save the adjusted stack values in the struct tcb_s */
tcb->stack_base_ptr = (FAR uint8_t *)tcb->stack_base_ptr + frame_size;
tcb->stack_base_ptr = (uint8_t *)tcb->stack_base_ptr + frame_size;
tcb->adj_stack_size -= frame_size;
/* And return the pointer to the allocated region */