Well, if you can do it, I guess I can too...
Someone who knows x86 asm better than I can change everything in uaccess.h
to always return 0, like so:
#define copy_from_user(to, from, n) \
({ \
/* Returns non-zero only if hit fault handler */ \
if (general_copy_user((to), (from), (n))) \
memset(to, 0, n); \
0; \
})
So the fault handler sends a SIGSEGV, and makes generic_copy_user return 1
immediately (if you were ambitious, it could do the memset too).
If someone wants to write the asm for that, I'll fix the SEGV delivery code
and mount option reading (two places where we must not deliver a signal),
and we can see what it looks like.
Cheers,
Rusty.
-- there are those who do and those who hang on and you don't see too many doers quoting their contemporaries. -- Larry McVoy - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/