Skip to content

Commit 79c7962

Browse files
masayuki2009xiaoxiang781216
authored andcommitted
apps: Replace CONFIG_ARCH_HAVE_VFORK with CONFIG_ARCH_HAVE_FORK
Summary: - Resolves an issue where `vfork_test` was not executed following the renaming from CONFIG_ARCH_HAVE_VFORK to CONFIG_ARCH_HAVE_FORK, as detailed in apache/nuttx#9755. Impact: - Please merge apache/nuttx#11200 before merging this PR. Testing: - Successfully tested with rv-virt:smp64, spresense:smp, and sim:smp. Signed-off-by: Masayuki Ishikawa <[email protected]>
1 parent 144bf0b commit 79c7962

File tree

7 files changed

+9
-9
lines changed

7 files changed

+9
-9
lines changed

interpreters/bas/Kconfig

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ config INTERPRETER_BAS_HAVE_FTRUNCATE
7272
config EXAMPLES_BAS_SHELL
7373
bool "Shell support"
7474
default n
75-
depends on ARCH_HAVE_VFORK && EXPERIMENTAL
75+
depends on ARCH_HAVE_FORK && EXPERIMENTAL
7676
select LIBC_EXECFUNCS
7777
select SCHED_WAITPID
7878
---help---

interpreters/bas/bas_statement.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -1051,7 +1051,7 @@ struct Value *stmt_DOcondition(struct Value *value)
10511051

10521052
struct Value *stmt_EDIT(struct Value *value)
10531053
{
1054-
#if defined(CONFIG_EXAMPLES_BAS_EDITOR) && defined(CONFIG_EXAMPLES_BAS_SHELL) && defined(CONFIG_ARCH_HAVE_VFORK)
1054+
#if defined(CONFIG_EXAMPLES_BAS_EDITOR) && defined(CONFIG_EXAMPLES_BAS_SHELL) && defined(CONFIG_ARCH_HAVE_FORK)
10551055
long int line;
10561056
struct Pc statementpc = g_pc;
10571057
int status;
@@ -5674,7 +5674,7 @@ struct Value *stmt_SELECTCASE(struct Value *value)
56745674

56755675
struct Value *stmt_SHELL(struct Value *value)
56765676
{
5677-
#if defined(CONFIG_EXAMPLES_BAS_SHELL) && defined(CONFIG_ARCH_HAVE_VFORK)
5677+
#if defined(CONFIG_EXAMPLES_BAS_SHELL) && defined(CONFIG_ARCH_HAVE_FORK)
56785678
pid_t pid;
56795679
int status;
56805680

testing/ostest/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ if(CONFIG_TESTING_OSTEST)
122122
endif()
123123
endif()
124124

125-
if(CONFIG_ARCH_HAVE_VFORK)
125+
if(CONFIG_ARCH_HAVE_FORK)
126126
if(CONFIG_SCHED_WAITPID)
127127
list(APPEND SRCS vfork.c)
128128
endif()

testing/ostest/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ CSRCS += sigev_thread.c
123123
endif
124124
endif
125125

126-
ifeq ($(CONFIG_ARCH_HAVE_VFORK),y)
126+
ifeq ($(CONFIG_ARCH_HAVE_FORK),y)
127127
ifeq ($(CONFIG_SCHED_WAITPID),y)
128128
CSRCS += vfork.c
129129
endif

testing/ostest/ostest.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ void sched_lock_test(void);
256256

257257
/* vfork.c ******************************************************************/
258258

259-
#if defined(CONFIG_ARCH_HAVE_VFORK) && defined(CONFIG_SCHED_WAITPID)
259+
#if defined(CONFIG_ARCH_HAVE_FORK) && defined(CONFIG_SCHED_WAITPID)
260260
int vfork_test(void);
261261
#endif
262262

testing/ostest/ostest_main.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -580,7 +580,7 @@ static int user_main(int argc, char *argv[])
580580
check_test_memory_usage();
581581
#endif
582582

583-
#if defined(CONFIG_ARCH_HAVE_VFORK) && defined(CONFIG_SCHED_WAITPID)
583+
#if defined(CONFIG_ARCH_HAVE_FORK) && defined(CONFIG_SCHED_WAITPID)
584584
printf("\nuser_main: vfork() test\n");
585585
vfork_test();
586586
#endif

testing/ostest/vfork.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333

3434
#include "ostest.h"
3535

36-
#if defined(CONFIG_ARCH_HAVE_VFORK) && defined(CONFIG_SCHED_WAITPID)
36+
#if defined(CONFIG_ARCH_HAVE_FORK) && defined(CONFIG_SCHED_WAITPID)
3737

3838
/****************************************************************************
3939
* Private Data
@@ -84,4 +84,4 @@ int vfork_test(void)
8484
return 0;
8585
}
8686

87-
#endif /* CONFIG_ARCH_HAVE_VFORK && CONFIG_SCHED_WAITPID */
87+
#endif /* CONFIG_ARCH_HAVE_FORK && CONFIG_SCHED_WAITPID */

0 commit comments

Comments
 (0)