From 64fe463b9d7703f2621e2516fae9bd7736bb9897 Mon Sep 17 00:00:00 2001 From: patacongo Date: Sat, 9 Jul 2011 16:01:00 +0000 Subject: [PATCH] Redesign of NXTEXT font cache git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3761 42af7a65-404d-4744-a932-0658087f49c3 --- ChangeLog | 4 ++++ TODO | 1 + arch/arm/src/common/up_checkstack.c | 2 +- configs/stm3210e-eval/nxtext/defconfig | 6 +++--- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index a8b4d2712b..3b0f4905ca 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1883,3 +1883,7 @@ example. This example focuses on placing text on the background while pop-up windows occur. Text should continue to update normally with or without the popup windows present. + * arch/arm/src/common/up_checkstack.c: ARM stack overflow checking submitted + by Hal Glenn. + * arch/arm/src/lpc17xx: Changes to compile successfully with no serial console + (also submitted by Hal Glenn). diff --git a/TODO b/TODO index 24a9226dea..0ac42b5f42 100644 --- a/TODO +++ b/TODO @@ -1297,6 +1297,7 @@ o Other Applications & Tests (apps/examples/) it stops rendering. This is not a problem for the examples/nx code because it uses so few fonts, but if the logic were leveraged for more general purposes, it would be a problem. + Update: see examples/nxtext for some improved font cache handling. Status: Open Priority: Low. This is not really a problem becauses examples/nx works fine with its bogus font caching. diff --git a/arch/arm/src/common/up_checkstack.c b/arch/arm/src/common/up_checkstack.c index 27ac202345..6c13f63d13 100644 --- a/arch/arm/src/common/up_checkstack.c +++ b/arch/arm/src/common/up_checkstack.c @@ -104,7 +104,7 @@ size_t up_check_tcbstack(FAR _TCB *tcb) */ #if 0 - if (mark + 16 > tcb->adj_stack_size) + if (mark + 16 > tcb->adj_stack_size/4) { int i, j; diff --git a/configs/stm3210e-eval/nxtext/defconfig b/configs/stm3210e-eval/nxtext/defconfig index d9e0a63713..c828569534 100644 --- a/configs/stm3210e-eval/nxtext/defconfig +++ b/configs/stm3210e-eval/nxtext/defconfig @@ -967,8 +967,8 @@ CONFIG_EXAMPLES_NX_EXTERNINIT=n # for, for example, SPI LCD/OLED devices. # CONFIG_EXAMPLES_NXTEXT_BMCACHE - The maximum number of characters that # can be put in the background window. Default is 128. -# CONFIG_EXAMPLES_NXTEXT_GLCACHE - The maximum nuber of pre-rendered -# fonts that can be retained for the background window. +# CONFIG_EXAMPLES_NXTEXT_GLCACHE - The maximum number of pre-rendered +# fonts that can be retained for the background window. Default is 16. # CONFIG_EXAMPLES_NXTEXT_STACKSIZE -- The stacksize to use when creating # the NX server. Default 2048 # CONFIG_EXAMPLES_NXTEXT_CLIENTPRIO -- The client priority. Default: 100 @@ -987,7 +987,7 @@ CONFIG_EXAMPLES_NXTEXT_PUFONTCOLOR=0x001f CONFIG_EXAMPLES_NXTEXT_BPP=16 CONFIG_EXAMPLES_NXTEXT_EXTERNINIT=n CONFIG_EXAMPLES_NXTEXT_BMCACHE=512 -CONFIG_EXAMPLES_NXTEXT_GLCACHE=128 +CONFIG_EXAMPLES_NXTEXT_GLCACHE=16 CONFIG_EXAMPLES_NXTEXT_STACKSIZE=2048 CONFIG_EXAMPLES_NXTEXT_CLIENTPRIO=80 CONFIG_EXAMPLES_NXTEXT_SERVERPRIO=120