RFC: ptrace: Enabling PTRACE_{GET,SET}REGSET calls withoutCONFIG_HAVE_ARCH_TRACEHOOK

From: Dave Martin
Date: Fri Apr 01 2011 - 12:47:33 EST


Hi all,

I notice in kernel/ptrace.c that the generic regset ptrace calls
PTRACE_GETREGSET and PTRACE_SETREGSET are predicated on
CONFIG_HAVE_ARCH_TRACEHOOK.

However, if I'm reading the code correctly then all these calls
really depend on is regsets implemented in the target arch.

Since I'm separately proposing a regsets implementation for ARM,
it would be nice to enable these ptrace calls; but I don't think
we're ready to enable CONFIG_HAVE_ARCH_TRACEHOOK there for now.

Does anyone know whether it would be safe/straightforward to
change the #ifdef in kernel/ptrace.c to something else,
such as CORE_DUMP_USE_REGSET? I think all arches which implement
regsets define this, though I haven't researched this thoroughly.

Any views welcome.

Cheers
---Dave
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/