1 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
3 * linux-arm-low.c (arm_reinsert_addr): New function.
4 (the_low_target): Add arm_reinsert_addr.
6 2003-07-08 Mark Kettenis <kettenis@gnu.org>
8 * mem-break.c: Remove whitespace at end of file.
10 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
12 * configure.in: Check whether we need to prototype strerror.
13 * server.h: Optionally prototype strerror.
14 * gdbreplay.c (perror_with_name): Use strerror.
15 * linux-low.c (linux_attach_lwp): Use strerror.
16 * utils.c (perror_with_name): Use strerror.
17 * config.in, configure: Regenerated.
19 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
22 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
24 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
26 * Makefile.in (SFILES): Update.
27 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
28 low-sun3.c: Remove files.
30 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
32 * linux-low.c: Move comment to linux_thread_alive where it belonged.
33 (linux_detach_one_process, linux_detach): New functions.
34 (linux_target_ops): Add linux_detach.
35 * server.c (main): Handle 'D' packet.
36 * target.h (struct target_ops): Add "detach" member.
37 (detach_inferior): Define.
39 2003-06-13 Mark Kettenis <kettenis@gnu.org>
41 From Kelley Cook <kelleycook@wideopenwest.com>:
42 * configure.srv: Accept i[34567]86 variants.
44 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
46 * linux-low.c (linux_wait_for_event): Correct comment typos.
47 (linux_resume_one_process): Call check_removed_breakpoint.
48 (linux_send_signal): New function.
49 (linux_target_ops): Add linux_send_signal.
50 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
52 * target.h (struct target_ops): Add send_signal.
54 2003-05-29 Jim Blandy <jimb@redhat.com>
56 * linux-low.c (usr_store_inferior_registers): Transfer buf in
57 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
58 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
59 away part of the register's value.
61 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
63 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
64 (linux_wait_for_event, linux_init_signals): Likewise.
66 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
68 * configure.in: Check for stdlib.h.
69 * configure: Regenerated.
70 * config.in: Regenerated.
72 2003-01-04 Andreas Schwab <schwab@suse.de>
74 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
76 2003-01-02 Andrew Cagney <ac131313@redhat.com>
78 * Makefile.in: Remove obsolete code.
80 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
82 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
85 2002-11-17 Stuart Hughes <seh@zee2.com>
87 * linux-arm-low.c (arm_num_regs): Increase.
88 (arm_regmap): Include status register.
90 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
92 * linux-low.c (register_addr): Remove incorrect -1 check.
94 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
96 * linux-low.c (linux_create_inferior): Call setpgid. Return
98 (unstopped_p, linux_signal_pid): Remove.
99 (linux_target_ops): Remove linux_signal_pid.
100 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
101 global instead of target method.
102 * target.h (struct target_ops): Remove signal_pid. Update comment
104 * server.c (signal_pid): New variable.
105 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
106 gdbserver. Set the child to be the foreground process group.
107 (attach_inferior): Set signal_pid.
109 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
111 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
113 2002-08-20 Jim Blandy <jimb@redhat.com>
115 * Makefile.in (LDFLAGS): Allow the configure script to establish a
118 2002-08-01 Andrew Cagney <cagney@redhat.com>
120 * Makefile.in: Make chill references obsolete.
122 2002-07-24 Kevin Buettner <kevinb@redhat.com>
124 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
125 * configure: Regenerate.
126 * config.in: Regenerate.
128 2002-07-09 David O'Brien <obrien@FreeBSD.org>
130 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
131 (perror_with_name, remote_close, remote_open, expect, play): Static.
133 2002-07-04 Michal Ludvig <mludvig@suse.cz>
135 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
136 byte offsets instead of an array of indexes.
137 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
139 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
141 * regcache.c: Add comment.
143 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
145 * thread-db.c: New file.
146 * proc-service.c: New file.
147 * acinclude.m4: New file.
148 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
149 proc-service.o, and thread-db.o.
150 (linux-low.o): Add USE_THREAD_DB.
151 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
152 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
153 * aclocal.m4: Regenerated.
154 * config.in: Regenerated.
155 * configure: Regenerated.
156 * configure.in: Check for proc_service.h, sys/procfs.h,
157 thread_db.h, and linux/elf.h headrs.
158 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
159 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
160 Check for -lthread_db and thread support.
161 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
163 * i387-fp.c: Constify arguments.
164 * i387-fp.h: Likewise.
165 * inferiors.c: (struct thread_info): Renamed from
166 `struct inferior_info'. Remove PID member. Use generic inferior
167 list header. All uses updated.
168 (inferiors, signal_pid): Removed.
169 (all_threads): New variable.
170 (get_thread): Define.
171 (add_inferior_to_list): New function.
172 (for_each_inferior): New function.
173 (change_inferior_id): New function.
174 (add_inferior): Removed.
175 (remove_inferior): New function.
176 (add_thread): New function.
177 (free_one_thread): New function.
178 (remove_thread): New function.
179 (clear_inferiors): Use for_each_inferior and free_one_thread.
180 (find_inferior): New function.
181 (find_inferior_id): New function.
182 (inferior_target_data): Update argument type.
183 (set_inferior_target_data): Likewise.
184 (inferior_regcache_data): Likewise.
185 (set_inferior_regcache_data): Likewise.
186 * linux-low.c (linux_bp_reinsert): Remove.
187 (all_processes, stopping_threads, using_thrads)
188 (struct pending_signals, debug_threads, pid_of): New.
189 (inferior_pid): Replace with macro.
190 (struct inferior_linux_data): Remove.
191 (get_stop_pc, add_process): New functions.
192 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
193 Use add_process and add_thread.
194 (linux_attach_lwp): New function, based on old linux_attach. Use
195 add_process and add_thread. Set stop_expected for new threads.
196 (linux_attach): New function.
197 (linux_kill_one_process): New function.
198 (linux_kill): Kill all LWPs.
199 (linux_thread_alive): Use find_inferior_id.
200 (check_removed_breakpoints, status_pending_p): New functions.
201 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
202 Update. Use WNOHANG. Wait for cloned processes also. Update process
203 struct for the found process.
204 (linux_wait_for_event): New function.
205 (linux_wait): Use it. Support LWPs.
206 (send_sigstop, wait_for_sigstop, stop_all_processes)
207 (linux_resume_one_process, linux_continue_one_process): New functions.
208 (linux_resume): Support LWPs.
209 (REGISTER_RAW_SIZE): Remove.
210 (fetch_register): Use register_size instead. Call supply_register.
211 (usr_store_inferior_registers): Likewise. Call collect_register.
213 (regsets_fetch_inferior_registers): Improve error message.
214 (regsets_store_inferior_registers): Add debugging.
215 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
216 (unstopped_p, linux_signal_pid): New functions.
217 (linux_target_ops): Add linux_signal_pid.
218 (linux_init_signals): New function.
219 (initialize_low): Call it. Initialize using_threads.
220 * regcache.c (inferior_regcache_data): Add valid
222 (get_regcache): Fetch registers lazily. Add fetch argument
223 and update all callers.
224 (regcache_invalidate_one, regcache_invalidate): New
226 (new_register_cache): Renamed from create_register_cache.
227 Return the new regcache.
228 (free_register_cache): Change argument to a void *.
229 (registers_to_string, registers_from_string): Call get_regcache
231 (register_data): Make static. Pass fetch flag to get_regcache.
232 (supply_register): Call get_regcache with fetch flag clear.
233 (collect_register): Call get_regcache with fetch flag set.
234 (collect_register_as_string): New function.
235 * regcache.h: Update.
236 * remote-utils.c (putpkt): Flush after debug output and use
238 Handle input interrupts while waiting for an ACK.
239 (input_interrupt): Use signal_pid method.
240 (getpkt): Flush after debug output and use stderr.
241 (outreg): Use collect_register_as_string.
242 (new_thread_notify, dead_thread_notify): New functions.
243 (prepare_resume_reply): Check using_threads. Set thread_from_wait
245 (look_up_one_symbol): Flush after debug output.
246 * server.c (step_thread, server_waiting): New variables.
247 (start_inferior): Don't use signal_pid. Update call to mywait.
248 (attach_inferior): Update call to mywait.
249 (handle_query): Handle qfThreadInfo and qsThreadInfo.
250 (main): Don't fetch/store registers explicitly. Use
251 set_desired_inferior. Support proposed ``Hs'' packet. Update
254 (struct inferior_list, struct_inferior_list_entry): New.
255 * target.c (set_desired_inferior): New.
256 (write_inferior_memory): Constify.
257 (mywait): New function.
259 (struct target_ops): New signal_pid method.
260 (mywait): Removed macro, added prototype.
262 * linux-low.h (regset_func): Removed.
263 (regset_fill_func, regset_store_func): New.
264 (enum regset_type): New.
265 (struct regset_info): Add type field. Use new operation types.
266 (struct linux_target_ops): stop_pc renamed to get_pc.
267 Add decr_pc_after_break and breakpoint_at.
268 (get_process, get_thread_proess, get_process_thread)
269 (strut process_info, all_processes, linux_attach_lwp)
270 (thread_db_init): New.
272 * linux-arm-low.c (arm_get_pc, arm_set_pc,
273 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
274 (the_low_target): Add new members.
275 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
276 (i386_store_fpxregset): Constify.
277 (target_regsets): Add new kind identifier.
278 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
279 (i386_set_pc): Add debugging.
280 (i386_breakpoint_at): New function.
281 (the_low_target): Add new members.
282 * linux-mips-low.c (mips_get_pc, mips_set_pc)
283 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
284 (mips_breakpoint_at): New.
285 (the_low_target): Add new members.
286 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
287 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
288 (the_low_target): Add new members.
289 * linux-sh-low.c (sh_get_pc, sh_set_pc)
290 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
291 (the_low_target): Add new members.
292 * linux-x86-64-low.c (target_regsets): Add new kind
295 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
297 From Martin Pool <mbp@samba.org>:
298 * server.c (gdbserver_usage): New function.
301 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
303 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
306 2002-05-04 Andrew Cagney <ac131313@redhat.com>
308 * Makefile.in: Remove obsolete code.
310 2002-04-24 Michal Ludvig <mludvig@suse.cz>
312 * linux-low.c (regsets_fetch_inferior_registers),
313 (regsets_store_inferior_registers): Removed cast to int from
315 * regcache.h: Added declaration of struct inferior_info.
317 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
319 * inferiors.c (struct inferior_info): Add regcache_data.
320 (add_inferior): Call create_register_cache.
321 (clear_inferiors): Call free_register_cache.
322 (inferior_regcache_data, set_inferior_regcache_data): New functions.
323 * regcache.c (struct inferior_regcache_data): New.
325 (get_regcache): New function.
326 (create_register_cache, free_register_cache): New functions.
327 (set_register_cache): Don't initialize the register cache here.
328 (registers_to_string, registers_from_string, register_data): Call
330 * regcache.h: Add prototypes.
331 * server.h: Likewise.
333 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
335 * mem-break.c: New file.
336 * mem-break.h: New file.
337 * Makefile.in: Add mem-break.o rule; update server.h
339 * inferiors.c (struct inferior_info): Add target_data
341 (clear_inferiors): Free target_data member if set.
342 (inferior_target_data, set_inferior_target_data): New functions.
343 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
344 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
345 * linux-low.c (linux_bp_reinsert): New variable.
346 (struct inferior_linux_data): New.
347 (linux_create_inferior): Use set_inferior_target_data.
348 (linux_attach): Likewise. Call add_inferior.
349 (linux_wait_for_one_inferior): New function.
350 (linux_wait): Call it.
351 (linux_write_memory): Add const.
352 (initialize_low): Call set_breakpoint_data.
353 * linux-low.h (struct linux_target_ops): Add breakpoint
355 * server.c (attach_inferior): Remove extra add_inferior
357 * server.h: Include mem-break.h. Update inferior.c
359 * target.c (read_inferior_memory)
360 (write_inferior_memory): New functions.
361 * target.h (read_inferior_memory)
362 (write_inferior_memory): Change macros to prototypes.
363 (struct target_ops): Update comments. Add const to write_memory
366 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
368 * linux-low.c (usr_store_inferior_registers): Support
369 registers which are allowed to fail to store.
370 * linux-low.h (linux_target_ops): Likewise.
371 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
372 (ppc_cannot_store_register): FPSCR may not be storable.
374 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
376 * server.h: Include <string.h> if HAVE_STRING_H.
377 * ChangeLog: Correct paths in last ChangeLog entry.
379 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
381 * linux-low.h: Remove obsolete prototypes.
382 (struct linux_target_ops): New.
383 (extern the_low_target): New.
384 * linux-low.c (num_regs, regmap): Remove declarations.
385 (register_addr): Use the_low_target explicitly.
386 (fetch_register): Likewise.
387 (usr_fetch_inferior_registers): Likewise.
388 (usr_store_inferior_registers): Likewise.
389 * linux-arm-low.c (num_regs): Remove.
390 (arm_num_regs): Define.
391 (arm_regmap): Renamed from regmap, made static.
392 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
394 (arm_cannot_store_register): Renamed from cannot_store_register,
396 (the_low_target): New.
397 * linux-i386-low.c (num_regs): Remove.
398 (i386_num_regs): Define.
399 (i386_regmap): Renamed from regmap, made static.
400 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
402 (i386_cannot_store_register): Renamed from cannot_store_register,
404 (the_low_target): New.
405 * linux-ia64-low.c (num_regs): Remove.
406 (ia64_num_regs): Define.
407 (ia64_regmap): Renamed from regmap, made static.
408 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
410 (ia64_cannot_store_register): Renamed from cannot_store_register,
412 (the_low_target): New.
413 * linux-m68k-low.c (num_regs): Remove.
414 (m68k_num_regs): Define.
415 (m68k_regmap): Renamed from regmap, made static.
416 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
418 (m68k_cannot_store_register): Renamed from cannot_store_register,
420 (the_low_target): New.
421 * linux-mips-low.c (num_regs): Remove.
422 (mips_num_regs): Define.
423 (mips_regmap): Renamed from regmap, made static.
424 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
426 (mips_cannot_store_register): Renamed from cannot_store_register,
428 (the_low_target): New.
429 * linux-ppc-low.c (num_regs): Remove.
430 (ppc_num_regs): Define.
431 (ppc_regmap): Renamed from regmap, made static.
432 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
434 (ppc_cannot_store_register): Renamed from cannot_store_register,
436 (the_low_target): New.
437 * linux-s390-low.c (num_regs): Remove.
438 (s390_num_regs): Define.
439 (s390_regmap): Renamed from regmap, made static.
440 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
442 (s390_cannot_store_register): Renamed from cannot_store_register,
444 (the_low_target): New.
445 * linux-sh-low.c (num_regs): Remove.
446 (sh_num_regs): Define.
447 (sh_regmap): Renamed from regmap, made static.
448 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
450 (sh_cannot_store_register): Renamed from cannot_store_register,
452 (the_low_target): New.
453 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
454 (the_low_target): New.
456 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
458 * Makefile.in: Add stamp-h target.
459 * configure.in: Create stamp-h.
460 * configure: Regenerated.
462 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
464 * inferiors.c: New file.
465 * target.c: New file.
466 * target.h: New file.
467 * Makefile.in: Add target.o and inferiors.o. Update
469 * linux-low.c (inferior_pid): New static variable,
471 (linux_create_inferior): Renamed from create_inferior.
472 Call add_inferior. Return 0 on success instead of a PID.
473 (linux_attach): Renamed from myattach.
474 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
475 (linux_thread_alive): Renamed from mythread_alive.
476 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
478 (linux_resume): Renamed from myresume. Add missing ``return 0''.
479 (regsets_store_inferior_registers): Correct error message.
480 Add missing ``return 0''.
481 (linux_fetch_registers): Renamed from fetch_inferior_registers.
482 (linux_store_registers): Renamed from store_inferior_registers.
483 (linux_read_memory): Renamed from read_inferior_memory.
484 (linux_write_memory): Renamed from write_inferior_memory.
485 (linux_target_ops): New structure.
486 (initialize_low): Call set_target_ops ().
487 * remote-utils.c (unhexify): New function.
488 (hexify): New function.
489 (input_interrupt): Send signals to ``signal_pid''.
490 * server.c (inferior_pid): Remove.
491 (start_inferior): Update create_inferior call.
492 (attach_inferior): Call add_inferior.
493 (handle_query): New function.
494 (main): Call handle_query for `q' packets.
495 * server.h: Include "target.h". Remove obsolete prototypes.
496 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
498 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
500 * Makefile.in: Add WARN_CFLAGS. Update configury
502 * configure.in: Check for <string.h>
503 * configure: Regenerate.
504 * config.in: Regenerate.
505 * gdbreplay.c: Include needed system headers.
506 (remote_open): Remove strchr prototype.
507 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
508 * regcache.c (supply_register): Change buf argument to const void *.
509 (supply_register_by_name): Likewise.
510 (collect_register): Change buf argument to void *.
511 (collect_register_by_name): Likewise.
512 * regcache.h: Add missing prototypes.
513 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
514 * server.c (handle_query): New function.
515 (attached): New static variable, moved out of main.
516 (main): Quiet longjmp clobber warnings.
517 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
518 * utils.c (error): Remove NORETURN.