[PATCH 09/12] fsdosfssync01: Stack size for bdbuf SMP workaround
Gedare Bloom
gedare at rtems.org
Tue May 27 15:04:25 UTC 2014
On Tue, May 27, 2014 at 10:47 AM, Ralf Kirchner
<ralf.kirchner at embedded-brains.de> wrote:
> Increase the size of the init task stack for the SMP workaround within bdbuf.
> ---
> testsuites/fstests/fsdosfssync01/init.c | 12 ++++++++++++
> 1 Datei geändert, 12 Zeilen hinzugefügt(+)
>
> diff --git a/testsuites/fstests/fsdosfssync01/init.c b/testsuites/fstests/fsdosfssync01/init.c
> index b0022e9..022cd2b 100644
> --- a/testsuites/fstests/fsdosfssync01/init.c
> +++ b/testsuites/fstests/fsdosfssync01/init.c
> @@ -170,6 +170,18 @@ size_t rtems_ramdisk_configuration_size = 1;
>
> #define CONFIGURE_EXTRA_TASK_STACKS (8 * 1024)
>
> +
> +#if defined( RTEMS_SMP )
> + #if defined( RTEMS_POSIX_API )
> + /* The single core bdbuf implementation with enabling and disabling preemption
> + * will not work under SMP. Thus we need to use POSIX mutexes and POSIX
> + * condition variables as a workaround.
> + * These require additional stack size.
> + */
> + #define CONFIGURE_INIT_TASK_STACK_SIZE (2 * CPU_STACK_MINIMUM_SIZE)
> + #endif /* defined( RTEMS_POSIX_API ) */
> +#endif /* defined( RTEMS_SMP ) */
> +
This kind of hack in the application configuration is not very
user-friendly. You should adjust for the required resources in
confdefs.h instead, by configuring for the required mutexes/condvars
explicitly.
> #define CONFIGURE_INITIAL_EXTENSIONS RTEMS_TEST_INITIAL_EXTENSION
>
> #define CONFIGURE_RTEMS_INIT_TASKS_TABLE
> --
> 1.7.10.4
>
> _______________________________________________
> rtems-devel mailing list
> rtems-devel at rtems.org
> http://www.rtems.org/mailman/listinfo/rtems-devel
More information about the devel
mailing list