summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-09-01 15:39:34 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-09-01 15:39:34 -0600
commit22cdf157c01d76420b790bdbb1d900a41346d53e (patch)
tree6b11889164de620dc7b6a8691574f7b1c457f970
parent6c1153d6b32d65888c13c743cfbe994b3c07cab8 (diff)
downloadnuttx-22cdf157c01d76420b790bdbb1d900a41346d53e.tar.gz
nuttx-22cdf157c01d76420b790bdbb1d900a41346d53e.tar.bz2
nuttx-22cdf157c01d76420b790bdbb1d900a41346d53e.zip
There used to be two ways to pass parameters to new tasks, depending upon the configuration: Either (1) argv[] as created as an array with each string strdup'ed. Or (1) argv[] array and strings were created on the stack before the new task was started. Now, there is only one way, way (1). Way (2) might be slightly more compact, but this is not worth carry the complexity of two different ways of doing the same thing.
-rw-r--r--nuttx/Documentation/NuttX.html12
-rw-r--r--nuttx/Documentation/NuttxPortingGuide.html5
-rw-r--r--nuttx/arch/arm/src/a1x/Make.defs4
-rw-r--r--nuttx/arch/arm/src/c5471/Make.defs17
-rw-r--r--nuttx/arch/arm/src/calypso/Make.defs2
-rw-r--r--nuttx/arch/arm/src/dm320/Make.defs26
-rw-r--r--nuttx/arch/arm/src/imx/Make.defs24
-rw-r--r--nuttx/arch/arm/src/kinetis/Make.defs6
-rw-r--r--nuttx/arch/arm/src/kl/Make.defs8
-rw-r--r--nuttx/arch/arm/src/lpc17xx/Make.defs6
-rw-r--r--nuttx/arch/arm/src/lpc214x/Make.defs27
-rw-r--r--nuttx/arch/arm/src/lpc2378/Make.defs24
-rw-r--r--nuttx/arch/arm/src/lpc31xx/Make.defs2
-rw-r--r--nuttx/arch/arm/src/lpc43xx/Make.defs7
-rw-r--r--nuttx/arch/arm/src/nuc1xx/Make.defs8
-rw-r--r--nuttx/arch/arm/src/sam34/Make.defs6
-rw-r--r--nuttx/arch/arm/src/sama5/Make.defs4
-rw-r--r--nuttx/arch/arm/src/samd/Make.defs8
-rw-r--r--nuttx/arch/arm/src/stm32/Make.defs8
-rw-r--r--nuttx/arch/arm/src/str71x/Make.defs28
-rw-r--r--nuttx/arch/arm/src/tiva/Make.defs7
-rw-r--r--nuttx/arch/avr/src/at32uc3/Make.defs22
-rw-r--r--nuttx/arch/avr/src/at90usb/Make.defs17
-rw-r--r--nuttx/arch/avr/src/atmega/Make.defs18
-rw-r--r--nuttx/arch/avr/src/avr/up_stackframe.c1
-rw-r--r--nuttx/arch/avr/src/avr32/up_stackframe.c1
-rw-r--r--nuttx/arch/hc/src/common/up_stackframe.c1
-rw-r--r--nuttx/arch/hc/src/m9s12/Make.defs20
-rw-r--r--nuttx/arch/mips/src/common/up_stackframe.c1
-rw-r--r--nuttx/arch/mips/src/pic32mx/Make.defs25
-rw-r--r--nuttx/arch/rgmp/src/nuttx.c2
-rw-r--r--nuttx/arch/sh/src/common/up_stackframe.c1
-rw-r--r--nuttx/arch/sh/src/m16c/Make.defs20
-rw-r--r--nuttx/arch/sh/src/sh1/Make.defs3
-rw-r--r--nuttx/arch/sim/src/up_stackframe.c1
-rw-r--r--nuttx/arch/x86/src/i486/up_stackframe.c1
-rw-r--r--nuttx/arch/x86/src/qemu/Make.defs3
-rw-r--r--nuttx/arch/z16/src/common/up_stackframe.c1
-rw-r--r--nuttx/arch/z16/src/z16f/Make.defs3
-rw-r--r--nuttx/arch/z80/src/common/up_stackframe.c1
-rw-r--r--nuttx/arch/z80/src/ez80/Make.defs17
-rw-r--r--nuttx/arch/z80/src/z180/Make.defs4
-rw-r--r--nuttx/arch/z80/src/z8/Make.defs12
-rw-r--r--nuttx/arch/z80/src/z80/Make.defs25
-rw-r--r--nuttx/include/nuttx/arch.h4
-rw-r--r--nuttx/include/nuttx/sched.h10
-rw-r--r--nuttx/sched/sched/sched_releasetcb.c27
-rw-r--r--nuttx/sched/task/task_setup.c128
48 files changed, 251 insertions, 357 deletions
diff --git a/nuttx/Documentation/NuttX.html b/nuttx/Documentation/NuttX.html
index 276ae22a7..5bc50161a 100644
--- a/nuttx/Documentation/NuttX.html
+++ b/nuttx/Documentation/NuttX.html
@@ -3634,13 +3634,13 @@ Mem: 29232 5920 23312 23312
problems because of SDCC compiler differences.
Refer to the NuttX board <a href="http://sourceforge.net/p/nuttx/git/ci/master/tree/misc/Obsoleted/configs/pjrc-8051/README.txt">README</a> file for further information.
</p>
- <p>
- <b>Obsoleted</b>.
- This architecture has been obsoleted.
- The code has been moved out of the source tree an can now be found in <a href="http://sourceforge.net/p/nuttx/git/ci/master/tree/misc/Obsoleted/">Obsoleted</a> directory.
- This support was obsoleted because (1) the architecture limitations of the 8051 family make ongoing support too difficult, and (2) although the basic port was marginally functional, it has never really been demonstrated convincingly in any application.
- </p>
</ul>
+ <p>
+ <b><i>Obsoleted</i></b>.
+ This architecture has been <i>obsoleted</i>.
+ The code has been moved out of the NuttX source tree but can still be found be found in <a href="http://sourceforge.net/p/nuttx/git/ci/master/tree/misc/Obsoleted/">Obsoleted</a> directory.
+ This support was obsoleted because (1) the architecture limitations of the 8051 family make ongoing development of more advanced NuttX features too difficult, and (2) although the basic port was marginally functional, it has never really been demonstrated convincingly in any application.
+ </p>
</td>
</tr>
<tr>
diff --git a/nuttx/Documentation/NuttxPortingGuide.html b/nuttx/Documentation/NuttxPortingGuide.html
index 07996d513..a2d1d0884 100644
--- a/nuttx/Documentation/NuttxPortingGuide.html
+++ b/nuttx/Documentation/NuttxPortingGuide.html
@@ -1870,7 +1870,7 @@ The system can be re-made subsequently by just typing <code>make</code>.
<p>
<b>Description</b>.
Allocate a stack frame in the TCB's stack to hold thread-specific data.
- This function may be called anytime after <code>up_create_stack()</code> or <code>up_use_stack()</code> have been called but before the task has been started.
+ This function may be called any time after <code>up_create_stack()</code> or <code>up_use_stack()</code> have been called but before the task has been started.
</p>
<p>
Thread data may be kept in the stack (instead of in the TCB) if it is accessed by the user code directly.
@@ -1889,9 +1889,6 @@ The system can be re-made subsequently by just typing <code>make</code>.
This will still be the initial value of the stack pointer when the task is started.
</li>
</ul>
-<p>
- This API is <i>NOT</i> required if <code>CONFIG_BUILD_PROTECTED</code> and <code>CONFIG_BUILD_KERNEL</code> are undefined.
-</p>
<p><b>Input Parameters:</b></p>
<ul>
<li>
diff --git a/nuttx/arch/arm/src/a1x/Make.defs b/nuttx/arch/arm/src/a1x/Make.defs
index 6c53ce0e8..17aa9bbe2 100644
--- a/nuttx/arch/arm/src/a1x/Make.defs
+++ b/nuttx/arch/arm/src/a1x/Make.defs
@@ -62,7 +62,7 @@ endif
CMN_CSRCS = up_initialize.c up_idle.c up_interruptcontext.c up_exit.c
CMN_CSRCS += up_createstack.c up_releasestack.c up_usestack.c up_vfork.c
-CMN_CSRCS += up_puts.c up_mdelay.c up_udelay.c
+CMN_CSRCS += up_puts.c up_mdelay.c up_stackframe.c up_udelay.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += arm_assert.c arm_blocktask.c arm_copyfullstate.c arm_dataabort.c
@@ -83,7 +83,7 @@ CMN_CSRCS += arm_va2pte.c
endif
ifeq ($(CONFIG_BUILD_KERNEL),y)
-CMN_CSRCS += up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_task_start.c up_pthread_start.c
endif
ifeq ($(CONFIG_ARCH_ADDRENV),y)
diff --git a/nuttx/arch/arm/src/c5471/Make.defs b/nuttx/arch/arm/src/c5471/Make.defs
index 379d9123d..388ce9c18 100644
--- a/nuttx/arch/arm/src/c5471/Make.defs
+++ b/nuttx/arch/arm/src/c5471/Make.defs
@@ -35,14 +35,15 @@
HEAD_ASRC = up_nommuhead.S
-CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S vfork.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c \
- up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c up_doirq.c \
- up_exit.c up_idle.c up_initialize.c up_initialstate.c \
- up_interruptcontext.c up_prefetchabort.c up_releasepending.c \
- up_releasestack.c up_reprioritizertr.c up_schedulesigaction.c \
- up_sigdeliver.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_vfork.c
+CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S vfork.S
+
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c
+CMN_CSRCS += up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c up_doirq.c
+CMN_CSRCS += up_exit.c up_idle.c up_initialize.c up_initialstate.c
+CMN_CSRCS += up_interruptcontext.c up_prefetchabort.c up_releasepending.c
+CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_schedulesigaction.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_syscall.c up_unblocktask.c
+CMN_CSRCS += up_undefinedinsn.c up_usestack.c up_vfork.c
ifeq ($(CONFIG_ELF),y)
CMN_CSRCS += up_elf.c
diff --git a/nuttx/arch/arm/src/calypso/Make.defs b/nuttx/arch/arm/src/calypso/Make.defs
index a50ee62d4..9b5a2c9ab 100644
--- a/nuttx/arch/arm/src/calypso/Make.defs
+++ b/nuttx/arch/arm/src/calypso/Make.defs
@@ -45,7 +45,7 @@ CMN_CSRCS += up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c
CMN_CSRCS += up_doirq.c up_exit.c up_idle.c up_initialstate.c up_initialize.c
CMN_CSRCS += up_interruptcontext.c up_prefetchabort.c up_releasepending.c
CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_schedulesigaction.c
-CMN_CSRCS += up_sigdeliver.c up_syscall.c up_unblocktask.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_syscall.c up_unblocktask.c
CMN_CSRCS += up_undefinedinsn.c up_usestack.c calypso_power.c up_vfork.c
ifeq ($(CONFIG_ELF),y)
diff --git a/nuttx/arch/arm/src/dm320/Make.defs b/nuttx/arch/arm/src/dm320/Make.defs
index 36409f378..d38a6ac9d 100644
--- a/nuttx/arch/arm/src/dm320/Make.defs
+++ b/nuttx/arch/arm/src/dm320/Make.defs
@@ -35,15 +35,16 @@
HEAD_ASRC = up_head.S
-CMN_ASRCS = up_cache.S up_fullcontextrestore.S up_saveusercontext.S \
- up_vectors.S up_vectoraddrexcptn.S up_vectortab.S vfork.S
-CMN_CSRCS = up_assert.c up_blocktask.c up_copyfullstate.c up_createstack.c \
- up_dataabort.c up_mdelay.c up_udelay.c up_exit.c up_idle.c \
- up_initialize.c up_initialstate.c up_interruptcontext.c \
- up_prefetchabort.c up_releasepending.c up_releasestack.c \
- up_reprioritizertr.c up_schedulesigaction.c \
- up_sigdeliver.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_vfork.c
+CMN_ASRCS = up_cache.S up_fullcontextrestore.S up_saveusercontext.S
+CMN_ASRCS += up_vectors.S up_vectoraddrexcptn.S up_vectortab.S vfork.S
+
+CMN_CSRCS = up_assert.c up_blocktask.c up_copyfullstate.c up_createstack.c
+CMN_CSRCS += up_dataabort.c up_mdelay.c up_udelay.c up_exit.c up_idle.c
+CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
+CMN_CSRCS += up_prefetchabort.c up_releasepending.c up_releasestack.c
+CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_syscall.c up_unblocktask.c
+CMN_CSRCS += up_undefinedinsn.c up_usestack.c up_vfork.c
ifeq ($(CONFIG_ELF),y)
CMN_CSRCS += up_elf.c
@@ -53,9 +54,10 @@ ifeq ($(CONFIG_DEBUG_STACK),y)
CMN_CSRCS += up_checkstack.c
endif
-CHIP_ASRCS = dm320_lowputc.S dm320_restart.S
-CHIP_CSRCS = dm320_allocateheap.c dm320_boot.c dm320_decodeirq.c \
- dm320_irq.c dm320_serial.c dm320_framebuffer.c
+CHIP_ASRCS = dm320_lowputc.S dm320_restart.S
+
+CHIP_CSRCS = dm320_allocateheap.c dm320_boot.c dm320_decodeirq.c
+CHIP_CSRCS += dm320_irq.c dm320_serial.c dm320_framebuffer.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += dm320_timerisr.c
diff --git a/nuttx/arch/arm/src/imx/Make.defs b/nuttx/arch/arm/src/imx/Make.defs
index f8cd8cd7c..262e34c76 100644
--- a/nuttx/arch/arm/src/imx/Make.defs
+++ b/nuttx/arch/arm/src/imx/Make.defs
@@ -35,15 +35,15 @@
HEAD_ASRC = up_head.S
-CMN_ASRCS = up_cache.S up_fullcontextrestore.S up_saveusercontext.S \
- up_vectors.S up_vectoraddrexcptn.S up_vectortab.S vfork.S
-CMN_CSRCS = up_assert.c up_blocktask.c up_copyfullstate.c up_createstack.c \
- up_dataabort.c up_mdelay.c up_udelay.c up_exit.c up_idle.c \
- up_initialize.c up_initialstate.c up_interruptcontext.c \
- up_prefetchabort.c up_releasepending.c up_releasestack.c \
- up_reprioritizertr.c up_schedulesigaction.c \
- up_sigdeliver.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_vfork.c
+CMN_ASRCS = up_cache.S up_fullcontextrestore.S up_saveusercontext.S
+CMN_ASRCS += up_vectors.S up_vectoraddrexcptn.S up_vectortab.S vfork.S
+CMN_CSRCS = up_assert.c up_blocktask.c up_copyfullstate.c up_createstack.c
+CMN_CSRCS += up_dataabort.c up_mdelay.c up_udelay.c up_exit.c up_idle.c
+CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
+CMN_CSRCS += up_prefetchabort.c up_releasepending.c up_releasestack.c
+CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_syscall.c up_unblocktask.c
+CMN_CSRCS += up_undefinedinsn.c up_usestack.c up_vfork.c
ifeq ($(CONFIG_ELF),y)
CMN_CSRCS += up_elf.c
@@ -53,9 +53,9 @@ ifeq ($(CONFIG_DEBUG_STACK),y)
CMN_CSRCS += up_checkstack.c
endif
-CHIP_ASRCS = imx_lowputc.S
-CHIP_CSRCS = imx_boot.c imx_gpio.c imx_allocateheap.c imx_irq.c \
- imx_serial.c imx_decodeirq.c imx_spi.c
+CHIP_ASRCS = imx_lowputc.S
+CHIP_CSRCS = imx_boot.c imx_gpio.c imx_allocateheap.c imx_irq.c
+CHIP_CSRCS += imx_serial.c imx_decodeirq.c imx_spi.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += imx_timerisr.c
diff --git a/nuttx/arch/arm/src/kinetis/Make.defs b/nuttx/arch/arm/src/kinetis/Make.defs
index 4e5689d27..18896f1d7 100644
--- a/nuttx/arch/arm/src/kinetis/Make.defs
+++ b/nuttx/arch/arm/src/kinetis/Make.defs
@@ -47,8 +47,8 @@ CMN_CSRCS += up_mdelay.c up_udelay.c up_exit.c up_initialize.c up_memfault.c
CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_modifyreg8.c
CMN_CSRCS += up_modifyreg16.c up_modifyreg32.c up_releasestack.c
CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c up_releasepending.c
-CMN_CSRCS += up_sigdeliver.c up_unblocktask.c up_usestack.c up_doirq.c
-CMN_CSRCS += up_hardfault.c up_svcall.c up_checkstack.c up_vfork.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_unblocktask.c up_usestack.c
+CMN_CSRCS += up_doirq.c up_hardfault.c up_svcall.c up_checkstack.c up_vfork.c
ifeq ($(CONFIG_ARCH_RAMVECTORS),y)
CMN_CSRCS += up_ramvec_initialize.c up_ramvec_attach.c
@@ -59,7 +59,7 @@ CMN_ASRCS += up_memcpy.S
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/kl/Make.defs b/nuttx/arch/arm/src/kl/Make.defs
index 12162fde0..e7a4bceaa 100644
--- a/nuttx/arch/arm/src/kl/Make.defs
+++ b/nuttx/arch/arm/src/kl/Make.defs
@@ -43,12 +43,12 @@ CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c
CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_puts.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_systemreset.c
-CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
-CMN_CSRCS += up_svcall.c up_vectors.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_systemreset.c up_unblocktask.c up_usestack.c up_doirq.c
+CMN_CSRCS += up_hardfault.c up_svcall.c up_vectors.c up_vfork.c
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/lpc17xx/Make.defs b/nuttx/arch/arm/src/lpc17xx/Make.defs
index 539e5de71..9c3bf96ba 100644
--- a/nuttx/arch/arm/src/lpc17xx/Make.defs
+++ b/nuttx/arch/arm/src/lpc17xx/Make.defs
@@ -54,8 +54,8 @@ CMN_CSRCS += up_mdelay.c up_udelay.c up_exit.c up_initialize.c up_memfault.c
CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_modifyreg8.c
CMN_CSRCS += up_modifyreg16.c up_modifyreg32.c up_releasepending.c
CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_schedulesigaction.c
-CMN_CSRCS += up_sigdeliver.c up_unblocktask.c up_usestack.c up_doirq.c
-CMN_CSRCS += up_hardfault.c up_svcall.c up_checkstack.c up_vfork.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_unblocktask.c up_usestack.c
+CMN_CSRCS += up_doirq.c up_hardfault.c up_svcall.c up_checkstack.c up_vfork.c
ifeq ($(CONFIG_ARMV7M_CMNVECTOR),y)
CMN_ASRCS += up_exception.S
@@ -71,7 +71,7 @@ CMN_ASRCS += up_memcpy.S
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/lpc214x/Make.defs b/nuttx/arch/arm/src/lpc214x/Make.defs
index a8a1bf942..aaef5aba3 100644
--- a/nuttx/arch/arm/src/lpc214x/Make.defs
+++ b/nuttx/arch/arm/src/lpc214x/Make.defs
@@ -33,19 +33,21 @@
#
##############################################################################
-HEAD_ASRC = lpc214x_head.S
+HEAD_ASRC = lpc214x_head.S
-CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S \
- vfork.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c \
- up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c \
- up_exit.c up_idle.c up_initialize.c up_initialstate.c \
- up_interruptcontext.c up_prefetchabort.c up_releasepending.c \
- up_releasestack.c up_reprioritizertr.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_lowputs.c up_vfork.c
+CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S
+CMN_ASRCS += vfork.S
+
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c
+CMN_CSRCS += up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c
+CMN_CSRCS += up_exit.c up_idle.c up_initialize.c up_initialstate.c
+CMN_CSRCS += up_interruptcontext.c up_prefetchabort.c up_releasepending.c
+CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_stackframe.c
+CMN_CSRCS += up_syscall.c up_unblocktask.c up_undefinedinsn.c up_usestack.c
+CMN_CSRCS += up_lowputs.c up_vfork.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c
endif
ifeq ($(CONFIG_ELF),y)
@@ -56,8 +58,8 @@ ifeq ($(CONFIG_DEBUG_STACK),y)
CMN_CSRCS += up_checkstack.c
endif
-CHIP_ASRCS = lpc214x_lowputc.S
-CHIP_CSRCS = lpc214x_decodeirq.c lpc214x_irq.c lpc214x_serial.c
+CHIP_ASRCS = lpc214x_lowputc.S
+CHIP_CSRCS = lpc214x_decodeirq.c lpc214x_irq.c lpc214x_serial.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += lpc214x_timerisr.c
@@ -66,4 +68,3 @@ endif
ifeq ($(CONFIG_USBDEV),y)
CHIP_CSRCS += lpc214x_usbdev.c
endif
-
diff --git a/nuttx/arch/arm/src/lpc2378/Make.defs b/nuttx/arch/arm/src/lpc2378/Make.defs
index 09c5cba6e..469fd8ffc 100644
--- a/nuttx/arch/arm/src/lpc2378/Make.defs
+++ b/nuttx/arch/arm/src/lpc2378/Make.defs
@@ -40,14 +40,15 @@
HEAD_ASRC = lpc23xx_head.S
-CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S \
- vfork.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c \
- up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c \
- up_exit.c up_idle.c up_initialize.c up_initialstate.c \
- up_interruptcontext.c up_prefetchabort.c up_releasepending.c \
- up_releasestack.c up_reprioritizertr.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_lowputs.c up_vfork.c
+CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S
+CMN_ASRCS += vfork.S
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c
+CMN_CSRCS += up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c
+CMN_CSRCS += up_exit.c up_idle.c up_initialize.c up_initialstate.c
+CMN_CSRCS += up_interruptcontext.c up_prefetchabort.c up_releasepending.c
+CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_stackframe.c
+CMN_CSRCS += up_syscall.c up_unblocktask.c up_undefinedinsn.c
+CMN_CSRCS += up_usestack.c up_lowputs.c up_vfork.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c
@@ -61,9 +62,9 @@ ifeq ($(CONFIG_DEBUG_STACK),y)
CMN_CSRCS += up_checkstack.c
endif
-CHIP_ASRCS = lpc23xx_lowputc.S
-CHIP_CSRCS = lpc23xx_pllsetup.c lpc23xx_decodeirq.c lpc23xx_irq.c \
- lpc23xx_serial.c lpc23xx_io.c
+CHIP_ASRCS = lpc23xx_lowputc.S
+CHIP_CSRCS += lpc23xx_pllsetup.c lpc23xx_decodeirq.c lpc23xx_irq.c
+CHIP_CSRCS += lpc23xx_serial.c lpc23xx_io.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += lpc23xx_timerisr.c
@@ -80,4 +81,3 @@ endif
ifeq ($(CONFIG_USBDEV),y)
#CHIP_CSRCS += lpc23xx_usbdev.c
endif
-
diff --git a/nuttx/arch/arm/src/lpc31xx/Make.defs b/nuttx/arch/arm/src/lpc31xx/Make.defs
index ee97e6cbb..d9b8f116b 100644
--- a/nuttx/arch/arm/src/lpc31xx/Make.defs
+++ b/nuttx/arch/arm/src/lpc31xx/Make.defs
@@ -44,7 +44,7 @@ CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_prefetchabort.c up_releasepending.c up_releasestack.c
CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c
-CMN_CSRCS += up_sigdeliver.c up_syscall.c up_unblocktask.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_syscall.c up_unblocktask.c
CMN_CSRCS += up_undefinedinsn.c up_usestack.c up_vfork.c
ifeq ($(CONFIG_PAGING),y)
diff --git a/nuttx/arch/arm/src/lpc43xx/Make.defs b/nuttx/arch/arm/src/lpc43xx/Make.defs
index 04793d7b1..9d7c48d9c 100644
--- a/nuttx/arch/arm/src/lpc43xx/Make.defs
+++ b/nuttx/arch/arm/src/lpc43xx/Make.defs
@@ -43,8 +43,9 @@ CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c
CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_memfault.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_unblocktask.c
-CMN_CSRCS += up_usestack.c up_doirq.c up_hardfault.c up_svcall.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
+CMN_CSRCS += up_svcall.c up_vfork.c
ifeq ($(CONFIG_ARMV7M_CMNVECTOR),y)
CMN_ASRCS += up_exception.S
@@ -60,7 +61,7 @@ CMN_ASRCS += up_memcpy.S
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/nuc1xx/Make.defs b/nuttx/arch/arm/src/nuc1xx/Make.defs
index 6161b4928..f13458904 100644
--- a/nuttx/arch/arm/src/nuc1xx/Make.defs
+++ b/nuttx/arch/arm/src/nuc1xx/Make.defs
@@ -43,12 +43,12 @@ CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c
CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_systemreset.c
-CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
-CMN_CSRCS += up_svcall.c up_vectors.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_systemreset.c up_unblocktask.c up_usestack.c up_doirq.c
+CMN_CSRCS += up_hardfault.c up_svcall.c up_vectors.c up_vfork.c
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/sam34/Make.defs b/nuttx/arch/arm/src/sam34/Make.defs
index ec7d10b3a..cb1727565 100644
--- a/nuttx/arch/arm/src/sam34/Make.defs
+++ b/nuttx/arch/arm/src/sam34/Make.defs
@@ -49,8 +49,8 @@ CMN_CSRCS += up_mdelay.c up_udelay.c up_exit.c up_idle.c up_initialize.c
CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_memfault.c up_modifyreg8.c
CMN_CSRCS += up_modifyreg16.c up_modifyreg32.c up_releasepending.c
CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_schedulesigaction.c
-CMN_CSRCS += up_sigdeliver.c up_unblocktask.c up_usestack.c up_doirq.c
-CMN_CSRCS += up_hardfault.c up_svcall.c up_vfork.c
+CMN_CSRCS += up_sigdeliver.c up_stackframe.c up_unblocktask.c up_usestack.c
+CMN_CSRCS += up_doirq.c up_hardfault.c up_svcall.c up_vfork.c
# Configuration-dependent common files
@@ -63,7 +63,7 @@ CMN_ASRCS += up_memcpy.S
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/sama5/Make.defs b/nuttx/arch/arm/src/sama5/Make.defs
index 6daa81b5e..dc4544df7 100644
--- a/nuttx/arch/arm/src/sama5/Make.defs
+++ b/nuttx/arch/arm/src/sama5/Make.defs
@@ -64,7 +64,7 @@ endif
CMN_CSRCS = up_initialize.c up_idle.c up_interruptcontext.c up_exit.c
CMN_CSRCS += up_createstack.c up_releasestack.c up_usestack.c up_vfork.c
-CMN_CSRCS += up_puts.c up_mdelay.c up_udelay.c
+CMN_CSRCS += up_puts.c up_mdelay.c up_stackframe.c up_udelay.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += arm_assert.c arm_blocktask.c arm_copyfullstate.c arm_dataabort.c
@@ -85,7 +85,7 @@ CMN_CSRCS += arm_va2pte.c
endif
ifeq ($(CONFIG_BUILD_KERNEL),y)
-CMN_CSRCS += up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_task_start.c up_pthread_start.c
endif
ifeq ($(CONFIG_ARCH_ADDRENV),y)
diff --git a/nuttx/arch/arm/src/samd/Make.defs b/nuttx/arch/arm/src/samd/Make.defs
index 1cc4b2f4d..3e7bc4ba0 100644
--- a/nuttx/arch/arm/src/samd/Make.defs
+++ b/nuttx/arch/arm/src/samd/Make.defs
@@ -43,12 +43,12 @@ CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c
CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_systemreset.c
-CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
-CMN_CSRCS += up_svcall.c up_vectors.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_systemreset.c up_unblocktask.c up_usestack.c up_doirq.c
+CMN_CSRCS += up_hardfault.c up_svcall.c up_vectors.c up_vfork.c
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/stm32/Make.defs b/nuttx/arch/arm/src/stm32/Make.defs
index 2a3675da1..2cbf01cc9 100644
--- a/nuttx/arch/arm/src/stm32/Make.defs
+++ b/nuttx/arch/arm/src/stm32/Make.defs
@@ -50,9 +50,9 @@ CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c
CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_memfault.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_systemreset.c
-CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
-CMN_CSRCS += up_svcall.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_systemreset.c up_unblocktask.c up_usestack.c up_doirq.c
+CMN_CSRCS += up_hardfault.c up_svcall.c up_vfork.c
ifeq ($(CONFIG_ARMV7M_CMNVECTOR),y)
CMN_ASRCS += up_exception.S
@@ -68,7 +68,7 @@ CMN_ASRCS += up_memcpy.S
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/arm/src/str71x/Make.defs b/nuttx/arch/arm/src/str71x/Make.defs
index 57ec38a9f..7ab03c675 100644
--- a/nuttx/arch/arm/src/str71x/Make.defs
+++ b/nuttx/arch/arm/src/str71x/Make.defs
@@ -35,14 +35,16 @@
HEAD_ASRC = str71x_head.S
-CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S \
- vfork.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c \
- up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c \
- up_exit.c up_idle.c up_initialize.c up_initialstate.c \
- up_interruptcontext.c up_prefetchabort.c up_releasepending.c \
- up_releasestack.c up_reprioritizertr.c up_syscall.c up_unblocktask.c \
- up_undefinedinsn.c up_usestack.c up_lowputs.c up_vfork.c
+CMN_ASRCS = up_saveusercontext.S up_fullcontextrestore.S up_vectors.S
+CMN_ASRCS += vfork.S
+
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copyfullstate.c
+CMN_CSRCS += up_createstack.c up_dataabort.c up_mdelay.c up_udelay.c
+CMN_CSRCS += up_exit.c up_idle.c up_initialize.c up_initialstate.c
+CMN_CSRCS += up_interruptcontext.c up_prefetchabort.c up_releasepending.c
+CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_stackframe.c
+CMN_CSRCS += up_syscall.c up_unblocktask.c up_undefinedinsn.c up_usestack.c
+CMN_CSRCS += up_lowputs.c up_vfork.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c
@@ -56,19 +58,19 @@ ifeq ($(CONFIG_DEBUG_STACK),y)
CMN_CSRCS += up_checkstack.c
endif
-CHIP_ASRCS =
-CHIP_CSRCS = str71x_prccu.c str71x_lowputc.c str71x_decodeirq.c str71x_irq.c \
- str71x_serial.c
+CHIP_ASRCS =
+CHIP_CSRCS = str71x_prccu.c str71x_lowputc.c str71x_decodeirq.c str71x_irq.c
+CHIP_CSRCS += str71x_serial.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += str71x_timerisr.c
endif
ifeq ($(CONFIG_USBDEV),y)
-CHIP_CSRCS += str71x_usbdev.c
+CHIP_CSRCS+= str71x_usbdev.c
endif
ifeq ($(CONFIG_STR71X_XTI),y)
-CHIP_CSRCS += str71x_xti.c
+CHIP_CSRCS+= str71x_xti.c
endif
diff --git a/nuttx/arch/arm/src/tiva/Make.defs b/nuttx/arch/arm/src/tiva/Make.defs
index e13771bfa..0b2b5cd6e 100644
--- a/nuttx/arch/arm/src/tiva/Make.defs
+++ b/nuttx/arch/arm/src/tiva/Make.defs
@@ -43,8 +43,9 @@ CMN_CSRCS += up_mdelay.c up_udelay.c up_exit.c up_idle.c up_initialize.c
CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_memfault.c
CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
-CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_unblocktask.c
-CMN_CSRCS += up_usestack.c up_doirq.c up_hardfault.c up_svcall.c up_vfork.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c up_hardfault.c
+CMN_CSRCS += up_svcall.c up_vfork.c
ifeq ($(CONFIG_ARCH_RAMVECTORS),y)
CMN_CSRCS += up_ramvec_initialize.c up_ramvec_attach.c
@@ -59,7 +60,7 @@ CMN_CSRCS += up_checkstack.c
endif
ifeq ($(CONFIG_BUILD_PROTECTED),y)
-CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c up_stackframe.c
+CMN_CSRCS += up_mpu.c up_task_start.c up_pthread_start.c
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CMN_CSRCS += up_signal_dispatch.c
CMN_UASRCS += up_signal_handler.S
diff --git a/nuttx/arch/avr/src/at32uc3/Make.defs b/nuttx/arch/avr/src/at32uc3/Make.defs
index fa1f010cf..0e1a98e2a 100644
--- a/nuttx/arch/avr/src/at32uc3/Make.defs
+++ b/nuttx/arch/avr/src/at32uc3/Make.defs
@@ -39,14 +39,14 @@ HEAD_ASRC = up_nommuhead.S
# Common AVR/AVR32 files
-CMN_ASRCS = up_exceptions.S up_fullcontextrestore.S up_switchcontext.S
-CMN_CSRCS = up_assert.c up_allocateheap.c up_blocktask.c up_copystate.c \
- up_createstack.c up_mdelay.c up_udelay.c up_exit.c up_idle.c \
- up_initialize.c up_initialstate.c up_interruptcontext.c \
- up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c \
- up_releasepending.c up_releasestack.c up_reprioritizertr.c \
- up_schedulesigaction.c up_sigdeliver.c up_unblocktask.c \
- up_usestack.c up_doirq.c
+CMN_ASRCS = up_exceptions.S up_fullcontextrestore.S up_switchcontext.S
+CMN_CSRCS = up_assert.c up_allocateheap.c up_blocktask.c up_copystate.c
+CMN_CSRCS += up_createstack.c up_mdelay.c up_udelay.c up_exit.c up_idle.c
+CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
+CMN_CSRCS += up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
+CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
+CMN_CSRCS += up_schedulesigaction.c up_sigdeliver.c up_stackframe.c
+CMN_CSRCS += up_unblocktask.c up_usestack.c up_doirq.c
# Configuration-dependent common files
@@ -56,9 +56,9 @@ endif
# Required AT32UC3 files
-CHIP_ASRCS =
-CHIP_CSRCS = at32uc3_clkinit.c at32uc3_gpio.c at32uc3_irq.c \
- at32uc3_lowconsole.c at32uc3_lowinit.c at32uc3_serial.c
+CHIP_ASRCS =
+CHIP_CSRCS = at32uc3_clkinit.c at32uc3_gpio.c at32uc3_irq.c
+CHIP_CSRCS += at32uc3_lowconsole.c at32uc3_lowinit.c at32uc3_serial.c
# Configuration-dependent AT32UC3 files
diff --git a/nuttx/arch/avr/src/at90usb/Make.defs b/nuttx/arch/avr/src/at90usb/Make.defs
index fb79d877c..249f345dc 100644
--- a/nuttx/arch/avr/src/at90usb/Make.defs
+++ b/nuttx/arch/avr/src/at90usb/Make.defs
@@ -39,14 +39,14 @@ HEAD_ASRC = at90usb_head.S
# Common AVR files
-CMN_ASRCS = up_switchcontext.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c \
- up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c \
- up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c \
- up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c \
- up_puts.c up_releasepending.c up_releasestack.c \
- up_reprioritizertr.c up_schedulesigaction.c up_sigdeliver.c \
- up_udelay.c up_unblocktask.c up_usestack.c
+CMN_ASRCS = up_switchcontext.S
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c
+CMN_CSRCS += up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c
+CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c
+CMN_CSRCS += up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
+CMN_CSRCS += up_puts.c up_releasepending.c up_releasestack.c
+CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c up_sigdeliver.c
+CMN_CSRCS += up_stackframe.c up_udelay.c up_unblocktask.c up_usestack.c
# Configuration-dependent common files
@@ -80,4 +80,3 @@ endif
ifeq ($(CONFIG_AVR_USBDEV),y)
CHIP_CSRCS += at90usb_usbdev.c
endif
-
diff --git a/nuttx/arch/avr/src/atmega/Make.defs b/nuttx/arch/avr/src/atmega/Make.defs
index 7ffd174e0..73377bd1a 100644
--- a/nuttx/arch/avr/src/atmega/Make.defs
+++ b/nuttx/arch/avr/src/atmega/Make.defs
@@ -39,14 +39,14 @@ HEAD_ASRC = atmega_head.S
# Common AVR files
-CMN_ASRCS = up_switchcontext.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c \
- up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c \
- up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c \
- up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c \
- up_puts.c up_releasepending.c up_releasestack.c \
- up_reprioritizertr.c up_schedulesigaction.c up_sigdeliver.c \
- up_udelay.c up_unblocktask.c up_usestack.c
+CMN_ASRCS = up_switchcontext.S
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c
+CMN_CSRCS += up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c
+CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c
+CMN_CSRCS += up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
+CMN_CSRCS += up_puts.c up_releasepending.c up_releasestack.c
+CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c up_sigdeliver.c
+CMN_CSRCS += up_stackframe.c up_udelay.c up_unblocktask.c up_usestack.c
# Configuration-dependent common files
@@ -78,5 +78,5 @@ endif
# Configuration-dependent ATMEGA files
ifeq ($(CONFIG_AVR_GPIOIRQ),y)
-CHIP_CSRCS +=
+CHIP_CSRCS +=
endif
diff --git a/nuttx/arch/avr/src/avr/up_stackframe.c b/nuttx/arch/avr/src/avr/up_stackframe.c
index 2a09f0550..1dfa238a2 100644
--- a/nuttx/arch/avr/src/avr/up_stackframe.c
+++ b/nuttx/arch/avr/src/avr/up_stackframe.c
@@ -123,3 +123,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint8_t));
}
+
diff --git a/nuttx/arch/avr/src/avr32/up_stackframe.c b/nuttx/arch/avr/src/avr32/up_stackframe.c
index e53eee5ae..576f83285 100644
--- a/nuttx/arch/avr/src/avr32/up_stackframe.c
+++ b/nuttx/arch/avr/src/avr32/up_stackframe.c
@@ -138,3 +138,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/hc/src/common/up_stackframe.c b/nuttx/arch/hc/src/common/up_stackframe.c
index 4ced22c4a..72777893d 100644
--- a/nuttx/arch/hc/src/common/up_stackframe.c
+++ b/nuttx/arch/hc/src/common/up_stackframe.c
@@ -139,3 +139,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint16_t));
}
+
diff --git a/nuttx/arch/hc/src/m9s12/Make.defs b/nuttx/arch/hc/src/m9s12/Make.defs
index 41be083df..809a0696c 100644
--- a/nuttx/arch/hc/src/m9s12/Make.defs
+++ b/nuttx/arch/hc/src/m9s12/Make.defs
@@ -35,21 +35,21 @@
HEAD_ASRC = m9s12_vectors.S
-CMN_ASRCS =
-CMN_CSRCS = up_allocateheap.c up_blocktask.c up_copystate.c up_createstack.c \
- up_doirq.c up_exit.c up_idle.c up_initialize.c up_interruptcontext.c \
- up_mdelay.c up_modifyreg16.c up_modifyreg32.c up_modifyreg8.c \
- up_puts.c up_releasepending.c up_releasestack.c up_reprioritizertr.c \
- up_udelay.c up_unblocktask.c up_usestack.c
+CMN_ASRCS =
+CMN_CSRCS = up_allocateheap.c up_blocktask.c up_copystate.c up_createstack.c
+CMN_CSRCS += up_doirq.c up_exit.c up_idle.c up_initialize.c up_interruptcontext.c
+CMN_CSRCS += up_mdelay.c up_modifyreg16.c up_modifyreg32.c up_modifyreg8.c
+CMN_CSRCS += up_puts.c up_releasepending.c up_releasestack.c up_reprioritizertr.c
+CMN_CSRCS += up_stackframe.c up_udelay.c up_unblocktask.c up_usestack.c
-CHIP_ASRCS = m9s12_start.S m9s12_lowputc.S m9s12_saveusercontext.S
-CHIP_CSRCS = m9s12_assert.c m9s12_gpio.c m9s12_gpioirq.c m9s12_initialstate.c \
- m9s12_irq.c m9s12_serial.c
+CHIP_ASRCS = m9s12_start.S m9s12_lowputc.S m9s12_saveusercontext.S
+CHIP_CSRCS = m9s12_assert.c m9s12_gpio.c m9s12_gpioirq.c m9s12_initialstate.c
+CHIP_CSRCS += m9s12_irq.c m9s12_serial.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += m9s12_timerisr.c
endif
ifeq ($(CONFIG_DEBUG_GPIO),y)
-CHIP_CSRCS += m9s12_dumpgpio.c
+CHIP_CSRCS+= m9s12_dumpgpio.c
endif
diff --git a/nuttx/arch/mips/src/common/up_stackframe.c b/nuttx/arch/mips/src/common/up_stackframe.c
index 87f13bc42..1c4776af5 100644
--- a/nuttx/arch/mips/src/common/up_stackframe.c
+++ b/nuttx/arch/mips/src/common/up_stackframe.c
@@ -140,3 +140,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/mips/src/pic32mx/Make.defs b/nuttx/arch/mips/src/pic32mx/Make.defs
index 873fc1571..aac5b19f1 100644
--- a/nuttx/arch/mips/src/pic32mx/Make.defs
+++ b/nuttx/arch/mips/src/pic32mx/Make.defs
@@ -39,14 +39,15 @@ HEAD_ASRC = pic32mx-head.S
# Common MIPS files
-CMN_ASRCS = up_syscall0.S vfork.S
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c \
- up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c \
- up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c \
- up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c \
- up_puts.c up_releasepending.c up_releasestack.c up_reprioritizertr.c \
- up_schedulesigaction.c up_sigdeliver.c up_swint0.c up_udelay.c \
- up_unblocktask.c up_usestack.c up_vfork.c
+CMN_ASRCS = up_syscall0.S vfork.S
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_copystate.c
+CMN_CSRCS += up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c
+CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_irq.c up_lowputs.c
+CMN_CSRCS += up_mdelay.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
+CMN_CSRCS += up_puts.c up_releasepending.c up_releasestack.c
+CMN_CSRCS += up_reprioritizertr.c up_schedulesigaction.c up_sigdeliver.c
+CMN_CSRCS += up_stackframe.c up_swint0.c up_udelay.c up_unblocktask.c
+CMN_CSRCS += up_usestack.c up_vfork.c
# Configuration dependent common files
@@ -62,9 +63,10 @@ endif
# Required PIC32MX files
-CHIP_ASRCS =
-CHIP_CSRCS = pic32mx-irq.c pic32mx-decodeirq.c pic32mx-exception.c pic32mx-gpio.c \
- pic32mx-lowconsole.c pic32mx-lowinit.c pic32mx-serial.c pic32mx-spi.c
+CHIP_ASRCS =
+CHIP_CSRCS = pic32mx-irq.c pic32mx-decodeirq.c pic32mx-exception.c
+CHIP_CSRCS += pic32mx-gpio.c pic32mx-lowconsole.c pic32mx-lowinit.c
+CHIP_CSRCS += pic32mx-serial.c pic32mx-spi.cO
# Configuration-dependent PIC32MX files
@@ -83,4 +85,3 @@ endif
ifeq ($(CONFIG_PIC32MX_ETHERNET),y)
CHIP_CSRCS += pic32mx-ethernet.c
endif
-
diff --git a/nuttx/arch/rgmp/src/nuttx.c b/nuttx/arch/rgmp/src/nuttx.c
index 3f9323bb7..dc5478bd2 100644
--- a/nuttx/arch/rgmp/src/nuttx.c
+++ b/nuttx/arch/rgmp/src/nuttx.c
@@ -170,7 +170,6 @@ int up_use_stack(struct tcb_s *tcb, void *stack, size_t stack_size)
return OK;
}
-#ifdef CONFIG_BUILD_KERNEL
FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
{
uintptr_t topaddr;
@@ -199,7 +198,6 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
-#endif
void up_release_stack(struct tcb_s *dtcb, uint8_t ttype)
{
diff --git a/nuttx/arch/sh/src/common/up_stackframe.c b/nuttx/arch/sh/src/common/up_stackframe.c
index 736402b81..727cbb783 100644
--- a/nuttx/arch/sh/src/common/up_stackframe.c
+++ b/nuttx/arch/sh/src/common/up_stackframe.c
@@ -136,3 +136,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/sh/src/m16c/Make.defs b/nuttx/arch/sh/src/m16c/Make.defs
index ae5d34be6..6995d37b1 100644
--- a/nuttx/arch/sh/src/m16c/Make.defs
+++ b/nuttx/arch/sh/src/m16c/Make.defs
@@ -35,16 +35,16 @@
HEAD_ASRC = m16c_head.S
-CMN_ASRCS =
-CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c \
- up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c \
- up_interruptcontext.c up_lowputs.c up_mdelay.c up_puts.c \
- up_releasepending.c up_releasestack.c up_reprioritizertr.c \
- up_udelay.c up_unblocktask.c up_usestack.c
+CMN_ASRCS =
+CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c
+CMN_CSRCS += up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c
+CMN_CSRCS += up_interruptcontext.c up_lowputs.c up_mdelay.c up_puts.c
+CMN_CSRCS += up_releasepending.c up_releasestack.c up_reprioritizertr.c
+CMN_CSRCS += up_stackframe.c up_udelay.c up_unblocktask.c up_usestack.c
-CHIP_ASRCS = m16c_vectors.S
-CHIP_CSRCS = m16c_initialstate.c m16c_copystate.c m16c_lowputc.c m16c_irq.c \
- m16c_serial.c m16c_dumpstate.c
+CHIP_ASRCS = m16c_vectors.S
+CHIP_CSRCS = m16c_initialstate.c m16c_copystate.c m16c_lowputc.c m16c_irq.c
+CHIP_CSRCS += m16c_serial.c m16c_dumpstate.c
ifneq ($(CONFIG_SCHED_TICKLESS),y)
CHIP_CSRCS += m16c_timerisr.c
@@ -53,5 +53,3 @@ endif
ifneq ($(CONFIG_DISABLE_SIGNALS),y)
CHIP_CSRCS += m16c_schedulesigaction.c m16c_sigdeliver.c
endif
-
-
diff --git a/nuttx/arch/sh/src/sh1/Make.defs b/nuttx/arch/sh/src/sh1/Make.defs
index 28a3150d5..180034a72 100644
--- a/nuttx/arch/sh/src/sh1/Make.defs
+++ b/nuttx/arch/sh/src/sh1/Make.defs
@@ -40,7 +40,8 @@ CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c
CMN_CSRCS += up_createstack.c up_doirq.c up_exit.c up_idle.c up_initialize.c
CMN_CSRCS += up_initialstate.c up_interruptcontext.c up_lowputs.c
CMN_CSRCS += up_mdelay.c up_puts.c up_releasepending.c up_releasestack.c
-CMN_CSRCS += up_reprioritizertr.c up_udelay.c up_unblocktask.c up_usestack.c
+CMN_CSRCS += up_reprioritizertr.c up_stackframe.c up_udelay.c
+CMN_CSRCS += up_unblocktask.c up_usestack.c
CHIP_ASRCS = sh1_vector.S sh1_saveusercontext.S
CHIP_CSRCS = sh1_lowputc.c sh1_irq.c sh1_serial.c sh1_initialstate.c
diff --git a/nuttx/arch/sim/src/up_stackframe.c b/nuttx/arch/sim/src/up_stackframe.c
index 542403c9a..ef6498598 100644
--- a/nuttx/arch/sim/src/up_stackframe.c
+++ b/nuttx/arch/sim/src/up_stackframe.c
@@ -138,3 +138,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/x86/src/i486/up_stackframe.c b/nuttx/arch/x86/src/i486/up_stackframe.c
index fd93ac48f..4f2ee156a 100644
--- a/nuttx/arch/x86/src/i486/up_stackframe.c
+++ b/nuttx/arch/x86/src/i486/up_stackframe.c
@@ -139,3 +139,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/x86/src/qemu/Make.defs b/nuttx/arch/x86/src/qemu/Make.defs
index 86fe009ae..9d2d78f3b 100644
--- a/nuttx/arch/x86/src/qemu/Make.defs
+++ b/nuttx/arch/x86/src/qemu/Make.defs
@@ -46,7 +46,8 @@ CMN_CSRCS += up_initialize.c up_initialstate.c up_interruptcontext.c
CMN_CSRCS += up_irq.c up_modifyreg8.c up_modifyreg16.c up_modifyreg32.c
CMN_CSRCS += up_regdump.c up_releasepending.c up_releasestack.c
CMN_CSRCS += up_reprioritizertr.c up_savestate.c up_sigdeliver.c
-CMN_CSRCS += up_schedulesigaction.c up_unblocktask.c up_usestack.c
+CMN_CSRCS += up_schedulesigaction.c up_stackframe.c up_unblocktask.c
+CMN_CSRCS += up_usestack.c
# Required QEMU files
diff --git a/nuttx/arch/z16/src/common/up_stackframe.c b/nuttx/arch/z16/src/common/up_stackframe.c
index feb5c8578..8823034c4 100644
--- a/nuttx/arch/z16/src/common/up_stackframe.c
+++ b/nuttx/arch/z16/src/common/up_stackframe.c
@@ -137,3 +137,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/z16/src/z16f/Make.defs b/nuttx/arch/z16/src/z16f/Make.defs
index 8db9e8894..f14570fb6 100644
--- a/nuttx/arch/z16/src/z16f/Make.defs
+++ b/nuttx/arch/z16/src/z16f/Make.defs
@@ -41,7 +41,8 @@ CMN_CSRCS += up_assert.c up_initialstate.c up_sigdeliver.c up_blocktask.c
CMN_CSRCS += up_interruptcontext.c up_stackdump.c up_copystate.c
CMN_CSRCS += up_mdelay.c up_udelay.c up_createstack.c up_registerdump.c
CMN_CSRCS += up_unblocktask.c up_doirq.c up_releasepending.c up_usestack.c
-CMN_CSRCS += up_exit.c up_releasestack.c up_idle.c up_reprioritizertr.c
+CMN_CSRCS += up_exit.c up_releasestack.c up_stackframe.c up_idle.c
+CMN_CSRCS += up_reprioritizertr.c
CHIP_SSRCS = z16f_lowuart.S z16f_saveusercontext.S z16f_restoreusercontext.S
CHIP_CSRCS = z16f_clkinit.c z16f_sysexec.c z16f_irq.c z16f_serial.c
diff --git a/nuttx/arch/z80/src/common/up_stackframe.c b/nuttx/arch/z80/src/common/up_stackframe.c
index 1db0bf470..2c419c723 100644
--- a/nuttx/arch/z80/src/common/up_stackframe.c
+++ b/nuttx/arch/z80/src/common/up_stackframe.c
@@ -136,3 +136,4 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size)
return (FAR void *)(topaddr + sizeof(uint32_t));
}
+
diff --git a/nuttx/arch/z80/src/ez80/Make.defs b/nuttx/arch/z80/src/ez80/Make.defs
index 3ce0b4c42..4dbeed0f3 100644
--- a/nuttx/arch/z80/src/ez80/Make.defs
+++ b/nuttx/arch/z80/src/ez80/Make.defs
@@ -36,15 +36,16 @@
HEAD_ASRC = ez80_vectors.asm
HEAD_SSRC =
-CMN_SSRCS =
-CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c \
- up_releasestack.c up_interruptcontext.c up_blocktask.c \
- up_unblocktask.c up_exit.c up_releasepending.c \
- up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c \
- up_mdelay.c up_udelay.c up_usestack.c up_puts.c
+CMN_SSRCS =
+CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c
+CMN_CSRCS += up_releasestack.c up_interruptcontext.c up_blocktask.c
+CMN_CSRCS += up_unblocktask.c up_exit.c up_releasepending.c
+CMN_CSRCS += up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c
+CMN_CSRCS += up_mdelay.c up_stackframe.c up_udelay.c up_usestack.c
+CMN_CSRCS += up_puts.c
-CHIP_ASRCS = ez80_startup.asm ez80_io.asm ez80_irqsave.asm \
- ez80_saveusercontext.asm ez80_restorecontext.asm
+CHIP_ASRCS = ez80_startup.asm ez80_io.asm ez80_irqsave.asm
+ ez80_saveusercontext.asm ez80_restorecontext.asm
ifeq ($(CONFIG_ARCH_CHIP_EZ80F91),y)
CHIP_ASRCS += ez80f91_init.asm
endif
diff --git a/nuttx/arch/z80/src/z180/Make.defs b/nuttx/arch/z80/src/z180/Make.defs
index 3e8c4b7f4..0f71bb949 100644
--- a/nuttx/arch/z80/src/z180/Make.defs
+++ b/nuttx/arch/z80/src/z180/Make.defs
@@ -45,8 +45,8 @@ CMN_ASRCS =
CMN_CSRCS = up_allocateheap.c up_assert.c up_blocktask.c up_createstack.c
CMN_CSRCS += up_doirq.c up_exit.c up_idle.c up_initialize.c
CMN_CSRCS += up_interruptcontext.c up_mdelay.c up_releasepending.c
-CMN_CSRCS += up_releasestack.c up_reprioritizertr.c up_unblocktask.c
-CMN_CSRCS += up_udelay.c up_usestack.c
+CMN_CSRCS += up_releasestack.c up_stackframe.c up_reprioritizertr.c
+CMN_CSRCS += up_unblocktask.c up_udelay.c up_usestack.c
CHIP_ASRCS = z180_restoreusercontext.asm z180_saveusercontext.asm
CHIP_ASRCS += z180_vectcommon.asm
diff --git a/nuttx/arch/z80/src/z8/Make.defs b/nuttx/arch/z80/src/z8/Make.defs
index 50f1d98b0..7a7476aa4 100644
--- a/nuttx/arch/z80/src/z8/Make.defs
+++ b/nuttx/arch/z80/src/z8/Make.defs
@@ -35,12 +35,12 @@
HEAD_SSRC = z8_head.S
-CMN_SSRCS =
-CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c \
- up_releasestack.c up_interruptcontext.c up_blocktask.c \
- up_unblocktask.c up_exit.c up_releasepending.c \
- up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c \
- up_mdelay.c up_udelay.c up_usestack.c
+CMN_SSRCS =
+CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c
+CMN_CSRCS += up_releasestack.c up_interruptcontext.c up_blocktask.c
+CMN_CSRCS += up_unblocktask.c up_exit.c up_releasepending.c
+CMN_CSRCS += up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c
+CMN_CSRCS += up_mdelay.c up_stackframe.c up_udelay.c up_usestack.c
CHIP_SSRCS = z8_vector.S z8_saveusercontext.S z8_restorecontext.S
CHIP_CSRCS = z8_initialstate.c z8_irq.c z8_saveirqcontext.c
diff --git a/nuttx/arch/z80/src/z80/Make.defs b/nuttx/arch/z80/src/z80/Make.defs
index c60e88be6..485dc3bbc 100644
--- a/nuttx/arch/z80/src/z80/Make.defs
+++ b/nuttx/arch/z80/src/z80/Make.defs
@@ -35,21 +35,22 @@
ifeq ($(CONFIG_ARCH_HAVEHEAD),)
ifeq ($(CONFIG_LINKER_ROM_AT_0000),y)
-HEAD_ASRC = z80_rom.asm
+HEAD_ASRC = z80_rom.asm
else
-HEAD_ASRC = z80_head.asm
+HEAD_ASRC = z80_head.asm
endif
endif
-CMN_ASRCS =
-CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c \
- up_releasestack.c up_interruptcontext.c up_blocktask.c \
- up_unblocktask.c up_exit.c up_releasepending.c \
- up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c \
- up_mdelay.c up_udelay.c up_usestack.c
+CMN_ASRCS =
-CHIP_ASRCS = z80_saveusercontext.asm z80_restoreusercontext.asm
-CHIP_CSRCS = z80_initialstate.c z80_io.c z80_irq.c z80_copystate.c \
- z80_schedulesigaction.c z80_sigdeliver.c \
- z80_registerdump.c
+CMN_CSRCS = up_initialize.c up_allocateheap.c up_createstack.c
+CMN_CSRCS += up_releasestack.c up_interruptcontext.c up_blocktask.c
+CMN_CSRCS += up_unblocktask.c up_exit.c up_releasepending.c
+CMN_CSRCS += up_reprioritizertr.c up_idle.c up_assert.c up_doirq.c
+CMN_CSRCS += up_mdelay.c up_stackframe.c up_udelay.c up_usestack.c
+CHIP_ASRCS = z80_saveusercontext.asm z80_restoreusercontext.asm
+
+CHIP_CSRCS = z80_initialstate.c z80_io.c z80_irq.c z80_copystate.c
+CHIP_CSRCS += z80_schedulesigaction.c z80_sigdeliver.c
+CHIP_CSRCS += z80_registerdump.c
diff --git a/nuttx/include/nuttx/arch.h b/nuttx/include/nuttx/arch.h
index 724f59207..f60ec6d8d 100644
--- a/nuttx/include/nuttx/arch.h
+++ b/nuttx/include/nuttx/arch.h
@@ -277,7 +277,7 @@ int up_use_stack(FAR struct tcb_s *tcb, FAR void *stack, size_t stack_size);
*
* Description:
* Allocate a stack frame in the TCB's stack to hold thread-specific data.
- * This function may be called anytime after up_create_stack() or
+ * This function may be called any time after up_create_stack() or
* up_use_stack() have been called but before the task has been started.
*
* Thread data may be kept in the stack (instead of in the TCB) if it is
@@ -304,9 +304,7 @@ int up_use_stack(FAR struct tcb_s *tcb, FAR void *stack, size_t stack_size);
*
****************************************************************************/
-#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL)
FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size);
-#endif
/****************************************************************************
* Name: up_release_stack
diff --git a/nuttx/include/nuttx/sched.h b/nuttx/include/nuttx/sched.h
index 40442cc87..4b5d6b5a5 100644
--- a/nuttx/include/nuttx/sched.h
+++ b/nuttx/include/nuttx/sched.h
@@ -557,17 +557,7 @@ struct task_tcb_s
/* Values needed to restart a task ********************************************/
uint8_t init_priority; /* Initial priority of the task */
-
-#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL)
- /* In the kernel mode build, the arguments are saved on the task's stack */
-
FAR char **argv; /* Name+start-up parameters */
-#else
- /* Otherwise, the arguments are strdup'ed and the argv[] is statically */
- /* defined here: */
-
- char *argv[CONFIG_MAX_TASK_ARGS+1]; /* Name+start-up parameters */
-#endif
};
/* struct pthread_tcb_s **********************************************************/
diff --git a/nuttx/sched/sched/sched_releasetcb.c b/nuttx/sched/sched/sched_releasetcb.c
index 724e9e409..f731a2442 100644
--- a/nuttx/sched/sched/sched_releasetcb.c
+++ b/nuttx/sched/sched/sched_releasetcb.c
@@ -111,9 +111,6 @@ static void sched_releasepid(pid_t pid)
int sched_releasetcb(FAR struct tcb_s *tcb, uint8_t ttype)
{
int ret = OK;
-#if !defined(CONFIG_BUILD_PROTECTED) && !defined(CONFIG_BUILD_KERNEL)
- int i;
-#endif
if (tcb)
{
@@ -150,7 +147,7 @@ int sched_releasetcb(FAR struct tcb_s *tcb, uint8_t ttype)
up_release_stack(tcb, ttype);
}
- /* Delete the tasks's allocated DSpace region (external modules only) */
+ /* Delete the task's allocated DSpace region (external modules only) */
#ifdef CONFIG_PIC
if (tcb->dspace)
@@ -166,28 +163,6 @@ int sched_releasetcb(FAR struct tcb_s *tcb, uint8_t ttype)
}
#endif
-#if !defined(CONFIG_BUILD_PROTECTED) && !defined(CONFIG_BUILD_KERNEL)
- /* Release command line arguments that were allocated for task
- * start/re-start.
- *
- * NOTE: In the kernel mode build, the arguments were saved on
- * the task's stack and will be cleaned up when the stack memory
- * is released. Nothing need be done here in that case.
- */
-
-#ifndef CONFIG_DISABLE_PTHREAD
- if (ttype != TCB_FLAG_TTYPE_PTHREAD)
-#endif
- {
- FAR struct task_tcb_s *ttcb = (FAR struct task_tcb_s *)tcb;
- for (i = 1; i < CONFIG_MAX_TASK_ARGS+1 && ttcb->argv[i]; i++)
- {
- sched_kfree((FAR void*)ttcb->argv[i]);
- }
- }
-
-#endif /* !CONFIG_BUILD_PROTECTED && !CONFIG_BUILD_KERNEL */
-
/* Release this thread's reference to the address environment */
#ifdef CONFIG_ARCH_ADDRENV
diff --git a/nuttx/sched/task/task_setup.c b/nuttx/sched/task/task_setup.c
index 9ef1b0d39..bed71707b 100644
--- a/nuttx/sched/task/task_setup.c
+++ b/nuttx/sched/task/task_setup.c
@@ -1,7 +1,7 @@
/****************************************************************************
* sched/task/task_setup.c
*
- * Copyright (C) 2007-2013 Gregory Nutt. All rights reserved.
+ * Copyright (C) 2007-2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -427,97 +427,30 @@ static void task_namesetup(FAR struct task_tcb_s *tcb, FAR const char *name)
#endif /* CONFIG_TASK_NAME_SIZE */
/****************************************************************************
- * Name: task_tcbargsetup
- *
- * Description:
- * This functions is called only from task_argsetup() in the "normal"
- * case, where the argv[] array is a structure in the TCB. This function
- * will clone all of the arguments using strdup.
- *
- * Input Parameters:
- * tcb - Address of the new task's TCB
- * argv - A pointer to an array of input parameters.
- * Up to CONFIG_MAX_TASK_ARG parameters may be
- * provided. If fewer than CONFIG_MAX_TASK_ARG
- * parameters are passed, the list should be
- * terminated with a NULL argv[] value.
- * If no parameters are required, argv may be NULL.
- *
- * Return Value:
- * OK. This function always succeeds.
- *
- ****************************************************************************/
-
-#if !defined(CONFIG_BUILD_PROTECTED) && !defined(CONFIG_BUILD_KERNEL)
-static int task_tcbargsetup(FAR struct task_tcb_s *tcb,
- FAR char * const argv[])
-{
- int i;
-
- /* Save the name as the first argument */
-
-#if CONFIG_TASK_NAME_SIZE > 0
- tcb->argv[0] = tcb->cmn.name;
-#else
- tcb->argv[0] = (FAR char *)g_noname;
-#endif /* CONFIG_TASK_NAME_SIZE */
-
- /* For tasks, the life of the argument must be as long as the life of the
- * task and the arguments must be strings. So for tasks, we have to dup
- * the strings.
- *
- * The first NULL argument terminates the list of arguments. The argv
- * pointer may be NULL if no parameters are passed.
- */
-
- i = 1;
- if (argv)
- {
- for (; i < CONFIG_MAX_TASK_ARGS+1 && argv[i-1]; i++)
- {
- tcb->argv[i] = strdup(argv[i-1]);
- }
- }
-
- /* Nullify any unused argument storage */
-
- for (; i < CONFIG_MAX_TASK_ARGS+1; i++)
- {
- tcb->argv[i] = NULL;
- }
-
- return OK;
-}
-#endif /* !CONFIG_BUILD_PROTECTED && !CONFIG_BUILD_KERNEL */
-
-/****************************************************************************
* Name: task_stackargsetup
*
* Description:
- * This functions is called only from task_argsetup() for the case of the
- * kernel build where the argv[] array and all strings are copied to the
- * task's stack. This is done because the TCB (and kernel allocated
- * strings) are only accessible in kernel-mode. Data on the stack, on the
- * other hand, is guaranteed to be accessible no matter what mode the
- * task runs in.
+ * This functions is called only from task_argsetup() It will allocate
+ * space on the new task's stack and will copy the argv[] array and all
+ * strings to the task's stack where it is readily accessible to the
+ * task. Data on the stack, on the other hand, is guaranteed to be
+ * accessible no matter what privilege mode the task runs in.
*
* Input Parameters:
- * tcb - Address of the new task's TCB
- * argv - A pointer to an array of input parameters.
- * Up to CONFIG_MAX_TASK_ARG parameters may be
- * provided. If fewer than CONFIG_MAX_TASK_ARG
- * parameters are passed, the list should be
- * terminated with a NULL argv[] value.
- * If no parameters are required, argv may be NULL.
+ * tcb - Address of the new task's TCB
+ * argv - A pointer to an array of input parameters. Up to
+ * CONFIG_MAX_TASK_ARG parameters may be provided. If fewer than
+ * CONFIG_MAX_TASK_ARG parameters are passed, the list should be
+ * terminated with a NULL argv[] value. If no parameters are
+ * required, argv may be NULL.
*
* Return Value:
- * zero on success; a negated errno on failure.
+ * Zero (OK) on success; a negated errno on failure.
*
****************************************************************************/
-#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL)
-static int task_stackargsetup(FAR struct task_tcb_s *tcb,
- FAR char * const argv[])
+static inline int task_stackargsetup(FAR struct task_tcb_s *tcb,
+ FAR char * const argv[])
{
FAR char **stackargv;
FAR const char *name;
@@ -568,8 +501,8 @@ static int task_stackargsetup(FAR struct task_tcb_s *tcb,
* task name plus a NULL argv[] entry to terminate the list.
*/
- argvlen = (argc + 2)*sizeof(FAR char*);
- stackargv = (FAR char **)up_stack_frame(&tcb->cmn, argvlen + strtablen);
+ argvlen = (argc + 2)*sizeof(FAR char*);
+ stackargv = (FAR char **)up_stack_frame(&tcb->cmn, argvlen + strtablen);
DEBUGASSERT(stackargv != NULL);
if (stackargv == NULL)
@@ -581,7 +514,7 @@ static int task_stackargsetup(FAR struct task_tcb_s *tcb,
* the argv[] array and mark it as a null string.
*/
- str = (FAR char *)stackargv + argvlen;
+ str = (FAR char *)stackargv + argvlen;
/* Copy the task name. Increment str to skip over the task name and its
* NUL terminator in the string buffer.
@@ -617,7 +550,6 @@ static int task_stackargsetup(FAR struct task_tcb_s *tcb,
return OK;
}
-#endif /* CONFIG_BUILD_PROTECTED || CONFIG_BUILD_KERNEL */
/****************************************************************************
* Public Functions
@@ -736,30 +668,14 @@ int pthread_schedsetup(FAR struct pthread_tcb_s *tcb, int priority, start_t star
int task_argsetup(FAR struct task_tcb_s *tcb, FAR const char *name,
FAR char * const argv[])
{
- int ret;
-
/* Setup the task name */
task_namesetup(tcb, name);
-#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL)
- /* In the kernel build case, the argv[] array and all strings are copied
- * to the task's stack. This is done because the TCB (and kernel allocated
- * strings) are only accessible in kernel-mode. Data on the stack, on the
- * other hand, is guaranteed to be accessible no matter what mode the
- * task runs in.
+ /* Copy the argv[] array and all strings are to the task's stack. Data on
+ * the stack is guaranteed to be accessible by the ask no matter what
+ * privilege mode the task runs in.
*/
- ret = task_stackargsetup(tcb, argv);
-
-#else
- /* In the "normal" case, the argv[] array is a structure in the TCB, the
- * arguments are cloned via strdup.
- */
-
- ret = task_tcbargsetup(tcb, argv);
-
-#endif /* CONFIG_BUILD_PROTECTED || CONFIG_BUILD_KERNEL */
-
- return ret;
+ return task_stackargsetup(tcb, argv);
}