1 diff --git a/coregrind/m_syswrap/syswrap-amd64-linux.c b/coregrind/m_syswrap/syswrap-amd64-linux.c
2 index 0f2ad8c51..407af7f76 100644
3 --- a/coregrind/m_syswrap/syswrap-amd64-linux.c
4 +++ b/coregrind/m_syswrap/syswrap-amd64-linux.c
5 @@ -249,6 +249,7 @@ PRE(sys_rt_sigreturn)
9 + Bool known_option = True;
10 PRINT( "arch_prctl ( %ld, %lx )", SARG1, ARG2 );
12 vg_assert(VG_(is_valid_tid)(tid));
13 @@ -283,13 +284,16 @@ PRE(sys_arch_prctl)
14 POST_MEM_WRITE(ARG2, sizeof(unsigned long));
17 - VG_(core_panic)("Unsupported arch_prctl option");
18 + known_option = False;
21 /* Note; the Status writeback to guest state that happens after
22 this wrapper returns does not change guest_FS_CONST or guest_GS_CONST;
23 hence that direct assignment to the guest state is safe here. */
24 - SET_STATUS_Success( 0 );
26 + SET_STATUS_Success( 0 );
28 + SET_STATUS_Failure( VKI_EINVAL );
31 // Parts of this are amd64-specific, but the *PEEK* cases are generic.