summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--nuttx/ChangeLog6
-rw-r--r--nuttx/configs/stm3240g-eval/README.txt18
-rw-r--r--nuttx/graphics/nxbe/nxbe_clipper.c2
-rw-r--r--nuttx/graphics/nxbe/nxbe_closewindow.c12
-rw-r--r--nuttx/graphics/nxsu/nx_close.c4
-rw-r--r--nuttx/graphics/nxsu/nx_constructwindow.c2
-rw-r--r--nuttx/graphics/nxsu/nx_open.c6
-rw-r--r--nuttx/graphics/nxsu/nx_openwindow.c6
-rw-r--r--nuttx/libnx/nxmu/nx_connect.c4
-rw-r--r--nuttx/libnx/nxmu/nx_constructwindow.c2
-rw-r--r--nuttx/libnx/nxmu/nx_eventhandler.c2
-rw-r--r--nuttx/libnx/nxmu/nx_openwindow.c2
-rw-r--r--nuttx/libnx/nxtk/nxtk_openwindow.c2
13 files changed, 40 insertions, 28 deletions
diff --git a/nuttx/ChangeLog b/nuttx/ChangeLog
index 9bd1473fe..d0ff108d9 100644
--- a/nuttx/ChangeLog
+++ b/nuttx/ChangeLog
@@ -6345,5 +6345,7 @@
* Moved configs/stm3240g-eval/src/up_cxxinitialize.c to
apps/platform/stm3240g-eval/up_cxxinitialize.c: Now it is available
in user-space in the kernel mode build (2013-12-29).
-
-
+ * graphics/nxbe, nxsu, libnx/nxmu, and nxtk: Need to be consistent with
+ which allocator is used in the different configurations. Always uses
+ the user-space allocator because that one is required in certain
+ configurations (2013-12-30).
diff --git a/nuttx/configs/stm3240g-eval/README.txt b/nuttx/configs/stm3240g-eval/README.txt
index a933884cc..9780e791b 100644
--- a/nuttx/configs/stm3240g-eval/README.txt
+++ b/nuttx/configs/stm3240g-eval/README.txt
@@ -49,7 +49,7 @@ GNU Toolchain Options
Most testing has been conducted using the CodeSourcery toolchain for Windows and
that is the default toolchain in most configurations (FPU-related testing has
- been performed with the Atolloc toolchain for windows. To use the Atollic,
+ been performed with the Atollic toolchain for windows. To use the Atollic,
devkitARM, Raisonance GNU, or NuttX buildroot toolchain, you simply need to
add one of the following configuration options to your .config (or defconfig)
file:
@@ -115,7 +115,7 @@ GNU Toolchain Options
The Atollic "Lite" Toolchain
----------------------------
The free, "Lite" version of the Atollic toolchain does not support C++ nor
- does it support ar, nm, objdump, or objdcopy. If you use the Atollic "Lite"
+ does it support ar, nm, objdump, or objcopy. If you use the Atollic "Lite"
toolchain, you will have to set:
CONFIG_HAVE_CXX=n
@@ -162,7 +162,7 @@ IDEs
2) Start the NuttX build at least one time from the Cygwin command line
before trying to create your project. This is necessary to create
certain auto-generated files and directories that will be needed.
- 3) Set up include pathes: You will need include/, arch/arm/src/stm32,
+ 3) Set up include paths: You will need include/, arch/arm/src/stm32,
arch/arm/src/common, arch/arm/src/armv7-m, and sched/.
4) All assembly files need to have the definition option -D __ASSEMBLY__
on the command line.
@@ -304,7 +304,7 @@ events as follows:
* If LED1, LED2, LED3 are statically on, then NuttX probably failed to boot
and these LEDs will give you some indication of where the failure was
** The normal state is LED3 ON and LED1 faintly glowing. This faint glow
- is because of timer interupts that result in the LED being illuminated
+ is because of timer interrupts that result in the LED being illuminated
on a small proportion of the time.
*** LED2 may also flicker normally if signals are processed.
@@ -331,7 +331,7 @@ the LCD).
ACCESS:
- Daughterboard Extension Connector, CN3, pin 32
+ Daughter board Extension Connector, CN3, pin 32
Ground is available on CN3, pin1
NOTE: TIM4 hardware will not support pulse counting.
@@ -670,7 +670,7 @@ STM3240G-EVAL-specific Configuration Options
CONFIG_ARCH_CALIBRATION - Enables some build in instrumentation that
cause a 100 second delay during boot-up. This 100 second delay
- serves no purpose other than it allows you to calibratre
+ serves no purpose other than it allows you to calibrate
CONFIG_ARCH_LOOPSPERMSEC. You simply use a stop watch to measure
the 100 second delay then adjust CONFIG_ARCH_LOOPSPERMSEC until
the delay actually is 100 seconds.
@@ -805,7 +805,7 @@ STM3240G-EVAL-specific Configuration Options
CONFIG_STM32_MII_MCO1 - Use MCO1 to clock the MII interface
CONFIG_STM32_MII_MCO2 - Use MCO2 to clock the MII interface
CONFIG_STM32_RMII - Support Ethernet RMII interface
- CONFIG_STM32_AUTONEG - Use PHY autonegotion to determine speed and mode
+ CONFIG_STM32_AUTONEG - Use PHY autonegotiation to determine speed and mode
CONFIG_STM32_ETHFD - If CONFIG_STM32_AUTONEG is not defined, then this
may be defined to select full duplex mode. Default: half-duplex
CONFIG_STM32_ETH100MBPS - If CONFIG_STM32_AUTONEG is not defined, then this
@@ -1067,7 +1067,7 @@ Where <subdir> is one of the following:
-------
This configuration directory may be used to verify networking performance
- using the STM32's Ethernet controller. It uses apps/examples/nettest to excercise the
+ using the STM32's Ethernet controller. It uses apps/examples/nettest to exercise the
TCP/IP network.
CONFIG_EXAMPLES_NETTEST_SERVER=n : Target is configured as the client
@@ -1409,7 +1409,7 @@ Where <subdir> is one of the following:
Here is the quick summary of the build steps (Assuming that all of
the required packages are available in a directory ~/nuttx-code):
- 1. Intall the nxwm configuration
+ 1. Install the nxwm configuration
$ cd ~/nuttx-code/nuttx/tools
$ ./configure.sh stm3240g-eval/nxwm
diff --git a/nuttx/graphics/nxbe/nxbe_clipper.c b/nuttx/graphics/nxbe/nxbe_clipper.c
index 1c33dd243..4b7293ae6 100644
--- a/nuttx/graphics/nxbe/nxbe_clipper.c
+++ b/nuttx/graphics/nxbe/nxbe_clipper.c
@@ -110,7 +110,7 @@ static inline void nxbe_pushrectangle(FAR struct nxbe_clipstack_s *stack,
if ((stack->npushed + 1) > stack->mxrects)
{
- /* No then we will need to reallocate the stack to hole more */
+ /* No then we will need to reallocate the stack to hold more */
int mxrects = stack->mxrects ? 2 * stack->mxrects : NX_INITIAL_STACKSIZE;
struct nxbe_cliprect_s *newstack;
diff --git a/nuttx/graphics/nxbe/nxbe_closewindow.c b/nuttx/graphics/nxbe/nxbe_closewindow.c
index e632ebf01..09c47af22 100644
--- a/nuttx/graphics/nxbe/nxbe_closewindow.c
+++ b/nuttx/graphics/nxbe/nxbe_closewindow.c
@@ -39,11 +39,12 @@
#include <nuttx/config.h>
-#include <stdlib.h>
#include <assert.h>
#include <debug.h>
+#include <nuttx/kmalloc.h>
#include <nuttx/nx/nxglib.h>
+
#include "nxbe.h"
/****************************************************************************
@@ -77,7 +78,8 @@
* Close an existing window
*
* Input Parameters:
- * wnd - The window to be closed (and deallocated)
+ * wnd - The window to be closed (and deallocated using the user-space
+ * allocator)
*
* Return:
* None
@@ -131,7 +133,9 @@ void nxbe_closewindow(struct nxbe_window_s *wnd)
nxbe_redrawbelow(be, wnd->below, &wnd->bounds);
- /* Then discard the window structure */
+ /* Then discard the window structure. Here we assume that the user-space
+ * allocator was used.
+ */
- free(wnd);
+ umm_free(wnd);
}
diff --git a/nuttx/graphics/nxsu/nx_close.c b/nuttx/graphics/nxsu/nx_close.c
index c1b9d1537..848513b5c 100644
--- a/nuttx/graphics/nxsu/nx_close.c
+++ b/nuttx/graphics/nxsu/nx_close.c
@@ -88,6 +88,8 @@
void nx_close(NXHANDLE handle)
{
- kfree(handle);
+ /* For consistency, we use the user-space allocate (if available) */
+
+ umm_free(handle);
}
diff --git a/nuttx/graphics/nxsu/nx_constructwindow.c b/nuttx/graphics/nxsu/nx_constructwindow.c
index 6a0595181..1be780a2a 100644
--- a/nuttx/graphics/nxsu/nx_constructwindow.c
+++ b/nuttx/graphics/nxsu/nx_constructwindow.c
@@ -116,7 +116,7 @@ int nx_constructwindow(NXHANDLE handle, NXWINDOW wnd,
if (!fe || !cb)
{
- kfree(wnd);
+ umm_free(wnd);
errno = EINVAL;
return ERROR;
}
diff --git a/nuttx/graphics/nxsu/nx_open.c b/nuttx/graphics/nxsu/nx_open.c
index d8efcee41..4866f15ce 100644
--- a/nuttx/graphics/nxsu/nx_open.c
+++ b/nuttx/graphics/nxsu/nx_open.c
@@ -195,9 +195,11 @@ NXHANDLE nx_open(FAR NX_DRIVERTYPE *dev)
}
#endif
- /* Allocate the NX state structure */
+ /* Allocate the NX state structure. The user-space allocator is used
+ * (if available) for compatibility with the multi-user implementation.
+ */
- fe = (FAR struct nxfe_state_s *)kzalloc(sizeof(struct nxfe_state_s));
+ fe = (FAR struct nxfe_state_s *)umm_zalloc(sizeof(struct nxfe_state_s));
if (!fe)
{
errno = ENOMEM;
diff --git a/nuttx/graphics/nxsu/nx_openwindow.c b/nuttx/graphics/nxsu/nx_openwindow.c
index b1e632937..d085ad03e 100644
--- a/nuttx/graphics/nxsu/nx_openwindow.c
+++ b/nuttx/graphics/nxsu/nx_openwindow.c
@@ -103,9 +103,11 @@ NXWINDOW nx_openwindow(NXHANDLE handle, FAR const struct nx_callback_s *cb,
}
#endif
- /* Pre-allocate the window structure */
+ /* Pre-allocate the window structure. The user-space allocator is used (if
+ * available) for compatibility with the multi-user implementation.
+ */
- wnd = (FAR struct nxbe_window_s *)kzalloc(sizeof(struct nxbe_window_s));
+ wnd = (FAR struct nxbe_window_s *)umm_zalloc(sizeof(struct nxbe_window_s));
if (!wnd)
{
errno = ENOMEM;
diff --git a/nuttx/libnx/nxmu/nx_connect.c b/nuttx/libnx/nxmu/nx_connect.c
index 7a9241f3b..07cf7a751 100644
--- a/nuttx/libnx/nxmu/nx_connect.c
+++ b/nuttx/libnx/nxmu/nx_connect.c
@@ -132,7 +132,7 @@ NXHANDLE nx_connectinstance(FAR const char *svrmqname)
/* Allocate the NX client structure */
- conn = (FAR struct nxfe_conn_s *)lib_zalloc(sizeof(struct nxfe_conn_s));
+ conn = (FAR struct nxfe_conn_s *)lib_uzalloc(sizeof(struct nxfe_conn_s));
if (!conn)
{
set_errno(ENOMEM);
@@ -215,7 +215,7 @@ errout_with_wmq:
errout_with_rmq:
mq_close(conn->crdmq);
errout_with_conn:
- lib_free(conn);
+ lib_ufree(conn);
errout:
return NULL;
}
diff --git a/nuttx/libnx/nxmu/nx_constructwindow.c b/nuttx/libnx/nxmu/nx_constructwindow.c
index 76e038202..677706e18 100644
--- a/nuttx/libnx/nxmu/nx_constructwindow.c
+++ b/nuttx/libnx/nxmu/nx_constructwindow.c
@@ -117,7 +117,7 @@ int nx_constructwindow(NXHANDLE handle, NXWINDOW hwnd,
if (!conn || !cb)
{
- lib_free(wnd);
+ lib_ufree(wnd);
set_errno(EINVAL);
return ERROR;
}
diff --git a/nuttx/libnx/nxmu/nx_eventhandler.c b/nuttx/libnx/nxmu/nx_eventhandler.c
index 26d7f9dee..338f5de4e 100644
--- a/nuttx/libnx/nxmu/nx_eventhandler.c
+++ b/nuttx/libnx/nxmu/nx_eventhandler.c
@@ -99,7 +99,7 @@ static inline void nx_disconnected(FAR struct nxfe_conn_s *conn)
/* And free the client structure */
- lib_free(conn);
+ lib_ufree(conn);
}
/****************************************************************************
diff --git a/nuttx/libnx/nxmu/nx_openwindow.c b/nuttx/libnx/nxmu/nx_openwindow.c
index d09a329ad..5100a3b9a 100644
--- a/nuttx/libnx/nxmu/nx_openwindow.c
+++ b/nuttx/libnx/nxmu/nx_openwindow.c
@@ -105,7 +105,7 @@ NXWINDOW nx_openwindow(NXHANDLE handle, FAR const struct nx_callback_s *cb,
/* Pre-allocate the window structure */
- wnd = (FAR struct nxbe_window_s *)lib_zalloc(sizeof(struct nxbe_window_s));
+ wnd = (FAR struct nxbe_window_s *)lib_uzalloc(sizeof(struct nxbe_window_s));
if (!wnd)
{
set_errno(ENOMEM);
diff --git a/nuttx/libnx/nxtk/nxtk_openwindow.c b/nuttx/libnx/nxtk/nxtk_openwindow.c
index 5c9426359..c7c050b8d 100644
--- a/nuttx/libnx/nxtk/nxtk_openwindow.c
+++ b/nuttx/libnx/nxtk/nxtk_openwindow.c
@@ -131,7 +131,7 @@ NXTKWINDOW nxtk_openwindow(NXHANDLE handle,
/* Pre-allocate the window structure */
fwnd = (FAR struct nxtk_framedwindow_s *)
- lib_zalloc(sizeof(struct nxtk_framedwindow_s));
+ lib_uzalloc(sizeof(struct nxtk_framedwindow_s));
if (!fwnd)
{