MFC r255844:
Ensure that the ERESTART return from the syscall reloads the registers,
to make the restarted syscall instruction pass the correct arguments.

PR:	kern/182161
MFC r255891:

Import NetBSD readline.c,v 1.104: do not crash with add_history(NULL).