-linux_nat_add_target (struct target_ops *t)
-{
- /* Save the provided single-threaded target. We save this in a separate
- variable because another target we've inherited from (e.g. inf-ptrace)
- may have saved a pointer to T; we want to use it for the final
- process stratum target. */
- linux_ops_saved = *t;
- linux_ops = &linux_ops_saved;
-
- /* Override some methods for multithreading. */
- t->to_create_inferior = linux_nat_create_inferior;
- t->to_attach = linux_nat_attach;
- t->to_detach = linux_nat_detach;
- t->to_resume = linux_nat_resume;
- t->to_wait = linux_nat_wait;
- t->to_pass_signals = linux_nat_pass_signals;
- t->to_xfer_partial = linux_nat_xfer_partial;
- t->to_kill = linux_nat_kill;
- t->to_mourn_inferior = linux_nat_mourn_inferior;
- t->to_thread_alive = linux_nat_thread_alive;
- t->to_update_thread_list = linux_nat_update_thread_list;
- t->to_pid_to_str = linux_nat_pid_to_str;
- t->to_thread_name = linux_nat_thread_name;
- t->to_has_thread_control = tc_schedlock;
- t->to_thread_address_space = linux_nat_thread_address_space;
- t->to_stopped_by_watchpoint = linux_nat_stopped_by_watchpoint;
- t->to_stopped_data_address = linux_nat_stopped_data_address;
- t->to_stopped_by_sw_breakpoint = linux_nat_stopped_by_sw_breakpoint;
- t->to_supports_stopped_by_sw_breakpoint = linux_nat_supports_stopped_by_sw_breakpoint;
- t->to_stopped_by_hw_breakpoint = linux_nat_stopped_by_hw_breakpoint;
- t->to_supports_stopped_by_hw_breakpoint = linux_nat_supports_stopped_by_hw_breakpoint;
-
- t->to_can_async_p = linux_nat_can_async_p;
- t->to_is_async_p = linux_nat_is_async_p;
- t->to_supports_non_stop = linux_nat_supports_non_stop;
- t->to_always_non_stop_p = linux_nat_always_non_stop_p;
- t->to_async = linux_nat_async;
- t->to_terminal_inferior = linux_nat_terminal_inferior;
- t->to_terminal_ours = linux_nat_terminal_ours;
-
- super_close = t->to_close;
- t->to_close = linux_nat_close;
-
- t->to_stop = linux_nat_stop;
- t->to_interrupt = linux_nat_interrupt;
-
- t->to_supports_multi_process = linux_nat_supports_multi_process;
-
- t->to_supports_disable_randomization
- = linux_nat_supports_disable_randomization;
-
- t->to_core_of_thread = linux_nat_core_of_thread;
-
- t->to_filesystem_is_local = linux_nat_filesystem_is_local;
- t->to_fileio_open = linux_nat_fileio_open;
- t->to_fileio_readlink = linux_nat_fileio_readlink;
- t->to_fileio_unlink = linux_nat_fileio_unlink;