1 /* Target-dependent code for GNU/Linux, architecture independent.
3 Copyright (C) 2009-2012 Free Software Foundation, Inc.
5 This file is part of GDB.
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3 of the License, or
10 (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */
22 #include "linux-tdep.h"
25 #include "gdbthread.h"
29 #include "elf/common.h"
30 #include "elf-bfd.h" /* for elfcore_write_* */
32 #include "cli/cli-utils.h"
36 static struct gdbarch_data
*linux_gdbarch_data_handle
;
38 struct linux_gdbarch_data
40 struct type
*siginfo_type
;
44 init_linux_gdbarch_data (struct gdbarch
*gdbarch
)
46 return GDBARCH_OBSTACK_ZALLOC (gdbarch
, struct linux_gdbarch_data
);
49 static struct linux_gdbarch_data
*
50 get_linux_gdbarch_data (struct gdbarch
*gdbarch
)
52 return gdbarch_data (gdbarch
, linux_gdbarch_data_handle
);
55 /* This function is suitable for architectures that don't
56 extend/override the standard siginfo structure. */
59 linux_get_siginfo_type (struct gdbarch
*gdbarch
)
61 struct linux_gdbarch_data
*linux_gdbarch_data
;
62 struct type
*int_type
, *uint_type
, *long_type
, *void_ptr_type
;
63 struct type
*uid_type
, *pid_type
;
64 struct type
*sigval_type
, *clock_type
;
65 struct type
*siginfo_type
, *sifields_type
;
68 linux_gdbarch_data
= get_linux_gdbarch_data (gdbarch
);
69 if (linux_gdbarch_data
->siginfo_type
!= NULL
)
70 return linux_gdbarch_data
->siginfo_type
;
72 int_type
= arch_integer_type (gdbarch
, gdbarch_int_bit (gdbarch
),
74 uint_type
= arch_integer_type (gdbarch
, gdbarch_int_bit (gdbarch
),
76 long_type
= arch_integer_type (gdbarch
, gdbarch_long_bit (gdbarch
),
78 void_ptr_type
= lookup_pointer_type (builtin_type (gdbarch
)->builtin_void
);
81 sigval_type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_UNION
);
82 TYPE_NAME (sigval_type
) = xstrdup ("sigval_t");
83 append_composite_type_field (sigval_type
, "sival_int", int_type
);
84 append_composite_type_field (sigval_type
, "sival_ptr", void_ptr_type
);
87 pid_type
= arch_type (gdbarch
, TYPE_CODE_TYPEDEF
,
88 TYPE_LENGTH (int_type
), "__pid_t");
89 TYPE_TARGET_TYPE (pid_type
) = int_type
;
90 TYPE_TARGET_STUB (pid_type
) = 1;
93 uid_type
= arch_type (gdbarch
, TYPE_CODE_TYPEDEF
,
94 TYPE_LENGTH (uint_type
), "__uid_t");
95 TYPE_TARGET_TYPE (uid_type
) = uint_type
;
96 TYPE_TARGET_STUB (uid_type
) = 1;
99 clock_type
= arch_type (gdbarch
, TYPE_CODE_TYPEDEF
,
100 TYPE_LENGTH (long_type
), "__clock_t");
101 TYPE_TARGET_TYPE (clock_type
) = long_type
;
102 TYPE_TARGET_STUB (clock_type
) = 1;
105 sifields_type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_UNION
);
108 const int si_max_size
= 128;
110 int size_of_int
= gdbarch_int_bit (gdbarch
) / HOST_CHAR_BIT
;
113 if (gdbarch_ptr_bit (gdbarch
) == 64)
114 si_pad_size
= (si_max_size
/ size_of_int
) - 4;
116 si_pad_size
= (si_max_size
/ size_of_int
) - 3;
117 append_composite_type_field (sifields_type
, "_pad",
118 init_vector_type (int_type
, si_pad_size
));
122 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
123 append_composite_type_field (type
, "si_pid", pid_type
);
124 append_composite_type_field (type
, "si_uid", uid_type
);
125 append_composite_type_field (sifields_type
, "_kill", type
);
128 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
129 append_composite_type_field (type
, "si_tid", int_type
);
130 append_composite_type_field (type
, "si_overrun", int_type
);
131 append_composite_type_field (type
, "si_sigval", sigval_type
);
132 append_composite_type_field (sifields_type
, "_timer", type
);
135 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
136 append_composite_type_field (type
, "si_pid", pid_type
);
137 append_composite_type_field (type
, "si_uid", uid_type
);
138 append_composite_type_field (type
, "si_sigval", sigval_type
);
139 append_composite_type_field (sifields_type
, "_rt", type
);
142 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
143 append_composite_type_field (type
, "si_pid", pid_type
);
144 append_composite_type_field (type
, "si_uid", uid_type
);
145 append_composite_type_field (type
, "si_status", int_type
);
146 append_composite_type_field (type
, "si_utime", clock_type
);
147 append_composite_type_field (type
, "si_stime", clock_type
);
148 append_composite_type_field (sifields_type
, "_sigchld", type
);
151 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
152 append_composite_type_field (type
, "si_addr", void_ptr_type
);
153 append_composite_type_field (sifields_type
, "_sigfault", type
);
156 type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
157 append_composite_type_field (type
, "si_band", long_type
);
158 append_composite_type_field (type
, "si_fd", int_type
);
159 append_composite_type_field (sifields_type
, "_sigpoll", type
);
162 siginfo_type
= arch_composite_type (gdbarch
, NULL
, TYPE_CODE_STRUCT
);
163 TYPE_NAME (siginfo_type
) = xstrdup ("siginfo");
164 append_composite_type_field (siginfo_type
, "si_signo", int_type
);
165 append_composite_type_field (siginfo_type
, "si_errno", int_type
);
166 append_composite_type_field (siginfo_type
, "si_code", int_type
);
167 append_composite_type_field_aligned (siginfo_type
,
168 "_sifields", sifields_type
,
169 TYPE_LENGTH (long_type
));
171 linux_gdbarch_data
->siginfo_type
= siginfo_type
;
177 linux_has_shared_address_space (void)
179 /* Determine whether we are running on uClinux or normal Linux
182 int target_is_uclinux
;
185 = (target_auxv_search (¤t_target
, AT_NULL
, &dummy
) > 0
186 && target_auxv_search (¤t_target
, AT_PAGESZ
, &dummy
) == 0);
188 return target_is_uclinux
;
191 /* This is how we want PTIDs from core files to be printed. */
194 linux_core_pid_to_str (struct gdbarch
*gdbarch
, ptid_t ptid
)
198 if (ptid_get_lwp (ptid
) != 0)
200 snprintf (buf
, sizeof (buf
), "LWP %ld", ptid_get_lwp (ptid
));
204 return normal_pid_to_str (ptid
);
207 /* Service function for corefiles and info proc. */
210 read_mapping (const char *line
,
211 ULONGEST
*addr
, ULONGEST
*endaddr
,
212 const char **permissions
, size_t *permissions_len
,
214 const char **device
, size_t *device_len
,
216 const char **filename
)
218 const char *p
= line
;
220 *addr
= strtoulst (p
, &p
, 16);
223 *endaddr
= strtoulst (p
, &p
, 16);
225 while (*p
&& isspace (*p
))
228 while (*p
&& !isspace (*p
))
230 *permissions_len
= p
- *permissions
;
232 *offset
= strtoulst (p
, &p
, 16);
234 while (*p
&& isspace (*p
))
237 while (*p
&& !isspace (*p
))
239 *device_len
= p
- *device
;
241 *inode
= strtoulst (p
, &p
, 10);
243 while (*p
&& isspace (*p
))
248 /* Implement the "info proc" command. */
251 linux_info_proc (struct gdbarch
*gdbarch
, char *args
,
252 enum info_proc_what what
)
254 /* A long is used for pid instead of an int to avoid a loss of precision
255 compiler warning from the output of strtoul. */
257 int cmdline_f
= (what
== IP_MINIMAL
|| what
== IP_CMDLINE
|| what
== IP_ALL
);
258 int cwd_f
= (what
== IP_MINIMAL
|| what
== IP_CWD
|| what
== IP_ALL
);
259 int exe_f
= (what
== IP_MINIMAL
|| what
== IP_EXE
|| what
== IP_ALL
);
260 int mappings_f
= (what
== IP_MAPPINGS
|| what
== IP_ALL
);
261 int status_f
= (what
== IP_STATUS
|| what
== IP_ALL
);
262 int stat_f
= (what
== IP_STAT
|| what
== IP_ALL
);
267 if (args
&& isdigit (args
[0]))
268 pid
= strtoul (args
, &args
, 10);
271 if (!target_has_execution
)
272 error (_("No current process: you must name one."));
273 if (current_inferior ()->fake_pid_p
)
274 error (_("Can't determine the current process's PID: you must name one."));
276 pid
= current_inferior ()->pid
;
279 args
= skip_spaces (args
);
281 error (_("Too many parameters: %s"), args
);
283 printf_filtered (_("process %ld\n"), pid
);
286 xsnprintf (filename
, sizeof filename
, "/proc/%ld/cmdline", pid
);
287 data
= target_fileio_read_stralloc (filename
);
290 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
291 printf_filtered ("cmdline = '%s'\n", data
);
292 do_cleanups (cleanup
);
295 warning (_("unable to open /proc file '%s'"), filename
);
299 xsnprintf (filename
, sizeof filename
, "/proc/%ld/cwd", pid
);
300 data
= target_fileio_readlink (filename
, &target_errno
);
303 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
304 printf_filtered ("cwd = '%s'\n", data
);
305 do_cleanups (cleanup
);
308 warning (_("unable to read link '%s'"), filename
);
312 xsnprintf (filename
, sizeof filename
, "/proc/%ld/exe", pid
);
313 data
= target_fileio_readlink (filename
, &target_errno
);
316 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
317 printf_filtered ("exe = '%s'\n", data
);
318 do_cleanups (cleanup
);
321 warning (_("unable to read link '%s'"), filename
);
325 xsnprintf (filename
, sizeof filename
, "/proc/%ld/maps", pid
);
326 data
= target_fileio_read_stralloc (filename
);
329 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
332 printf_filtered (_("Mapped address spaces:\n\n"));
333 if (gdbarch_addr_bit (gdbarch
) == 32)
335 printf_filtered ("\t%10s %10s %10s %10s %s\n",
338 " Size", " Offset", "objfile");
342 printf_filtered (" %18s %18s %10s %10s %s\n",
345 " Size", " Offset", "objfile");
348 for (line
= strtok (data
, "\n"); line
; line
= strtok (NULL
, "\n"))
350 ULONGEST addr
, endaddr
, offset
, inode
;
351 const char *permissions
, *device
, *filename
;
352 size_t permissions_len
, device_len
;
354 read_mapping (line
, &addr
, &endaddr
,
355 &permissions
, &permissions_len
,
356 &offset
, &device
, &device_len
,
359 if (gdbarch_addr_bit (gdbarch
) == 32)
361 printf_filtered ("\t%10s %10s %10s %10s %s\n",
362 paddress (gdbarch
, addr
),
363 paddress (gdbarch
, endaddr
),
364 hex_string (endaddr
- addr
),
366 *filename
? filename
: "");
370 printf_filtered (" %18s %18s %10s %10s %s\n",
371 paddress (gdbarch
, addr
),
372 paddress (gdbarch
, endaddr
),
373 hex_string (endaddr
- addr
),
375 *filename
? filename
: "");
379 do_cleanups (cleanup
);
382 warning (_("unable to open /proc file '%s'"), filename
);
386 xsnprintf (filename
, sizeof filename
, "/proc/%ld/status", pid
);
387 data
= target_fileio_read_stralloc (filename
);
390 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
391 puts_filtered (data
);
392 do_cleanups (cleanup
);
395 warning (_("unable to open /proc file '%s'"), filename
);
399 xsnprintf (filename
, sizeof filename
, "/proc/%ld/stat", pid
);
400 data
= target_fileio_read_stralloc (filename
);
403 struct cleanup
*cleanup
= make_cleanup (xfree
, data
);
404 const char *p
= data
;
408 printf_filtered (_("Process: %s\n"),
409 pulongest (strtoulst (p
, &p
, 10)));
411 while (*p
&& isspace (*p
))
413 if (*p
== '(' && (ep
= strchr (p
, ')')) != NULL
)
415 printf_filtered ("Exec file: %.*s\n", (int) (ep
- p
- 1), p
+ 1);
419 while (*p
&& isspace (*p
))
422 printf_filtered (_("State: %c\n"), *p
++);
425 printf_filtered (_("Parent process: %s\n"),
426 pulongest (strtoulst (p
, &p
, 10)));
428 printf_filtered (_("Process group: %s\n"),
429 pulongest (strtoulst (p
, &p
, 10)));
431 printf_filtered (_("Session id: %s\n"),
432 pulongest (strtoulst (p
, &p
, 10)));
434 printf_filtered (_("TTY: %s\n"),
435 pulongest (strtoulst (p
, &p
, 10)));
437 printf_filtered (_("TTY owner process group: %s\n"),
438 pulongest (strtoulst (p
, &p
, 10)));
441 printf_filtered (_("Flags: %s\n"),
442 hex_string (strtoulst (p
, &p
, 10)));
444 printf_filtered (_("Minor faults (no memory page): %s\n"),
445 pulongest (strtoulst (p
, &p
, 10)));
447 printf_filtered (_("Minor faults, children: %s\n"),
448 pulongest (strtoulst (p
, &p
, 10)));
450 printf_filtered (_("Major faults (memory page faults): %s\n"),
451 pulongest (strtoulst (p
, &p
, 10)));
453 printf_filtered (_("Major faults, children: %s\n"),
454 pulongest (strtoulst (p
, &p
, 10)));
456 printf_filtered (_("utime: %s\n"),
457 pulongest (strtoulst (p
, &p
, 10)));
459 printf_filtered (_("stime: %s\n"),
460 pulongest (strtoulst (p
, &p
, 10)));
462 printf_filtered (_("utime, children: %s\n"),
463 pulongest (strtoulst (p
, &p
, 10)));
465 printf_filtered (_("stime, children: %s\n"),
466 pulongest (strtoulst (p
, &p
, 10)));
468 printf_filtered (_("jiffies remaining in current "
470 pulongest (strtoulst (p
, &p
, 10)));
472 printf_filtered (_("'nice' value: %s\n"),
473 pulongest (strtoulst (p
, &p
, 10)));
475 printf_filtered (_("jiffies until next timeout: %s\n"),
476 pulongest (strtoulst (p
, &p
, 10)));
478 printf_filtered (_("jiffies until next SIGALRM: %s\n"),
479 pulongest (strtoulst (p
, &p
, 10)));
481 printf_filtered (_("start time (jiffies since "
482 "system boot): %s\n"),
483 pulongest (strtoulst (p
, &p
, 10)));
485 printf_filtered (_("Virtual memory size: %s\n"),
486 pulongest (strtoulst (p
, &p
, 10)));
488 printf_filtered (_("Resident set size: %s\n"),
489 pulongest (strtoulst (p
, &p
, 10)));
491 printf_filtered (_("rlim: %s\n"),
492 pulongest (strtoulst (p
, &p
, 10)));
494 printf_filtered (_("Start of text: %s\n"),
495 hex_string (strtoulst (p
, &p
, 10)));
497 printf_filtered (_("End of text: %s\n"),
498 hex_string (strtoulst (p
, &p
, 10)));
500 printf_filtered (_("Start of stack: %s\n"),
501 hex_string (strtoulst (p
, &p
, 10)));
502 #if 0 /* Don't know how architecture-dependent the rest is...
503 Anyway the signal bitmap info is available from "status". */
505 printf_filtered (_("Kernel stack pointer: %s\n"),
506 hex_string (strtoulst (p
, &p
, 10)));
508 printf_filtered (_("Kernel instr pointer: %s\n"),
509 hex_string (strtoulst (p
, &p
, 10)));
511 printf_filtered (_("Pending signals bitmap: %s\n"),
512 hex_string (strtoulst (p
, &p
, 10)));
514 printf_filtered (_("Blocked signals bitmap: %s\n"),
515 hex_string (strtoulst (p
, &p
, 10)));
517 printf_filtered (_("Ignored signals bitmap: %s\n"),
518 hex_string (strtoulst (p
, &p
, 10)));
520 printf_filtered (_("Catched signals bitmap: %s\n"),
521 hex_string (strtoulst (p
, &p
, 10)));
523 printf_filtered (_("wchan (system call): %s\n"),
524 hex_string (strtoulst (p
, &p
, 10)));
526 do_cleanups (cleanup
);
529 warning (_("unable to open /proc file '%s'"), filename
);
533 /* Determine which signal stopped execution. */
536 find_signalled_thread (struct thread_info
*info
, void *data
)
538 if (info
->suspend
.stop_signal
!= TARGET_SIGNAL_0
539 && ptid_get_pid (info
->ptid
) == ptid_get_pid (inferior_ptid
))
545 static enum target_signal
546 find_stop_signal (void)
548 struct thread_info
*info
=
549 iterate_over_threads (find_signalled_thread
, NULL
);
552 return info
->suspend
.stop_signal
;
554 return TARGET_SIGNAL_0
;
557 /* Generate corefile notes for SPU contexts. */
560 linux_spu_make_corefile_notes (bfd
*obfd
, char *note_data
, int *note_size
)
562 static const char *spu_files
[] =
584 enum bfd_endian byte_order
= gdbarch_byte_order (target_gdbarch
);
588 /* Determine list of SPU ids. */
589 size
= target_read_alloc (¤t_target
, TARGET_OBJECT_SPU
,
592 /* Generate corefile notes for each SPU file. */
593 for (i
= 0; i
< size
; i
+= 4)
595 int fd
= extract_unsigned_integer (spu_ids
+ i
, 4, byte_order
);
597 for (j
= 0; j
< sizeof (spu_files
) / sizeof (spu_files
[0]); j
++)
599 char annex
[32], note_name
[32];
603 xsnprintf (annex
, sizeof annex
, "%d/%s", fd
, spu_files
[j
]);
604 spu_len
= target_read_alloc (¤t_target
, TARGET_OBJECT_SPU
,
608 xsnprintf (note_name
, sizeof note_name
, "SPU/%s", annex
);
609 note_data
= elfcore_write_note (obfd
, note_data
, note_size
,
629 /* Records the thread's register state for the corefile note
633 linux_collect_thread_registers (const struct regcache
*regcache
,
634 ptid_t ptid
, bfd
*obfd
,
635 char *note_data
, int *note_size
,
636 enum target_signal stop_signal
)
638 struct gdbarch
*gdbarch
= get_regcache_arch (regcache
);
639 struct core_regset_section
*sect_list
;
642 sect_list
= gdbarch_core_regset_sections (gdbarch
);
643 gdb_assert (sect_list
);
645 /* For remote targets the LWP may not be available, so use the TID. */
646 lwp
= ptid_get_lwp (ptid
);
648 lwp
= ptid_get_tid (ptid
);
650 while (sect_list
->sect_name
!= NULL
)
652 const struct regset
*regset
;
655 regset
= gdbarch_regset_from_core_section (gdbarch
,
656 sect_list
->sect_name
,
658 gdb_assert (regset
&& regset
->collect_regset
);
660 buf
= xmalloc (sect_list
->size
);
661 regset
->collect_regset (regset
, regcache
, -1, buf
, sect_list
->size
);
663 /* PRSTATUS still needs to be treated specially. */
664 if (strcmp (sect_list
->sect_name
, ".reg") == 0)
665 note_data
= (char *) elfcore_write_prstatus
666 (obfd
, note_data
, note_size
, lwp
,
667 target_signal_to_host (stop_signal
), buf
);
669 note_data
= (char *) elfcore_write_register_note
670 (obfd
, note_data
, note_size
,
671 sect_list
->sect_name
, buf
, sect_list
->size
);
682 struct linux_corefile_thread_data
684 struct gdbarch
*gdbarch
;
690 enum target_signal stop_signal
;
691 linux_collect_thread_registers_ftype collect
;
694 /* Called by gdbthread.c once per thread. Records the thread's
695 register state for the corefile note section. */
698 linux_corefile_thread_callback (struct thread_info
*info
, void *data
)
700 struct linux_corefile_thread_data
*args
= data
;
702 if (ptid_get_pid (info
->ptid
) == args
->pid
)
704 struct cleanup
*old_chain
;
705 struct regcache
*regcache
;
706 regcache
= get_thread_arch_regcache (info
->ptid
, args
->gdbarch
);
708 old_chain
= save_inferior_ptid ();
709 inferior_ptid
= info
->ptid
;
710 target_fetch_registers (regcache
, -1);
711 do_cleanups (old_chain
);
713 args
->note_data
= args
->collect (regcache
, info
->ptid
, args
->obfd
,
714 args
->note_data
, args
->note_size
,
719 return !args
->note_data
;
722 /* Fills the "to_make_corefile_note" target vector. Builds the note
723 section for a corefile, and returns it in a malloc buffer. */
726 linux_make_corefile_notes (struct gdbarch
*gdbarch
, bfd
*obfd
, int *note_size
,
727 linux_collect_thread_registers_ftype collect
)
729 struct linux_corefile_thread_data thread_args
;
730 char *note_data
= NULL
;
734 /* Process information. */
735 if (get_exec_file (0))
737 const char *fname
= lbasename (get_exec_file (0));
738 char *psargs
= xstrdup (fname
);
740 if (get_inferior_args ())
741 psargs
= reconcat (psargs
, psargs
, " ", get_inferior_args (),
744 note_data
= elfcore_write_prpsinfo (obfd
, note_data
, note_size
,
752 /* Thread register information. */
753 thread_args
.gdbarch
= gdbarch
;
754 thread_args
.pid
= ptid_get_pid (inferior_ptid
);
755 thread_args
.obfd
= obfd
;
756 thread_args
.note_data
= note_data
;
757 thread_args
.note_size
= note_size
;
758 thread_args
.num_notes
= 0;
759 thread_args
.stop_signal
= find_stop_signal ();
760 thread_args
.collect
= collect
;
761 iterate_over_threads (linux_corefile_thread_callback
, &thread_args
);
762 note_data
= thread_args
.note_data
;
766 /* Auxillary vector. */
767 auxv_len
= target_read_alloc (¤t_target
, TARGET_OBJECT_AUXV
,
771 note_data
= elfcore_write_note (obfd
, note_data
, note_size
,
772 "CORE", NT_AUXV
, auxv
, auxv_len
);
779 /* SPU information. */
780 note_data
= linux_spu_make_corefile_notes (obfd
, note_data
, note_size
);
784 make_cleanup (xfree
, note_data
);
789 linux_make_corefile_notes_1 (struct gdbarch
*gdbarch
, bfd
*obfd
, int *note_size
)
791 /* FIXME: uweigand/2011-10-06: Once all GNU/Linux architectures have been
792 converted to gdbarch_core_regset_sections, we no longer need to fall back
793 to the target method at this point. */
795 if (!gdbarch_core_regset_sections (gdbarch
))
796 return target_make_corefile_notes (obfd
, note_size
);
798 return linux_make_corefile_notes (gdbarch
, obfd
, note_size
,
799 linux_collect_thread_registers
);
802 /* To be called from the various GDB_OSABI_LINUX handlers for the
803 various GNU/Linux architectures and machine types. */
806 linux_init_abi (struct gdbarch_info info
, struct gdbarch
*gdbarch
)
808 set_gdbarch_core_pid_to_str (gdbarch
, linux_core_pid_to_str
);
809 set_gdbarch_info_proc (gdbarch
, linux_info_proc
);
810 set_gdbarch_make_corefile_notes (gdbarch
, linux_make_corefile_notes_1
);
814 _initialize_linux_tdep (void)
816 linux_gdbarch_data_handle
=
817 gdbarch_data_register_post_init (init_linux_gdbarch_data
);