From 7ab326bbb406504d0ae528af8a06b8456201b6a6 Mon Sep 17 00:00:00 2001 From: patacongo Date: Mon, 15 Jun 2009 21:44:27 +0000 Subject: Add conditional compilation to eliminate or limit cloning of descriptors when a new task is created git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1886 42af7a65-404d-4744-a932-0658087f49c3 --- nuttx/configs/mcu123-lpc214x/nsh/defconfig | 30 ++++++++++++++++++++ nuttx/configs/mcu123-lpc214x/ostest/defconfig | 34 +++++++++++++++++++++++ nuttx/configs/mcu123-lpc214x/usbserial/defconfig | 30 ++++++++++++++++++++ nuttx/configs/mcu123-lpc214x/usbstorage/defconfig | 30 ++++++++++++++++++++ 4 files changed, 124 insertions(+) (limited to 'nuttx/configs/mcu123-lpc214x') diff --git a/nuttx/configs/mcu123-lpc214x/nsh/defconfig b/nuttx/configs/mcu123-lpc214x/nsh/defconfig index f7a65c730..0f93d81fb 100644 --- a/nuttx/configs/mcu123-lpc214x/nsh/defconfig +++ b/nuttx/configs/mcu123-lpc214x/nsh/defconfig @@ -173,6 +173,31 @@ CONFIG_HAVE_LIBM=n # errorcheck mutexes. Enables pthread_mutexattr_settype(). # CONFIG_PRIORITY_INHERITANCE : Set to enable support for priority # inheritance on mutexes and semaphores. +# CONFIG_SEM_PREALLOCHOLDERS: This setting is only used if priority +# inheritance is enabled. It defines the maximum number of +# different threads (minus one) that can take counts on a +# semaphore with priority inheritance support. This may be +# set to zero if priority inheritance is disabled OR if you +# are only using semaphores as mutexes (only one holder) OR +# if no more than two threads participate using a counting +# semaphore. +# CONFIG_SEM_NNESTPRIO. If priority inheritance is enabled, +# then this setting is the maximum number of higher priority +# threads (minus 1) than can be waiting for another thread +# to release a count on a semaphore. This value may be set +# to zero if no more than one thread is expected to wait for +# a semaphore. +# CONFIG_FDCLONE_DISABLE. Disable cloning of all file descriptors +# by task_create() when a new task is started. If set, all +# files/drivers will appear to be closed in the new task. +# CONFIG_FDCLONE_STDIO. Disable cloning of all but the first +# three file descriptors (stdin, stdout, stderr) by task_create() +# when a new task is started. If set, all files/drivers will +# appear to be closed in the new task except for stdin, stdout, +# and stderr. +# CONFIG_SDCLONE_DISABLE. Disable cloning of all socket +# desciptors by task_create() when a new task is started. If +# set, all sockets will appear to be closed in the new task. # CONFIG_EXAMPLE=nsh CONFIG_DEBUG=n @@ -190,6 +215,11 @@ CONFIG_DEV_CONSOLE=y CONFIG_DEV_LOWCONSOLE=n CONFIG_MUTEX_TYPES=n CONFIG_PRIORITY_INHERITANCE=n +CONFIG_SEM_PREALLOCHOLDERS=0 +CONFIG_SEM_NNESTPRIO=0 +CONFIG_FDCLONE_DISABLE=n +CONFIG_FDCLONE_STDIO=n +CONFIG_SDCLONE_DISABLE=y # # The following can be used to disable categories of diff --git a/nuttx/configs/mcu123-lpc214x/ostest/defconfig b/nuttx/configs/mcu123-lpc214x/ostest/defconfig index 98f9f34b1..b29d84b44 100644 --- a/nuttx/configs/mcu123-lpc214x/ostest/defconfig +++ b/nuttx/configs/mcu123-lpc214x/ostest/defconfig @@ -169,6 +169,35 @@ CONFIG_HAVE_LIBM=n # provides /dev/console. Enables stdout, stderr, stdin. # CONFIG_DEV_LOWCONSOLE - Use the simple, low-level serial console # driver (minimul support) +# CONFIG_MUTEX_TYPES: Set to enable support for recursive and +# errorcheck mutexes. Enables pthread_mutexattr_settype(). +# CONFIG_PRIORITY_INHERITANCE : Set to enable support for priority +# inheritance on mutexes and semaphores. +# CONFIG_SEM_PREALLOCHOLDERS: This setting is only used if priority +# inheritance is enabled. It defines the maximum number of +# different threads (minus one) that can take counts on a +# semaphore with priority inheritance support. This may be +# set to zero if priority inheritance is disabled OR if you +# are only using semaphores as mutexes (only one holder) OR +# if no more than two threads participate using a counting +# semaphore. +# CONFIG_SEM_NNESTPRIO. If priority inheritance is enabled, +# then this setting is the maximum number of higher priority +# threads (minus 1) than can be waiting for another thread +# to release a count on a semaphore. This value may be set +# to zero if no more than one thread is expected to wait for +# a semaphore. +# CONFIG_FDCLONE_DISABLE. Disable cloning of all file descriptors +# by task_create() when a new task is started. If set, all +# files/drivers will appear to be closed in the new task. +# CONFIG_FDCLONE_STDIO. Disable cloning of all but the first +# three file descriptors (stdin, stdout, stderr) by task_create() +# when a new task is started. If set, all files/drivers will +# appear to be closed in the new task except for stdin, stdout, +# and stderr. +# CONFIG_SDCLONE_DISABLE. Disable cloning of all socket +# desciptors by task_create() when a new task is started. If +# set, all sockets will appear to be closed in the new task. # CONFIG_EXAMPLE=ostest CONFIG_DEBUG=n @@ -186,6 +215,11 @@ CONFIG_DEV_CONSOLE=y CONFIG_DEV_LOWCONSOLE=y CONFIG_MUTEX_TYPES=n CONFIG_PRIORITY_INHERITANCE=n +CONFIG_SEM_PREALLOCHOLDERS=0 +CONFIG_SEM_NNESTPRIO=0 +CONFIG_FDCLONE_DISABLE=n +CONFIG_FDCLONE_STDIO=n +CONFIG_SDCLONE_DISABLE=y # # The following can be used to disable categories of diff --git a/nuttx/configs/mcu123-lpc214x/usbserial/defconfig b/nuttx/configs/mcu123-lpc214x/usbserial/defconfig index 60bf4e5ae..1d2784d2e 100644 --- a/nuttx/configs/mcu123-lpc214x/usbserial/defconfig +++ b/nuttx/configs/mcu123-lpc214x/usbserial/defconfig @@ -173,6 +173,31 @@ CONFIG_HAVE_LIBM=n # errorcheck mutexes. Enables pthread_mutexattr_settype(). # CONFIG_PRIORITY_INHERITANCE : Set to enable support for priority # inheritance on mutexes and semaphores. +# CONFIG_SEM_PREALLOCHOLDERS: This setting is only used if priority +# inheritance is enabled. It defines the maximum number of +# different threads (minus one) that can take counts on a +# semaphore with priority inheritance support. This may be +# set to zero if priority inheritance is disabled OR if you +# are only using semaphores as mutexes (only one holder) OR +# if no more than two threads participate using a counting +# semaphore. +# CONFIG_SEM_NNESTPRIO. If priority inheritance is enabled, +# then this setting is the maximum number of higher priority +# threads (minus 1) than can be waiting for another thread +# to release a count on a semaphore. This value may be set +# to zero if no more than one thread is expected to wait for +# a semaphore. +# CONFIG_FDCLONE_DISABLE. Disable cloning of all file descriptors +# by task_create() when a new task is started. If set, all +# files/drivers will appear to be closed in the new task. +# CONFIG_FDCLONE_STDIO. Disable cloning of all but the first +# three file descriptors (stdin, stdout, stderr) by task_create() +# when a new task is started. If set, all files/drivers will +# appear to be closed in the new task except for stdin, stdout, +# and stderr. +# CONFIG_SDCLONE_DISABLE. Disable cloning of all socket +# desciptors by task_create() when a new task is started. If +# set, all sockets will appear to be closed in the new task. # CONFIG_EXAMPLE=usbserial CONFIG_DEBUG=n @@ -191,6 +216,11 @@ CONFIG_DEV_CONSOLE=y CONFIG_DEV_LOWCONSOLE=n CONFIG_MUTEX_TYPES=n CONFIG_PRIORITY_INHERITANCE=n +CONFIG_SEM_PREALLOCHOLDERS=0 +CONFIG_SEM_NNESTPRIO=0 +CONFIG_FDCLONE_DISABLE=n +CONFIG_FDCLONE_STDIO=n +CONFIG_SDCLONE_DISABLE=y # # The following can be used to disable categories of diff --git a/nuttx/configs/mcu123-lpc214x/usbstorage/defconfig b/nuttx/configs/mcu123-lpc214x/usbstorage/defconfig index 8394375a6..be3cf97e8 100644 --- a/nuttx/configs/mcu123-lpc214x/usbstorage/defconfig +++ b/nuttx/configs/mcu123-lpc214x/usbstorage/defconfig @@ -173,6 +173,31 @@ CONFIG_HAVE_LIBM=n # errorcheck mutexes. Enables pthread_mutexattr_settype(). # CONFIG_PRIORITY_INHERITANCE : Set to enable support for priority # inheritance on mutexes and semaphores. +# CONFIG_SEM_PREALLOCHOLDERS: This setting is only used if priority +# inheritance is enabled. It defines the maximum number of +# different threads (minus one) that can take counts on a +# semaphore with priority inheritance support. This may be +# set to zero if priority inheritance is disabled OR if you +# are only using semaphores as mutexes (only one holder) OR +# if no more than two threads participate using a counting +# semaphore. +# CONFIG_SEM_NNESTPRIO. If priority inheritance is enabled, +# then this setting is the maximum number of higher priority +# threads (minus 1) than can be waiting for another thread +# to release a count on a semaphore. This value may be set +# to zero if no more than one thread is expected to wait for +# a semaphore. +# CONFIG_FDCLONE_DISABLE. Disable cloning of all file descriptors +# by task_create() when a new task is started. If set, all +# files/drivers will appear to be closed in the new task. +# CONFIG_FDCLONE_STDIO. Disable cloning of all but the first +# three file descriptors (stdin, stdout, stderr) by task_create() +# when a new task is started. If set, all files/drivers will +# appear to be closed in the new task except for stdin, stdout, +# and stderr. +# CONFIG_SDCLONE_DISABLE. Disable cloning of all socket +# desciptors by task_create() when a new task is started. If +# set, all sockets will appear to be closed in the new task. # CONFIG_EXAMPLE=usbstorage CONFIG_DEBUG=n @@ -191,6 +216,11 @@ CONFIG_DEV_CONSOLE=y CONFIG_DEV_LOWCONSOLE=n CONFIG_MUTEX_TYPES=n CONFIG_PRIORITY_INHERITANCE=n +CONFIG_SEM_PREALLOCHOLDERS=0 +CONFIG_SEM_NNESTPRIO=0 +CONFIG_FDCLONE_DISABLE=n +CONFIG_FDCLONE_STDIO=n +CONFIG_SDCLONE_DISABLE=y # # The following can be used to disable categories of -- cgit v1.2.3