mirror of
https://github.com/apache/nuttx.git
synced 2026-05-29 20:56:47 +08:00
Fix more compile errors and warnings introduced in recent commits
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5744 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -115,17 +115,18 @@ void up_initial_state(struct tcb_s *tcb)
|
|||||||
xcp->regs[REG_PIC] = (uint32_t)tcb->dspace->region;
|
xcp->regs[REG_PIC] = (uint32_t)tcb->dspace->region;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef CONFIG_NXFLAT
|
||||||
/* Make certain that bit 0 is set in the main entry address. This is
|
/* Make certain that bit 0 is set in the main entry address. This is
|
||||||
* only an issue when NXFLAT is enabled. NXFLAT doesn't know anything
|
* only an issue when NXFLAT is enabled. NXFLAT doesn't know anything
|
||||||
* about thumb; the addresses that NXFLAT sets are based on file header
|
* about thumb; the addresses that NXFLAT sets are based on file header
|
||||||
* info and won't have bit 0 set.
|
* info and won't have bit 0 set.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_NXFLAT
|
|
||||||
tcb->entry.main = (main_t)((uint32_t)tcb->entry.main | 1);
|
tcb->entry.main = (main_t)((uint32_t)tcb->entry.main | 1);
|
||||||
#endif
|
#endif
|
||||||
#endif /* CONFIG_PIC */
|
#endif /* CONFIG_PIC */
|
||||||
|
|
||||||
|
#ifdef CONFIG_NUTTX_KERNEL
|
||||||
/* All tasks start via a stub function in kernel space. So all
|
/* All tasks start via a stub function in kernel space. So all
|
||||||
* tasks must start in privileged thread mode. If CONFIG_NUTTX_KERNEL
|
* tasks must start in privileged thread mode. If CONFIG_NUTTX_KERNEL
|
||||||
* is defined, then that stub function will switch to unprivileged
|
* is defined, then that stub function will switch to unprivileged
|
||||||
@@ -133,6 +134,7 @@ void up_initial_state(struct tcb_s *tcb)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
xcp->regs[REG_EXC_RETURN] = EXC_RETURN_PRIVTHR;
|
xcp->regs[REG_EXC_RETURN] = EXC_RETURN_PRIVTHR;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Enable or disable interrupts, based on user configuration */
|
/* Enable or disable interrupts, based on user configuration */
|
||||||
|
|
||||||
|
|||||||
@@ -115,13 +115,13 @@ void up_initial_state(struct tcb_s *tcb)
|
|||||||
xcp->regs[REG_PIC] = (uint32_t)tcb->dspace->region;
|
xcp->regs[REG_PIC] = (uint32_t)tcb->dspace->region;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef CONFIG_NXFLAT
|
||||||
/* Make certain that bit 0 is set in the main entry address. This
|
/* Make certain that bit 0 is set in the main entry address. This
|
||||||
* is only an issue when NXFLAT is enabled. NXFLAT doesn't know
|
* is only an issue when NXFLAT is enabled. NXFLAT doesn't know
|
||||||
* anything about thumb; the addresses that NXFLAT sets are based
|
* anything about thumb; the addresses that NXFLAT sets are based
|
||||||
* on file header info and won't have bit 0 set.
|
* on file header info and won't have bit 0 set.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_NXFLAT
|
|
||||||
tcb->entry.main = (main_t)((uint32_t)tcb->entry.main | 1);
|
tcb->entry.main = (main_t)((uint32_t)tcb->entry.main | 1);
|
||||||
#endif
|
#endif
|
||||||
#endif /* CONFIG_PIC */
|
#endif /* CONFIG_PIC */
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ static void dispatch_syscall(void)
|
|||||||
|
|
||||||
/* Refer to arch/arm/src/armv7-m/up_svcall.h for how this is done for ARM */
|
/* Refer to arch/arm/src/armv7-m/up_svcall.h for how this is done for ARM */
|
||||||
/* __asm__ __volatile__ */
|
/* __asm__ __volatile__ */
|
||||||
/* (
|
/* ( */
|
||||||
/* Save registers */
|
/* Save registers */
|
||||||
/* Get the base of the stub lookup table */
|
/* Get the base of the stub lookup table */
|
||||||
/* Get the offset of the stub for this syscall */
|
/* Get the offset of the stub for this syscall */
|
||||||
|
|||||||
+1
-1
@@ -232,7 +232,7 @@ int os_bringup(void)
|
|||||||
(main_t)CONFIG_USER_ENTRYPOINT,
|
(main_t)CONFIG_USER_ENTRYPOINT,
|
||||||
(FAR char * const *)NULL);
|
(FAR char * const *)NULL);
|
||||||
#endif
|
#endif
|
||||||
DEBUGASSERT(taskid > 0);
|
ASSERT(taskid > 0);
|
||||||
|
|
||||||
/* We an save a few bytes by discarding the IDLE thread's environment. */
|
/* We an save a few bytes by discarding the IDLE thread's environment. */
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user