2018-04-05 22:41:15 +05:30
|
|
|
# Copyright (c) 2018 Intel Corporation
|
2023-07-03 15:15:35 -04:00
|
|
|
# Copyright (c) 2023 Meta
|
|
|
|
#
|
2018-04-05 22:41:15 +05:30
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
2024-01-24 13:28:45 -05:00
|
|
|
menu "POSIX API Support"
|
|
|
|
|
2019-11-01 10:24:07 +01:00
|
|
|
config POSIX_MAX_FDS
|
2018-10-08 13:55:03 +03:00
|
|
|
int "Maximum number of open file descriptors"
|
2023-10-20 15:36:56 +03:00
|
|
|
default 16 if WIFI_NM_WPA_SUPPLICANT
|
2018-10-08 13:55:03 +03:00
|
|
|
default 16 if POSIX_API
|
|
|
|
default 4
|
|
|
|
help
|
|
|
|
Maximum number of open file descriptors, this includes
|
|
|
|
files, sockets, special devices, etc.
|
|
|
|
|
2018-09-27 18:08:12 +03:00
|
|
|
config POSIX_API
|
2023-05-31 17:09:25 +02:00
|
|
|
depends on !NATIVE_APPLICATION
|
2018-09-27 18:08:12 +03:00
|
|
|
bool "POSIX APIs"
|
|
|
|
help
|
|
|
|
Enable mostly-standards-compliant implementations of
|
|
|
|
various POSIX (IEEE 1003.1) APIs.
|
|
|
|
|
2019-05-06 16:50:24 +03:00
|
|
|
# The name of this option is mandated by zephyr_interface_library_named
|
|
|
|
# cmake directive.
|
|
|
|
config APP_LINK_WITH_POSIX_SUBSYS
|
2019-11-01 10:24:07 +01:00
|
|
|
bool "Make POSIX headers available to application"
|
|
|
|
default y
|
kconfig: Replace some single-symbol 'if's with 'depends on'
I think people might be reading differences into 'if' and 'depends on'
that aren't there, like maybe 'if' being needed to "hide" a symbol,
while 'depends on' just adds a dependency.
There are no differences between 'if' and 'depends on'. 'if' is just a
shorthand for 'depends on'. They work the same when it comes to creating
implicit menus too.
The way symbols get "hidden" is through their dependencies not being
satisfied ('if'/'depends on' get copied up as a dependency on the
prompt).
Since 'if' and 'depends on' are the same, an 'if' with just a single
symbol in it can be replaced with a 'depends on'. IMO, it's best to
avoid 'if' there as a style choice too, because it confuses people into
thinking there's deep Kconfig magic going on that requires 'if'.
Going for 'depends on' can also remove some nested 'if's, which
generates nicer symbol information and docs, because nested 'if's really
are so simple/dumb that they just add the dependencies from both 'if's
to all symbols within.
Replace a bunch of single-symbol 'if's with 'depends on' to despam the
Kconfig files a bit and make it clearer how things work. Also do some
other minor related dependency refactoring.
The replacement isn't complete. Will fix up the rest later. Splitting it
a bit to make it more manageable.
(Everything above is true for choices, menus, and comments as well.)
Detected by tweaking the Kconfiglib parsing code. It's impossible to
detect after parsing, because 'if' turns into 'depends on'.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2020-02-08 03:45:50 +01:00
|
|
|
depends on POSIX_API
|
2019-11-01 10:24:07 +01:00
|
|
|
help
|
|
|
|
Add POSIX subsystem header files to the 'app' include path.
|
2019-11-05 16:09:42 +01:00
|
|
|
|
2023-07-03 15:15:35 -04:00
|
|
|
config PTHREAD_IPC
|
|
|
|
bool "POSIX pthread IPC API"
|
2022-10-28 15:31:06 -04:00
|
|
|
default y if POSIX_API
|
2023-07-03 15:15:35 -04:00
|
|
|
depends on POSIX_CLOCK
|
2019-11-05 16:09:42 +01:00
|
|
|
help
|
2023-07-03 15:15:35 -04:00
|
|
|
This enables a mostly-standards-compliant implementation of
|
|
|
|
the pthread mutex, condition variable and barrier IPC
|
|
|
|
mechanisms.
|
2023-02-25 08:03:11 -05:00
|
|
|
|
2024-01-11 21:31:59 +01:00
|
|
|
config POSIX_SYSCONF
|
|
|
|
bool "Support for sysconf"
|
|
|
|
default y if POSIX_API
|
|
|
|
help
|
|
|
|
The sysconf() function provides a method for the application to determine
|
|
|
|
the current value of a configurable system limit or option (variable).
|
|
|
|
|
|
|
|
config POSIX_PAGE_SIZE_BITS
|
|
|
|
int "Number of bits to use for PAGE_SIZE"
|
|
|
|
range 6 16
|
|
|
|
default 12 if POSIX_API
|
|
|
|
default 6
|
|
|
|
help
|
|
|
|
Define PAGE_SIZE as BIT(n), where n is the value configured here.
|
|
|
|
PAGE_SIZE is supported in the range [64, 65536]
|
|
|
|
If CONFIG_POSIX_API=y, PAGE_SIZE defaults to 4096, otherwise, it is 64 bytes.
|
|
|
|
|
2023-07-03 15:15:35 -04:00
|
|
|
source "lib/posix/Kconfig.barrier"
|
|
|
|
source "lib/posix/Kconfig.clock"
|
|
|
|
source "lib/posix/Kconfig.cond"
|
|
|
|
source "lib/posix/Kconfig.eventfd"
|
|
|
|
source "lib/posix/Kconfig.fnmatch"
|
|
|
|
source "lib/posix/Kconfig.fs"
|
|
|
|
source "lib/posix/Kconfig.getopt"
|
|
|
|
source "lib/posix/Kconfig.key"
|
2023-07-18 13:00:59 +08:00
|
|
|
source "lib/posix/Kconfig.limits"
|
2023-07-03 15:15:35 -04:00
|
|
|
source "lib/posix/Kconfig.mqueue"
|
|
|
|
source "lib/posix/Kconfig.mutex"
|
|
|
|
source "lib/posix/Kconfig.pthread"
|
2024-01-15 23:37:58 -05:00
|
|
|
source "lib/posix/Kconfig.rwlock"
|
2023-12-27 21:56:15 +01:00
|
|
|
source "lib/posix/Kconfig.sched"
|
2023-07-03 15:15:35 -04:00
|
|
|
source "lib/posix/Kconfig.semaphore"
|
2023-07-08 22:09:25 +08:00
|
|
|
source "lib/posix/Kconfig.signal"
|
2023-07-03 15:15:35 -04:00
|
|
|
source "lib/posix/Kconfig.spinlock"
|
|
|
|
source "lib/posix/Kconfig.timer"
|
2023-07-04 15:15:15 +08:00
|
|
|
source "lib/posix/Kconfig.uname"
|
2024-01-16 14:33:12 +08:00
|
|
|
|
|
|
|
rsource "shell/Kconfig"
|
2024-01-24 13:28:45 -05:00
|
|
|
|
|
|
|
endmenu # "POSIX API Support"
|