diff --git a/kernel/Kconfig b/kernel/Kconfig index 54e0ccf1f2d897..0553161eca1ee7 100644 --- a/kernel/Kconfig +++ b/kernel/Kconfig @@ -245,8 +245,9 @@ if DYNAMIC_THREAD config DYNAMIC_THREAD_STACK_SIZE int "Size of each pre-allocated thread stack" - default 1024 if !64BIT - default 2048 if 64BIT + default 4096 if X86 + default 1024 if !X86 && !64BIT + default 2048 if !X86 && 64BIT help Default stack size (in bytes) for dynamic threads. diff --git a/tests/posix/common/boards/qemu_x86.conf b/tests/posix/common/boards/qemu_x86.conf deleted file mode 100644 index 2fa43926ee48f8..00000000000000 --- a/tests/posix/common/boards/qemu_x86.conf +++ /dev/null @@ -1 +0,0 @@ -CONFIG_DYNAMIC_THREAD_STACK_SIZE=4096 diff --git a/tests/posix/common/boards/qemu_x86_64.conf b/tests/posix/common/boards/qemu_x86_64.conf deleted file mode 100644 index 2fa43926ee48f8..00000000000000 --- a/tests/posix/common/boards/qemu_x86_64.conf +++ /dev/null @@ -1 +0,0 @@ -CONFIG_DYNAMIC_THREAD_STACK_SIZE=4096 diff --git a/tests/posix/common/boards/qemu_x86_tiny.conf b/tests/posix/common/boards/qemu_x86_tiny.conf new file mode 100644 index 00000000000000..01506ce9f553c2 --- /dev/null +++ b/tests/posix/common/boards/qemu_x86_tiny.conf @@ -0,0 +1,16 @@ +# Copyright (c) 2021 Intel Corporation +# SPDX-License-Identifier: Apache-2.0 + +# The test is highly sensitive to size of kernel image. +# However, specifying how many pages used by +# the backing store must be done in build time. +# So here we are, tuning this manually. +CONFIG_BACKING_STORE_RAM_PAGES=12 + +# The following is needed so that .text and following +# sections are present in physical memory to test +# using backing store for anonymous memory. +CONFIG_KERNEL_VM_BASE=0x0 +CONFIG_LINKER_GENERIC_SECTIONS_PRESENT_AT_BOOT=y +CONFIG_BACKING_STORE_RAM=y +CONFIG_BACKING_STORE_QEMU_X86_TINY_FLASH=n diff --git a/tests/posix/common/boards/qemu_x86_tiny.overlay b/tests/posix/common/boards/qemu_x86_tiny.overlay new file mode 100644 index 00000000000000..f717f3ff7edc76 --- /dev/null +++ b/tests/posix/common/boards/qemu_x86_tiny.overlay @@ -0,0 +1,11 @@ +/* + * Copyright (c) 2024, Tenstorrent AI ULC + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/ { + dram0: memory@0 { + reg = <0x100000 0x80000>; + }; +};