Introduce current_inferior_ptid
Make GDB's x86_linux_prepare_to_resume closer to gdbserver's
Add x86_debug_reg_state to gdbserver
Introduce current_inferior_pid
Make iterate_over_lwps be a shared function
Add a iterate_over_lwps to gdbserver
Use iterate_over_lwps in gdbserver