1 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
3 * server.c (wrapper_argv): New.
4 (start_inferior): Handle wrapper_argv. If set, expect an extra
6 (gdbserver_usage): Document --wrapper.
7 (main): Parse --wrapper.
9 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
12 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
13 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
14 (ppc_set_pc): Likewise.
15 (ppc_arch_setup): New function.
16 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
18 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
20 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
22 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
23 instead of linux-ppc64-low.o.
24 * linux-ppc64-low.c: Remove file.
25 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
26 (linux-ppc64-low.o): Remove rule.
28 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
29 (init_registers_powerpc_64): Likewise.
30 (ppc_regmap): Conditionally define depending on __powerpc64__.
31 (ppc_cannot_store_register): Do not special-case "fpscr" when
32 compiled on __powerpc64__.
33 (ppc_collect_ptrace_register): New function.
34 (ppc_supply_ptrace_register): New function.
35 (ppc_breakpoint): Change type to "unsigned int".
36 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
37 (the_low_target): Conditionally provide initializers for the
38 arch_setup member depending on __powerpc64__. Install
39 collect_ptrace_register and supply_ptrace_register members.
41 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
43 * regcache.h (gdbserver_xmltarget): Add extern declaration.
44 * server.c (gdbserver_xmltarget): Define.
45 (get_features_xml): Use it to replace "target.xml" and arch_string.
47 * configure.srv: Remove srv_xmltarget. Add XML files that were
48 mentioned there to srv_xmlfiles instead. Remove conditional tests
49 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
50 srv_xmlfiles and srv_regobj to include all possible choices.
51 * configure.ac (srv_xmltarget): Remove.
52 (srv_xmlfiles): Do not add "target.xml".
53 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
54 checks for supplementary target information.
55 * configure: Regenerate.
56 * Makefile.in (XML_TARGET): Remove.
57 (target.xml): Remove rule.
58 (clean): Do not clean up target.xml.
59 (.PRECIOUS): Do not mention target.xml.
61 * target.h (struct target_ops): Remove arch_string member.
62 * linux-low.c (linux_arch_string): Remove.
63 (linux_target_ops): Remove arch_string initializer.
64 * linux-low.h (struct linux_target_ops): Remove arch_string member.
65 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
66 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
67 * spu-low.c (spu_arch_string): Remove.
68 (spu_target_ops): Remove arch_string initializer.
69 * win32-low.c (win32_arch_string): Remove.
70 (win32_target_ops): Remove arch_string initializer.
71 * win32-low.h (struct win32_target_ops): Remove arch_string member.
72 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
73 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
75 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
77 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
78 by collect_ptrace_register and supply_ptrace_register hooks.
79 * linux-low.c (fetch_register): Use supply_ptrace_register callback
80 instead of checking for the_low_target.left_pad_xfer.
81 (usr_store_inferior_registers): Use collect_ptrace_register callback
82 instead of checking for the_low_target.left_pad_xfer.
84 * linux-s390-low.c (s390_collect_ptrace_register): New function.
85 (s390_supply_ptrace_register): Likewise.
86 (s390_fill_gregset): Call s390_collect_ptrace_register.
87 (the_low_target): Update.
89 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
90 (ppc_supply_ptrace_register): Likewise.
91 (the_low_target): Update.
93 * linux-i386-low.c (the_low_target): Update.
94 * linux-x86-64-low.c (the_low_target): Update.
96 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
98 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
99 reg-s390.o and reg-s390x.o.
101 * linux-low.c (new_inferior): New global variable.
102 (linux_create_inferior, linux_attach): Set it.
103 (linux_wait_for_process): Call the_low_target.arch_setup after the
104 target has stopped for the first time.
105 (initialize_low): Do not call the_low_target.arch_setup.
107 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
108 (s390_set_pc): Likewise.
109 (s390_arch_setup): New function.
110 (the_low_target): Use s390_arch_setup as arch_setup routine.
112 * regcache.c (realloc_register_cache): New function.
113 (set_register_cache): Call it for each existing regcache.
115 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
117 * server.h (init_registers): Remove prototype.
119 * linux-low.h (struct linux_target_ops): Add arch_setup field.
120 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
121 instead of init_registers ().
122 * linux-arm-low.c (init_registers_arm): Add prototype.
123 (init_registers_arm_with_iwmmxt): Likewise.
124 (the_low_target): Add initializer for arch_setup field.
125 * linux-cris-low.c (init_registers_cris): Add prototype.
126 (the_low_target): Add initializer for arch_setup field.
127 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
128 (the_low_target): Add initializer for arch_setup field.
129 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
130 (the_low_target): Add initializer for arch_setup field.
131 * linux-ia64-low.c (init_registers_ia64): Add prototype.
132 (the_low_target): Add initializer for arch_setup field.
133 * linux-m32r-low.c (init_registers_m32r): Add prototype.
134 (the_low_target): Add initializer for arch_setup field.
135 * linux-m68k-low.c (init_registers_m68k): Add prototype.
136 (the_low_target): Add initializer for arch_setup field.
137 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
138 (init_registers_mips64_linux): Likewise.
139 (the_low_target): Add initializer for arch_setup field.
140 * linux-ppc-low.c (init_registers_ppc): Add prototype.
141 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
142 (the_low_target): Add initializer for arch_setup field.
143 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
144 (init_registers_powerpc_64): Likewise.
145 (the_low_target): Add initializer for arch_setup field.
146 * linux-s390-low.c (init_registers_s390): Add prototype.
147 (init_registers_s390x): Likewise.
148 (the_low_target): Add initializer for arch_setup field.
149 * linux-sh-low.c (init_registers_sh): Add prototype.
150 (the_low_target): Add initializer for arch_setup field.
151 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
152 (the_low_target): Add initializer for arch_setup field.
153 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
154 (the_low_target): Add initializer for arch_setup field.
156 * win32-low.h (struct win32_target_ops): Add arch_setup field.
157 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
158 instead of init_registers ().
159 * win32-arm-low.c (init_registers_arm): Add prototype.
160 (the_low_target): Add initializer for arch_setup field.
161 * win32-i386-low.c (init_registers_i386): Add prototype.
162 (the_low_target): Add initializer for arch_setup field.
164 * spu-low.c (init_registers_spu): Add prototype.
165 (initialize_low): Call initialie_registers_spu () instead of
166 initialize_registers ().
168 2008-02-19 Pedro Alves <pedro@codesourcery.com>
170 * server.c (handle_v_requests): When handling the vRun and vAttach
171 packets, if already debugging a process, don't kill it. Return an
174 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
176 * server.c (handle_query): Correct length check.
178 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
180 * win32-low.c (do_initial_child_stuff): Add process handle
181 parameter. Set current_process_handle and current_process_id from the
182 parameters. Clear globals.
183 (win32_create_inferior): Don't set current_process_handle and
184 current_process_id here. Instead pass them on the call to
185 do_initial_child_stuff.
186 (win32_attach): Likewise.
187 (win32_clear_inferiors): New.
188 (win32_kill): Don't close the current process handle or the
189 current thread handle here. Instead call win32_clear_inferiors.
190 (win32_detach): Don't open a new handle to the process. Call
191 win32_clear_inferiors.
192 (win32_join): Don't rely on current_process_handle; open a new
193 handle using the process id.
194 (win32_wait): Call win32_clear_inferiors when the inferior process
197 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
199 * server.c (monitor_show_help): Add "exit".
201 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
203 * Makefile.in (SFILES): Add linux-xtensa-low.c.
204 (clean): Add reg-xtensa.c.
205 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
206 * configure.srv (xtensa*-*-linux*) New target.
207 * linux-xtensa-low.c: New.
208 * xtensa-xtregs.c: New.
210 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
212 * hostio.c: Don't include errno.h.
213 (errno_to_fileio_errno): Move to hostio-errno.
214 * hostio.c: (hostio_error): Remove the error parameter. Defer the
215 error number outputting to the target->hostio_last_error callback.
216 (hostio_packet_error): Use FILEIO_EINVAL directly.
217 (handle_open, handle_pread, hostio_error, handle_unlink): Update
218 calls to hostio_error.
219 * hostio-errno.c: New.
220 * server.h (hostio_last_error_from_errno): Declare.
221 * target.h (target_ops): Add hostio_last_error member.
222 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
223 as hostio_last_error handler.
224 * spu-low.c (spu_target_ops): Likewise.
225 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
226 (wince_hostio_last_error): New functions.
227 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
228 as hostio_last_error handler.
229 (win32_target_ops) [!_WIN32_WCE]: Register
230 hostio_last_error_from_errno as hostio_last_error handler.
231 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
232 (hostio-errno.o): New rule.
233 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
234 * configure.srv (srv_hostio_err_objs): New variable. Default to
236 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
237 * configure: Regenerate.
239 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
241 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
242 (linux_kill, linux_detach): Clean up the process list.
243 * remote-utils.c (remote_open): Improve port number parsing.
244 (putpkt_binary, input_interrupt): Only send interrupts if the target
246 * server.c (extended_protocol): Make static.
247 (attached): Define earlier.
248 (exit_requested, response_needed, program_argv): New variables.
249 (target_running): New.
250 (start_inferior): Clear attached here.
251 (attach_inferior): Set attached here.
252 (require_running): Define.
253 (handle_query): Use require_running and target_running. Implement
255 (handle_v_attach, handle_v_run): New.
256 (handle_v_requests): Use require_running. Handle vAttach and vRun.
257 (gdbserver_usage): Update.
258 (main): Redo argument parsing. Handle --debug and --multi. Handle
259 --attach along with other options or after the port. Save
260 program_argv. Support no initial program. Resynchronize
261 communication with GDB after an error. Handle "monitor exit".
262 Use require_running and target_running. Always allow the extended
263 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
264 restart in extended mode.
265 * README: Refer to the GDB manual. Update --attach usage.
267 2007-12-20 Andreas Schwab <schwab@suse.de>
269 * linux-low.c (STACK_SIZE): Define.
270 (linux_tracefork_child): Use it. Use __clone2 on ia64.
271 (linux_test_for_tracefork): Likewise.
273 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
275 * linux-low.c (linux_wait_for_event): Update messages. Do not
276 reinsert auto-delete breakpoints.
277 * mem-break.c (struct breakpoint): Change return type of handler to
279 (set_breakpoint_at): Update handler type.
280 (reinsert_breakpoint_handler): Return 1 instead of calling
282 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
284 (check_breakpoints): Delete auto-delete breakpoints and return 2.
285 * mem-break.h (set_breakpoint_at): Update handler type.
286 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
287 * win32-low.c (auto_delete_breakpoint): New.
288 (get_child_debug_event): Use it.
290 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
292 * configure.ac: Check for pread and pwrite.
293 * hostio.c (handle_pread): Fall back to lseek and read.
294 (handle_pwrite): Fall back to lseek and write.
295 * config.in, configure: Regenerated.
297 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
299 * server.c (myresume): Add own_buf argument.
300 (main): Update calls.
302 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
304 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
305 * remote-utils.c (remote_open): Do not call disable_async_io.
306 (block_async_io): Delete.
307 (unblock_async_io): Make static.
308 (initialize_async_io): New.
309 * server.c (handle_v_cont): Handle async I/O here.
310 (myresume): Likewise. Move other common resume tasks here...
311 (main): ... from here. Call initialize_async_io. Disable async
312 I/O before the main loop.
313 * server.h (initialize_async_io): Declare.
314 (block_async_io, unblock_async_io): Delete prototypes.
315 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
317 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
319 * remote-utils.c (readchar): Allow binary data in received messages.
321 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
323 * win32-low.c (attaching): New global.
324 (win32_create_inferior): Clear the `attaching' global.
325 (win32_attach): Set the `attaching' global.
326 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
327 attaching. Only set a breakpoint at the entry point if not
330 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
332 * server.c (main): Don't report dll events on the initial
333 connection on attaches.
335 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
337 * server.c (main): Relax numerical bases supported for the pid of
338 the --attach command line argument.
340 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
342 * win32-low.c (win32_attach): Call OpenProcess before
343 DebugActiveProcess, not after. Add last error output to error
346 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
348 * win32-low.c (win32_get_thread_context)
349 (win32_set_thread_context): New functions.
350 (thread_rec): Use win32_get_thread_context.
351 (continue_one_thread, win32_resume): Use win32_set_thread_context.
352 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
356 Pedro Alves <pedro_alves@portugalmail.pt>
358 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
360 (child_add_thread): Minor cleanup.
361 (child_continue): Resume artificially suspended threads before
362 calling ContinueDebugEvent.
363 (suspend_one_thread): New.
364 (fake_breakpoint_event): New.
365 (get_child_debug_event): Change return type to int. Check here if
366 gdb sent an interrupt request. If a soft interrupt was requested,
367 fake a breakpoint event. Return 0 if there is no event to handle,
369 (win32_wait): Don't check here if gdb sent an interrupt request.
370 Ensure there is a valid event to handle.
371 (win32_request_interrupt): Add soft interruption method as last
375 Pedro Alves <pedro_alves@portugalmail.pt>
377 * win32-low.h (win32_thread_info): Add descriptions to the
378 structure members. Replace `suspend_count' counter by a
380 * win32-low.c (thread_rec): Update condition of when to get the
381 context from the inferior. Rely on ContextFlags being set if it
382 has already been retrieved. Only suspend the inferior thread if
383 we haven't already. Warn if that fails.
384 (continue_one_thread): s/suspend_count/suspended/. Only call
385 ResumeThread once. Warn if that fails.
387 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
389 * win32-low.c (win32_wait): Don't read from the inferior when it
392 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
394 * Makefile.in (win32_low_h): New variable.
395 (win32-low.o): Add dependency on $(win32_low_h).
396 (win32-arm-low.o, win32-i386-low.o): New rules.
398 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
400 * hostio.c: Correct copyright year.
402 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
404 * Makefile.in (OBS): Add hostio.o.
405 (hostio.o): New rule.
406 * server.h (handle_vFile): Declare.
407 * hostio.c: New file.
408 * server.c (handle_v_requests): Take packet_len and new_packet_len
409 for binary packets. Call handle_vFile.
410 (main): Update call to handle_v_requests.
412 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
414 * linux-low.c: Include <sched.h>.
416 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
418 * linux-low.c (linux_tracefork_grandchild): New.
419 (linux_tracefork_child): Use clone.
420 (linux_test_for_tracefork): Use clone; allocate and free a stack.
422 2007-10-31 Joel Brobecker <brobecker@adacore.com>
424 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
426 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
428 * linux-low.c (handle_extended_wait): Handle unexpected signals.
430 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
432 * inferiors.c (change_inferior_id): Delete.
433 (add_pid_to_list, pull_pid_from_list): New.
434 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
435 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
436 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
437 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
438 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
439 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
440 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
441 (using_threads): Always set to 1.
442 (handle_extended_wait): New.
443 (add_process): Do not set TID.
444 (linux_create_inferior): Set must_set_ptrace_flags.
445 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
446 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
447 (linux_thread_alive): Rename TID argument to LWPID.
448 (linux_wait_for_process): Handle unknown processes. Do not use TID.
449 (linux_wait_for_event): Do not use TID or check using_threads. Update
450 call to dead_thread_notify. Call handle_extended_wait.
451 (linux_create_inferior): Use PTRACE_SETOPTIONS.
452 (send_sigstop): Delete sigstop_sent.
453 (wait_for_sigstop): Avoid TID.
454 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
455 (linux_test_for_tracefork): New.
456 (linux_lookup_signals): Use thread_db_active and
457 linux_supports_tracefork_flag.
458 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
459 * linux-low.h (get_process_thread): Avoid TID.
460 (struct process_ifo): Move thread_known and tid to the end. Remove
462 (linux_attach_lwp, thread_db_init): Update prototypes.
463 * server.h (change_inferior_id): Delete prototype.
464 (add_pid_to_list, pull_pid_from_list): New prototypes.
465 * thread-db.c (thread_db_use_events): New.
466 (find_first_thread): Rename to...
467 (find_one_thread): ...this. Update callers and messages. Do not
468 call fatal. Check thread_db_use_events. Do not call
469 change_inferior_id or new_thread_notify.
470 (maybe_attach_thread): Update. Do not call new_thread_notify.
471 (thread_db_init): Set thread_db_use_events. Check use_events.
472 * utils.c (fatal, warning): Correct message prefix.
474 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
476 * Makefile.in (clean): Remove new files.
477 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
478 (powerpc-64.o, powerpc-64.c): New rules.
479 * configure.srv: Use alternate register sets for powerpc64-*-linux*
480 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
482 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
484 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
485 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
486 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
487 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
488 (target_regsets): Add AltiVec and SPE register sets.
489 * configure.ac: Check for AltiVec and SPE.
490 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
491 (ppc_fill_vrregset, ppc_store_vrregset): New.
492 (target_regsets): Add AltiVec register set.
493 * configure: Regenerated.
495 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
497 * linux-low.c (O_LARGEFILE): Define.
498 (linux_read_memory): Use /proc/PID/mem.
499 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
500 * configure, config.in: Regenerated.
502 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
504 * linux-low.c (linux_wait_for_event): Do not pass signals while
507 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
509 * win32-low.c (create_process): New.
510 (win32_create_inferior): Use create_process instead of
511 CreateProcess. If create_process failed retry appending an ".exe"
512 suffix. Store the GetLastError result immediatelly after
513 create_process calls and use it on the call to error.
515 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
517 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
519 2007-08-23 Joel Brobecker <brobecker@adacore.com>
521 * configure.ac: Switch license to GPLv3.
523 2007-08-01 Michael Snyder <msnyder@access-company.com>
525 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
527 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
529 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
531 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
532 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
533 CloseToolhelp32Snapshot.
534 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
535 CloseToolhelp32Snapshot.
537 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
539 * server.c (main): Check for inferior exit before main loop.
541 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
543 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
544 instead of on tmp_desc.
546 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
547 Daniel Jacobowitz <dan@codesourcery.com>
549 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
550 (add_thread): Minor cleanups.
551 (clear_inferiors): Move lower in the file. Clear the DLL
553 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
554 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
555 (xml_escape_text): New.
556 * server.c (handle_query): Handle qXfer:libraries:read. Report it
558 (handle_v_cont): Report errors.
559 (gdbserver_version): Update.
560 (main): Correct size of own_buf. Do not report initial DLL events.
561 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
562 (unloaded_dll, xml_escape_text): New.
563 * win32-low.c (enum target_waitkind): Update comments.
564 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
565 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
566 (win32_EnumProcessModules, win32_GetModuleInformation)
567 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
568 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
569 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
570 (win32_Module32First, win32_Module32Next, load_toolhelp)
571 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
572 (get_child_debug_event): Handle DLL events.
573 (win32_wait): Likewise.
575 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
577 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
578 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
580 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
582 * win32-low.c (handle_output_debug_string): Ignore event if not
585 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
587 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
589 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
591 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
593 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
595 * inferiors.c (change_inferior_id): Add comment.
596 * linux-low.c (check_removed_breakpoint): Add an early
597 prototype. Improve debug output.
598 (linux_attach): Doc update.
599 (linux_detach_one_process, linux_detach): Clean up before releasing
601 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
602 * linux-low.h (struct process_info): Doc improvement.
603 * mem-break.c (delete_all_breakpoints): New.
604 * mem-break.h (delete_all_breakpoints): New prototype.
605 * thread-db.c (find_first_thread): New.
606 (thread_db_create_event): Call it instead of
607 thread_db_find_new_threads. Clean up unused variables.
608 (maybe_attach_thread): Remove first thread handling.
609 (thread_db_find_new_threads): Use find_first_thread.
610 (thread_db_get_tls_address): Likewise.
612 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
614 * thread-db.c (thread_db_find_new_threads): Add prototype.
615 (thread_db_create_event): Check for the main thread before adding
617 (maybe_attach_thread): Only enable event reporting if TID == 0.
618 (thread_db_get_tls_address): Check for new threads.
620 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
622 * linux-low.c (linux_create_inferior): Try execv before execvp.
623 * spu-low.c (spu_create_inferior): Likewise.
625 2007-06-13 Mike Frysinger <vapier@gentoo.org>
627 * linux-low.c (linux_create_inferior): Change execv to execvp.
628 * spu-low.c (spu_create_inferior): Likewies.
630 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
632 * Makefile.in (clean): Clean new files instead of deleted ones.
633 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
634 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
636 * configure.srv: Specify XML files and new regformats for MIPS and
638 * linux-mips-low.c (mips_num_regs): Set to only used registers.
639 (mips_regmap): Do not fetch $0. Remove unused registers. Add
640 an entry for the restart register.
641 (mips_cannot_fetch_register, mips_cannot_store_register)
642 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
643 register names to match the XML descriptions.
644 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
645 restart register instead of $0.
647 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
648 Markus Deuling <deuling@de.ibm.com>
650 * remote-utils.c (decode_xfer_write): New function.
651 * server.h (decode_xfer_write): Add prototype.
652 * server.c (handle_query): Add PACKET_LEN argument. Support
653 qXfer:spu:read and qXfer:spu:write packets.
654 (main): Pass packet_len to handle_query.
655 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
656 * target.h (target_ops): Add qxfer_spu.
658 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
660 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
661 accessing non-seekable spufs files.
663 2007-05-16 Markus Deuling <deuling@de.ibm.com>
665 * server.c (handle_query): Add reply for qC packet.
667 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
668 Leo Zayas <lerele@champenstudios@com>
670 * server.h (check_remote_input_interrupt_request): New function.
671 * remote_utils.c (INVALID_DESCRIPTOR): New define.
672 (remote_desc): Initialize with INVALID_DESCRIPTOR.
673 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
674 (check_remote_input_interrupt_request): New function.
675 * server.h (check_remote_input_interrupt_request): Declare.
676 * win32-low.c (winapi_DebugBreakProcess,
677 winapi_GenerateConsoleCtrlEvent): New typedefs.
678 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
680 (win32_wait): Check for remote interrupt request
681 with check_remote_input_interrupt_request.
682 (win32_request_interrupt): New function.
683 (win32_target_op): Set request_interrupt to win32_request_interrupt.
685 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
687 * win32-low.c (debug_registers_changed,
688 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
689 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
690 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
691 (thread_rec): Get context using the low target.
692 (child_add_thread): Call thread_added on the low target,
693 which does the same thing.
695 (do_initial_child_stuff): Remove debug registers references.
696 Set context using the low target. Resume threads after
697 setting the contexts.
698 (child_continue): Remove dead variable. Remove debug
699 registers references.
700 (child_fetch_inferior_registers): Go through the low target.
701 (do_child_store_inferior_registers): Remove.
702 (child_store_inferior_registers): Go through the low target.
703 (win32_resume): Remove debug registers references.
704 Set context using the low target.
705 (handle_exception): Change return type to void. Don't record
706 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
707 first chance exception.
708 (get_child_debug_event): Change return type to void. Remove
709 goto loop. Always return after waiting for debug event.
710 (win32_wait): Convert to switch statement. Handle spurious
713 * win32-i386-low.c (debug_registers_changed,
714 debug_registers_used): New.
715 (initial_stuff): Rename to ...
716 (i386_initial_stuff): ... this. Clear debug registers
718 (store_debug_registers): Delete.
719 (i386_get_thread_context): New.
720 (load_debug_registers): Delete.
721 (i386_set_thread_context): New.
722 (i386_thread_added): New.
723 (single_step): Rename to ...
724 (i386_single_step): ... this.
725 (do_fetch_inferior_registers): Rename to ...
726 (i386_fetch_inferior_register): ... this.
727 (i386_store_inferior_register): New.
728 (the_low_target): Adapt to new interface.
730 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
731 (arm_get_thread_context): New.
732 (arm_set_thread_context): New.
734 (do_fetch_inferior_registers): Rename to ...
735 (arm_fetch_inferior_register): ... this.
736 (arm_store_inferior_register): New.
737 (arm_wince_breakpoint): Reimplement as unsigned long.
738 (arm_wince_breakpoint_len): Define.
739 (the_low_target): Adapt to new interface.
741 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
742 load_debug_registers. Add get_thread_context, set_thread_context,
743 thread_added and store_inferior_register. Rename
744 fetch_inferior_registers to fetch_inferior_register.
745 (regptr): Remove declaration.
747 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
749 * linux-low.c (linux_detach): Change return type to int. Return 0.
750 * spu-low.c (spu_detach): Likewise.
752 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
754 * target.h (target_ops): Change return type of detach to int.
756 (join_inferior): New.
757 * server.c (main): Don't skip detach support on mingw32.
758 If the inferior doesn't support detaching return error.
759 Call join_inferior instead of using waitpid.
760 * linux-low.c (linux_join): New.
761 (linux_target_op): Add linux_join.
762 * spu-low.c (spu_join): New.
763 (spu_target_ops): Add spu_join.
764 * win32-low.c (win32_detach): Adapt to new interface.
765 Reopen current_process_handle before detaching. Issue a child
766 resume before detaching.
768 (win32_target_op): Add win32_join.
770 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
772 * win32-low.c (win32-attach): Fix return value.
773 * target.h (target_ops): Describe ATTACH return values.
775 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
777 * win32-low.c (GETPROCADDRESS): Define.
778 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
779 (winapi_DebugSetProcessKillOnExit): Likewise.
780 (win32_create_inferior): Force usage of ansi CreateProcessA.
781 (win32_attach): Use GETPROCADDRESS.
782 (win32_detach): Likewise.
784 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
786 * win32-low.c (win32_wait): Don't use WSTOPSIG.
788 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
790 * win32-low.c: Commit leftover changes from 2007-03-29.
792 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
794 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
795 fields short instead of int. Add explicit padding.
796 (i387_cache_to_fsave): Remove unnecessary casts.
797 (i387_fsave_to_cache): Doc fix.
798 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
800 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
802 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
803 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
805 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
807 * configure.srv (arm*-*-mingw32ce*): Move near the other
810 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
812 * configure.ac: Add errno checking.
813 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
814 sys/file.h and malloc.h.
815 (AC_CHECK_DECLS): Add perror.
816 (srv_mingwce): Handle.
817 * configure.srv (i[34567]86-*-cygwin*): Add
818 win32-i386-low.o to srv_tgtobj.
819 (i[34567]86-*-mingw*): Likewise.
820 (arm*-*-mingw32ce*): Add case.
821 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
822 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
823 [__MINGW32CE__] (strerror): New function.
824 [__MINGW32CE__] (errno): Define to GetLastError.
825 [__MINGW32CE__] (COUNTOF): New macro.
826 (remote_open): Remove extra close call.
827 * mem-break.c (delete_breakpoint_at): New function.
828 * mem-break.h (delete_breakpoint_at): Declare.
829 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
830 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
831 [USE_WIN32API] (read, write): Add char* casts.
832 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
833 * server.h: Include wincecompat.h on Windows CE.
834 [HAVE_ERRNO_H]: Check.
835 (perror): Declare if not declared.
836 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
837 (perror_with_name): Remove errno declaration.
838 * wincecompat.h: New.
839 * wincecompat.c: New.
841 * win32-arm-low.c: New.
842 * win32-i386-low.c: New.
843 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
844 (OUTMSG2): Make it safe.
846 (COUNTOF): New macro.
847 (NUM_REGS): Get it from the low target.
848 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
849 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
850 (thread_rec): Let low target handle debug registers.
851 (child_add_thread): Likewise.
852 (child_init_thread_list): Likewise.
853 (continue_one_thread): Likewise.
855 (do_child_fetch_inferior_registers): Move to ...
856 * win32-i386-low.c: ... here, and rename to ...
857 (do_fetch_inferior_registers): ... this.
858 * win32-low.c (child_fetch_inferior_registers):
859 Go through the low target.
860 (do_child_store_inferior_registers): Use regptr.
861 (strwinerror): New function.
862 (win32_create_inferior): Handle Windows CE.
863 Use strwinerror instead of strerror on Windows error
864 codes. Add program to the error output.
865 Don't close the main thread handle on Windows CE.
866 (win32_attach): Use coredll.dll on Windows CE.
867 (win32_kill): Close current process and current
869 (win32_detach): Use coredll.dll on Windows CE.
870 (win32_resume): Let low target handle debug registers, and
872 (handle_exception): Add/Remove initial breakpoint. Avoid
873 non-existant WSTOPSIG on Windows CE.
874 (win32_read_inferior_memory): Cast to remove warning.
875 (win32_arch_string): Go through the low target.
876 (initialize_low): Call set_breakpoint_data with the low
878 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
879 FOP_REGNUM, mappings): Move to ...
880 * win32-i386-low.c: ... here.
881 * win32-low.c (win32_thread_info): Move to ...
882 * win32-low.h: ... here.
883 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
884 win32-arm-low.c and wincecompat.c.
886 (install-only:): Likewise.
887 (gdbserver:): Likewise.
888 (gdbreplay:): Likewise.
889 * config.in: Regenerate.
890 * configure: Regenerate.
892 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
894 * win32-low.c: Rename typedef thread_info to
895 win32_thread_info throughout.
897 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
899 * win32-i386-low.c: Rename to ...
900 * win32-low.c: ... this.
901 * configure.srv: Replace win32-i386-low.o with win32-low.o.
902 * Makefile.in: Likewise.
904 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
906 * remote-utils.c (monitor_output): Constify msg parameter.
907 * server.h (monitor_output): Likewise.
908 * win32-i386-low.c (handle_output_debug_string): New.
909 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
910 handle_output_debug_string.
911 (get_child_debug_event): Likewise.
913 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
915 * server.c (main): Correct strtoul check.
917 2007-03-27 Jon Ringle <jon@ringle.org>
919 * linux-low.c: Check __ARCH_HAS_MMU__ also.
921 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
923 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
925 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
927 * terminal.h: Check HAVE_SGTTY_H.
929 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
931 * remote-utils.c (remote_open): Print out the assigned port number.
933 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
935 * remote-utils.c (monitor_output): New function.
936 * server.c (debug_threads): Define here.
937 (monitor_show_help): New function.
938 (handle_query): Handle qRcmd.
939 (main): Do not handle 'd' packet.
940 * server.h (debug_threads, remote_debug, monitor_output): Declare.
941 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
944 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
946 * Makefile.in (EXEEXT): New.
947 (clean): Use $(EXEEXT).
949 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
951 * target.h (target_ops): Rename send_signal to request_interrupt,
952 and remove enum target_signal parameter.
953 * linux-low.c (linux_request_interrupt): Rename from
954 linux_send_signal, and always send SIGINT.
955 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
956 and always send SIGINT.
957 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
959 (input_interrupt): Likewise.
961 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
963 * server.c (get_features_xml): Check if target implemented
965 * win32-i386-low.c (win32_arch_string): New.
966 (win32_target_ops): Add win32_arch_string as arch_string member.
968 2007-02-22 Markus Deuling <deuling@de.ibm.com>
970 * spu-low.c (spu_arch_string): New.
971 (spu_target_ops): Add spu_arch_string.
973 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
975 * remote-utils.c: Remove HAVE_TERMINAL_H check.
976 * configure.ac: Do not check for terminal.h.
977 * configure, config.in: Regenerated.
979 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
981 * Makefile.in (OBS): Add $(XML_BUILTIN).
982 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
984 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
985 (arm-with-iwmmxt.c): New.
986 * config.in, configure: Regenerate.
987 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
988 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
989 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
990 (arm*-*-linux*): Add iWMMXt and regset support.
991 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
992 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
993 (arm_store_wmmxregset, target_regsets): New.
994 * server.c (get_features_xml): Take annex argument. Check builtin
996 (handle_query): Handle multiple annexes.
998 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
1000 * remote-utils.c [USE_WIN32API] (read, write): Define.
1001 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
1004 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
1006 * linux-i386-low.c (the_low_target): Set arch_string.
1007 * linux-x86-64-low.c (the_low_target): Likewise.
1008 * linux-low.c (linux_arch_string): New.
1009 (linux_target_ops): Add it.
1010 * linux-low.h (struct linux_target_ops): Add arch_string.
1011 * server.c (write_qxfer_response): Use const void * for DATA.
1012 (get_features_xml): New.
1013 (handle_query): Handle qXfer:features:read. Report it for qSupported.
1014 * target.h (struct target_ops): Add arch_string method.
1016 2007-01-03 Denis Pilat <denis.pilat@st.com>
1017 Daniel Jacobowitz <dan@codesourcery.com>
1019 * linux-low.c (linux_kill): Handle being called with no threads.
1020 * win32-i386-low.c (win32_kill): Likewise.
1021 (get_child_debug_event): Clear current_process_handle.
1023 2006-12-30 Denis PILAT <denis.pilat@st.com>
1024 Daniel Jacobowitz <dan@codesourcery.com>
1026 * remote-utils.c (remote_open): Check the type of specified
1027 serial port devices before opening them.
1028 * server.c (main): Kill the inferior if an error occurs during
1029 the first remote_open.
1031 2006-12-05 Markus Deuling <deuling@de.ibm.com>
1033 * README: Update supported targets.
1035 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
1037 * Makefile.in (clean): Remove reg-mips64.c.
1038 (reg-mips64.c, reg-mips64.o): New rules.
1039 * configure.srv: Handle mips64. Include regset support for mips.
1040 * linux-mips-low.c (union mips_register): New.
1041 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
1042 (mips_breakpoint, mips_breakpoint_at): Use int.
1043 (mips_collect_register, mips_supply_register)
1044 (mips_collect_register_32bit, mips_supply_register_32bit)
1045 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
1046 (mips_store_fpregset, target_regsets): New.
1047 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
1049 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1051 * configure.srv: Add target "spu*-*-*".
1052 * Makefile.in (clean): Remove reg-spu.c.
1053 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
1054 * spu-low.c: New file.
1056 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
1058 * configure.ac: Correct td_thr_tls_get_addr test.
1059 * configure: Regenerated.
1061 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
1063 * linux-low.c (linux_wait_for_event): Reformat. Use the
1065 * remote-utils.c (decode_address_to_semicolon): New.
1066 * server.c (pass_signals, handle_general_set): New.
1067 (handle_query): Mention QPassSignals for qSupported.
1068 (main): Call handle_general_set.
1069 * server.h (pass_signals, decode_address_to_semicolon): New.
1071 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
1073 * server.c (handle_query): Correct error handling for read_auxv.
1075 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
1077 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
1078 and srv_linux_thread_db to yes.
1079 * linux-s390-low.c (s390_fill_gregset): New function.
1080 (target_regsets): Define data structure.
1082 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
1084 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
1085 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
1086 * config.in, configure: Regenerated.
1087 * inferiors.c (gdb_id_to_thread): New function.
1088 (gdb_id_to_thread_id): Use it.
1089 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
1090 * linux-low.h (struct process_info): Add th member.
1091 (thread_db_get_tls_address): New prototype.
1092 * remote-utils.c (decode_address): Make non-static.
1093 * server.c (handle_query): Handle qGetTLSAddr.
1094 * server.h (gdb_id_to_thread, decode_address): New prototypes.
1095 * target.h (struct target_ops): Add get_tls_address.
1096 * thread-db.c (maybe_attach_thread): Save the thread handle.
1097 (thread_db_get_tls_address): New.
1099 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
1101 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
1102 (linux_resume_one_process): Take a siginfo_t *. Update all
1103 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
1104 (struct pending_signals): Add a siginfo_t.
1105 (linux_wait_for_process): Always set last_status.
1106 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
1107 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
1108 * linux-low.h (struct process_info): Add last_status.
1110 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
1112 * remote-utils.c (try_rle): New function.
1113 (putpkt_binary): Use it.
1115 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
1117 * Makefile.in (clean): Clean reg-x86-64-linux.c.
1118 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
1119 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
1120 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
1121 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
1124 2006-08-08 Richard Sandiford <richard@codesourcery.com>
1126 * server.c (terminal_fd): New variable.
1127 (old_foreground_pgrp): Likewise.
1128 (restore_old_foreground_pgrp): New function.
1129 (start_inferior): Record the terminal file descriptor in terminal_fd
1130 and its original foreground group in old_foreground_pgrp. Register
1131 restore_old_foreground_pgrp with atexit().
1133 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
1135 * server.c (handle_query): Correct qPart to qXfer.
1137 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
1139 * configure.ac: Check for more headers which are missing on
1140 Windows. Automatically supply -lwsock32 and USE_WIN32API.
1141 * configure.srv: Add Cygwin and mingw32.
1142 * remote-utils.c: Don't include headers unconditionally which
1143 are missing on mingw32. Include <winsock.h> for mingw32.
1144 (remote_open): Adjust for mingw32 support. Flush
1145 standard error after writing to it.
1146 (remote_close, putpkt_binary, input_interrupt, block_async_io)
1147 (unblock_async_io, enable_async_io, disable_async_io)
1148 (readchar, getpkt): Update for Winsock support.
1149 (prepare_resume_reply): Expect a protocol signal number.
1150 * server.c: Disable <sys/wait.h> on mingw32.
1151 (start_inferior): Adjust for mingw32 support. Flush
1152 standard error after writing to it.
1153 (attach_inferior): Likewise. Use protocol signal
1155 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
1157 * win32-i386-low.c: New file.
1158 * Makefile.in (XM_CLIBS): Set.
1159 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
1160 (win32-i386-low.o): New dependency rule.
1161 * linux-low.c (linux_wait): Use target signal numbers.
1162 * target.h (struct target_ops): Doc fix.
1163 * server.h (target_signal_to_name): New prototype.
1164 * gdbreplay.c: Don't include headers unconditionally which
1165 are missing on mingw32. Include <winsock.h> for mingw32.
1166 (remote_close, remote_open): Adjust for Winsock support.
1167 * configure, config.in: Regenerated.
1169 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
1171 * server.c (decode_xfer_read, write_qxfer_response): New.
1172 (handle_query): Take a packet length argument. Handle
1173 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
1174 the qSupported response.
1175 (main): Update call to handle_query.
1177 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
1179 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
1180 (putpkt_binary): Renamed from putpkt and adjusted for binary
1182 (putpkt): New wrapper for putpkt_binary.
1183 (readchar): Don't mask off the high bit.
1184 (decode_X_packet): New function.
1185 * server.c (main): Call putpkt_binary if a handler sets the packet
1186 length. Save the length of the incoming packet. Handle 'X'.
1187 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
1189 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
1191 * server.c (handle_query): Handle qSupported.
1193 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
1195 * remote-utils.c (all_symbols_looked_up): New variable.
1196 (look_up_one_symbol): Check it.
1197 * server.h (look_up_one_symbol): New declaration.
1198 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
1200 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
1202 * Makefile.in (linux-arm-low.o): Update dependencies.
1203 * linux-arm-low.c: Include "gdb_proc_service.h".
1204 (PTRACE_GET_THREAD_AREA): Define.
1205 (ps_get_thread_area): New function.
1207 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
1209 * configure.srv (m68k*-*-uclinux*): New target.
1210 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
1211 (linux_resume_one_process): Remove extraneous cast.
1212 (linux_read_offsets): New.
1213 (linux_target_op): Add linux_read_offsets on mmuless systems.
1214 * server.c (handle_query): Add qOffsets logic.
1215 * target.h (struct target_ops): Add read_offsets.
1217 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
1219 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
1220 (PTRACE_GET_THREAD_AREA): Define.
1221 (ps_get_thread_area): New function.
1222 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
1223 (linux-x86-64-low.o): Update.
1225 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
1227 * configure.ac: Remove checks for prfpregset_t.
1228 * gdb_proc_service.h: New file.
1229 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
1230 new "gdb_proc_service.h".
1231 * proc-service.c: Likewise.
1232 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
1233 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
1234 * Makefile.in (gdb_proc_service_h): Updated.
1235 * configure, config.in: Regenerated.
1237 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
1239 * remote-utils.c (prepare_resume_reply): Move declaration
1240 of gdb_id_from_wait to the top of the block.
1242 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
1244 * linux-low.c (regsets_store_inferior_registers): Read the regset
1245 from the target before filling it.
1247 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
1249 * server.c (attach_inferior): Return SIGTRAP for a successful
1252 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
1254 * Makefile.in (OBS): Add version.o.
1255 (STAGESTUFF): Delete.
1256 (version.o): Add dependencies.
1257 (version.c): Replace rule.
1258 (clean): Remove version.c.
1259 * server.c (gdbserver_version): New.
1260 (gdbserver_usage): Use printf.
1261 (main): Handle --version and --help.
1262 * server.h (version, host_name): Add declarations.
1264 2005-12-23 Eli Zaretskii <eliz@gnu.org>
1276 * linux-x86-64-low.c:
1279 * linux-ppc64-low.c:
1288 * linux-crisv32-low.c:
1300 * gdbserver.1: Add (C) after Copyright. Update the FSF
1303 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
1305 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
1306 (arm_breakpoint_at): Recognize both breakpoints.
1307 (the_low_target): Use the correct breakpoint instruction.
1309 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
1311 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
1312 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
1313 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
1314 (the_low_target): Update.
1316 2005-10-25 Andreas Schwab <schwab@suse.de>
1318 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
1320 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
1321 (ia64_num_regs): Reduce to 462.
1323 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
1325 * acinclude.m4: Correct quoting.
1326 * aclocal.m4: Regenerated.
1328 Suggested by SZOKOVACS Robert <szo@ies.hu>:
1329 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
1330 (thread_db_init): Call thread_db_err_str.
1331 * configure.ac: Check for TD_VERSION.
1332 * config.in, configure: Regenerated.
1334 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1336 * server.h (error, fatal, warning): Add ATTR_FORMAT.
1338 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1340 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
1341 is not available. Define HAVE_PTRACE_GETREGS if it is.
1342 * config.in, configure: Regenerated.
1343 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
1344 * linux-i386-low.c, linux-m68k-low.c: Update to use
1345 HAVE_PTRACE_GETREGS.
1346 * linux-low.c (regsets_fetch_inferior_registers)
1347 (regsets_store_inferior_registers): Only return 0 if we processed
1349 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
1350 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
1352 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1354 * inferiors.c (struct thread_info): Add gdb_id.
1355 (add_thread): Add gdb_id argument.
1356 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
1357 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
1358 calls to add_thread.
1359 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
1360 * server.c (handle_query): Use thread_to_gdb_id.
1361 (handle_v_cont, main): Use gdb_id_to_thread_id.
1362 * server.h (add_thread): Update prototype.
1363 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
1366 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1368 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
1369 left-padded registers.
1370 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
1371 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
1373 2005-07-01 Steve Ellcey <sje@cup.hp.com>
1375 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
1376 * configure: Regenerate.
1377 * config.in: Regenerate.
1378 * server.h (NEED_DECLARATION_STRERROR):
1379 Replace with !HAVE_DECL_STRERROR.
1381 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
1383 * linux-low.c (linux_wait, linux_send_signal): Don't test
1384 an unsigned long variable for > 0 if it could be MAX_ULONG.
1385 * server.c (myresume): Likewise.
1386 * target.c (set_desired_inferior): Likewise.
1388 2005-06-13 Mark Kettenis <kettenis@gnu.org>
1390 * configure.ac: Simplify and improve check for socklen_t.
1391 * configure, config.in: Regenerate.
1393 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
1395 * acconfig.h: Remove.
1396 * configure.ac: Add a test for socklen_t. Use three-argument
1397 AC_DEFINE throughout.
1398 * config.in: Regenerated using autoheader 2.59.
1399 * configure: Regenerated.
1401 * gdbreplay.c (socklen_t): Provide a default.
1402 (remote_open): Use socklen_t.
1403 * remote-utils.c (socklen_t): Provide a default.
1404 (remote_open): Use socklen_t.
1405 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
1408 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
1410 * linux-low.c (linux_read_memory, linux_write_memory)
1411 (linux_read_auxv): Likewise.
1412 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
1413 (check_mem_write): Likewise.
1414 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
1416 * regcache.c (struct inferior_rgcache_data, registers_to_string)
1417 (registers_from_string, register_data): Likewise.
1418 * server.c (handle_query, main): Likewise.
1419 * server.h (convert_ascii_to_int, convert_int_to_ascii)
1420 (decode_M_packet): Likewise.
1421 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
1422 * target.h (struct target_ops): Update read_memory, write_memory,
1424 (read_inferior_memory, write_inferior_memory): Update.
1425 * linux-low.h (struct linux_target_ops): Change type of breakpoint
1427 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
1428 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
1429 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
1430 linux-s390-low.c, linux-sh-low.c: Update for changes in
1431 read_inferior_memory and the_low_target->breakpoint.
1433 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
1435 * Makefile.in (SFILES): Add linux-ppc64-low.c.
1436 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
1437 * configure.srv: Add powerpc64-*-linux*.
1438 * linux-ppc64-low.c: New file.
1440 2005-05-23 Orjan Friberg <orjanf@axis.com>
1442 * linux-cris-low.c: New file with support for CRIS.
1443 * linux-crisv32-low.c: Ditto for CRISv32.
1444 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
1445 (clean): Add reg-cris.c and reg-crisv32.c.
1446 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
1447 reg-crisv32.o, and reg-crisv32.c to make rules.
1448 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
1451 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
1453 * linux-low.c (fetch_register): Ensure buffer size is a multiple
1454 of sizeof (PTRACE_XFER_TYPE).
1455 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
1457 2005-05-12 Orjan Friberg <orjanf@axis.com>
1459 * target.h (struct target_ops): Add insert_watchpoint,
1460 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
1461 pointers for hardware watchpoint support.
1462 * linux-low.h (struct linux_target_ops): Ditto.
1463 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
1464 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
1465 to linux_target_ops.
1466 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
1468 * server.c (main): Recognize 'Z' and 'z' packets.
1470 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
1472 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
1473 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
1474 (the_low_target): Add new members.
1476 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
1478 * proc-service.c (ps_lgetregs): Search all_processes instead of
1481 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
1483 * server.c (start_inferior): Change return type to int.
1484 (attach_inferior): Change sigptr to int *.
1485 (handle_v_cont, handle_v_requests): Change signal to int *.
1486 (main): Change signal to int.
1488 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
1490 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
1491 * configure.srv: Add m32r*-*-linux*.
1492 * linux-m32r-low.c: New file.
1494 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
1496 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
1498 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
1500 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
1501 Take unsigned long arguments for PIDs.
1502 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
1503 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
1504 (wait_for_sigstop, linux_resume_one_process)
1505 (regsets_fetch_inferior_registers, linux_send_signal)
1506 (linux_read_auxv): Likewise. Update the types of variables holding
1507 PIDs. Update format string specifiers.
1508 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
1509 * remote-utils.c (prepare_resume_reply): Likewise.
1510 * server.c (cont_thread, general_thread, step_thread)
1511 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
1513 (handle_query): Update format specifiers.
1514 (handle_v_cont, main): Use strtoul for thread IDs.
1515 * server.h (struct inferior_list_entry): Use unsigned long for ID.
1516 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
1517 (general_thread, step_thread, thread_from_wait)
1518 (old_thread_from_wait): Update.
1519 * target.h (struct thread_resume): Use unsigned long for THREAD.
1520 (struct target_ops): Use unsigned long for arguments to attach and
1523 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
1525 * acinclude.m4: Include bfd/bfd.m4 directly.
1526 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
1527 <agriffis@toolchain.org>.
1528 * aclocal.m4, configure: Regenerated.
1530 2005-01-07 Andrew Cagney <cagney@gnu.org>
1532 * configure.ac: Rename configure.in, require autoconf 2.59.
1533 * configure: Re-generate.
1535 2004-12-08 Daniel Jacobowitz <dan@debian.org>
1537 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
1539 * aclocal.m4: Regenerated.
1540 * configure: Regenerated.
1542 2004-11-21 Andreas Schwab <schwab@suse.de>
1544 * linux-m68k-low.c (m68k_num_gregs): Define.
1545 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
1546 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
1547 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
1548 (m68k_breakpoint_at): New. Add to the_low_target.
1550 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
1551 srv_linux_thread_db to yes.
1553 2004-10-20 Joel Brobecker <brobecker@gnat.com>
1555 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
1556 (ARCH_SET_FS): Likewise.
1557 (ARCH_GET_FS): Likewise.
1558 (ARCH_GET_GS): Likewise.
1560 2004-10-16 Daniel Jacobowitz <dan@debian.org>
1562 * linux-i386-low.c (ps_get_thread_area): New.
1563 * linux-x86-64-low.c (ps_get_thread_area): New.
1564 * linux-low.c: Include <sys/syscall.h>.
1565 (linux_kill_one_process): Don't kill the first thread here.
1566 (linux_kill): Kill the first thread here.
1567 (kill_lwp): New function.
1568 (send_sigstop, linux_send_signal): Use it.
1569 * proc-service.c: Clean up #ifdefs.
1570 (fpregset_info): Delete.
1571 (ps_lgetregs): Update and enable implementation.
1572 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
1574 * remote-utils.c (struct sym_cache, symbol_cache): New.
1575 (input_interrupt): Print a clearer message.
1576 (async_io_enabled): New variable.
1577 (enable_async_io, disable_async_io): Use it. Update comments.
1578 (look_up_one_symbol): Use the symbol cache.
1579 * thread-db.c (thread_db_look_up_symbols): New function.
1580 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
1582 2004-10-16 Daniel Jacobowitz <dan@debian.org>
1584 * configure.in: Test for -rdynamic.
1585 * configure: Regenerated.
1586 * Makefile (INTERNAL_LDFLAGS): New.
1587 (gdbserver, gdbreplay): Use it.
1589 2004-09-02 Andrew Cagney <cagney@gnu.org>
1591 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
1593 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
1595 * linux-low.c (linux_wait): Clear all_processes list also.
1597 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
1599 * linux-low.c: Include <errno.h>. Remove extern declaration of
1602 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
1604 * gdbreplay.c, server.h, utils.c: Update copyright years.
1606 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1608 * server.c (main): Print child status or termination signal from
1609 variable 'signal', not 'sig'.
1611 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1613 * linux-low.c (linux_read_memory): Change return type to
1614 int. Check for and return error from ptrace().
1615 * target.c (read_inferior_memory): Change return type to int. Pass
1616 back return status from the_target->read_memory().
1617 * target.h (struct target_ops): Adapt *read_memory() prototype.
1619 (read_inferior_memory): Adapt prototype.
1620 * server.c (main): Return an error packet if
1621 read_inferior_memory() returns an error.
1623 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
1625 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
1626 Unify with other clean targets.
1628 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1630 * server.c (handle_v_cont): Call set_desired_inferior.
1632 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1634 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
1636 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1638 * linux-low.c (linux_wait): Unblock async I/O.
1639 (linux_resume): Block and enable async I/O.
1640 * remote-utils.c (block_async_io, unblock_async_io): New functions.
1641 * server.h (block_async_io, unblock_async_io): Add prototypes.
1643 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1645 * remote-utils.c (remote_open): Print a status notice after
1647 * server.c (attach_inferior): Print a status notice after
1650 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1652 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
1654 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
1656 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
1658 * server.c, target.h: Update copyright years.
1660 2004-02-25 Roland McGrath <roland@redhat.com>
1662 * target.h (struct target_ops): New member `read_auxv'.
1663 * server.c (handle_query): Handle qPart:auxv:read: query using that.
1664 * linux-low.c (linux_read_auxv): New function.
1665 (linux_target_ops): Initialize `read_auxv' member to that.
1667 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1669 Committed by Jim Blandy <jimb@redhat.com>.
1671 * linux-s390-low.c (s390_num_regs): Update.
1672 (s390_regmap): Remove control registers. Use __s390x__ predefine
1673 instead of GPR_SIZE to distiguish s390 and s390x targets.
1675 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
1677 * linux-low.c: Update copyright year.
1678 (check_removed_breakpoint): Clear pending_is_breakpoint.
1679 (linux_set_resume_request, linux_queue_one_thread)
1680 (resume_status_pending_p): New functions.
1681 (linux_continue_one_thread): Use process->resume.
1682 (linux_resume): Only resume threads if there are no pending events.
1683 * linux-low.h (struct process_info): Add resume request
1686 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
1688 * regcache.c (new_register_cache): Clear the allocated register
1689 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
1691 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
1693 * linux-low.c (linux_resume): Take a struct thread_resume *
1695 (linux_wait): Update call.
1696 (resume_ptr): New static variable.
1697 (linux_continue_one_thread): Renamed from
1698 linux_continue_one_process. Use resume_ptr.
1699 (linux_resume): Use linux_continue_one_thread.
1700 * server.c (handle_v_cont, handle_v_requests): New functions.
1701 (myresume): New function.
1702 (main): Handle 'v' case.
1703 * target.h (struct thread_resume): New type.
1704 (struct target_ops): Change argument of "resume" to struct
1706 (myresume): Delete macro.
1708 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
1710 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
1711 (uninstall): Support DESTDIR.
1713 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
1715 * configure.srv: Add xscale*linux copy of arm*linux entry.
1717 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
1719 * linux-arm-low.c (arm_reinsert_addr): New function.
1720 (the_low_target): Add arm_reinsert_addr.
1722 2003-07-08 Mark Kettenis <kettenis@gnu.org>
1724 * mem-break.c: Remove whitespace at end of file.
1726 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
1728 * configure.in: Check whether we need to prototype strerror.
1729 * server.h: Optionally prototype strerror.
1730 * gdbreplay.c (perror_with_name): Use strerror.
1731 * linux-low.c (linux_attach_lwp): Use strerror.
1732 * utils.c (perror_with_name): Use strerror.
1733 * config.in, configure: Regenerated.
1735 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
1737 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
1738 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
1740 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
1742 * Makefile.in (SFILES): Update.
1743 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
1744 low-sun3.c: Remove files.
1746 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
1748 * linux-low.c: Move comment to linux_thread_alive where it belonged.
1749 (linux_detach_one_process, linux_detach): New functions.
1750 (linux_target_ops): Add linux_detach.
1751 * server.c (main): Handle 'D' packet.
1752 * target.h (struct target_ops): Add "detach" member.
1753 (detach_inferior): Define.
1755 2003-06-13 Mark Kettenis <kettenis@gnu.org>
1757 From Kelley Cook <kelleycook@wideopenwest.com>:
1758 * configure.srv: Accept i[34567]86 variants.
1760 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
1762 * linux-low.c (linux_wait_for_event): Correct comment typos.
1763 (linux_resume_one_process): Call check_removed_breakpoint.
1764 (linux_send_signal): New function.
1765 (linux_target_ops): Add linux_send_signal.
1766 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
1768 * target.h (struct target_ops): Add send_signal.
1770 2003-05-29 Jim Blandy <jimb@redhat.com>
1772 * linux-low.c (usr_store_inferior_registers): Transfer buf in
1773 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
1774 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
1775 away part of the register's value.
1777 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
1779 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
1780 (linux_wait_for_event, linux_init_signals): Likewise.
1782 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
1784 * configure.in: Check for stdlib.h.
1785 * configure: Regenerated.
1786 * config.in: Regenerated.
1788 2003-01-04 Andreas Schwab <schwab@suse.de>
1790 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
1792 2003-01-02 Andrew Cagney <ac131313@redhat.com>
1794 * Makefile.in: Remove obsolete code.
1796 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
1798 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
1799 defined(PT_FPR0_HI).
1801 2002-11-17 Stuart Hughes <seh@zee2.com>
1803 * linux-arm-low.c (arm_num_regs): Increase.
1804 (arm_regmap): Include status register.
1806 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
1808 * linux-low.c (register_addr): Remove incorrect -1 check.
1810 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
1812 * linux-low.c (linux_create_inferior): Call setpgid. Return
1814 (unstopped_p, linux_signal_pid): Remove.
1815 (linux_target_ops): Remove linux_signal_pid.
1816 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
1817 global instead of target method.
1818 * target.h (struct target_ops): Remove signal_pid. Update comment
1819 for create_inferior.
1820 * server.c (signal_pid): New variable.
1821 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
1822 gdbserver. Set the child to be the foreground process group.
1823 (attach_inferior): Set signal_pid.
1825 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
1827 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
1829 2002-08-20 Jim Blandy <jimb@redhat.com>
1831 * Makefile.in (LDFLAGS): Allow the configure script to establish a
1834 2002-08-01 Andrew Cagney <cagney@redhat.com>
1836 * Makefile.in: Make chill references obsolete.
1838 2002-07-24 Kevin Buettner <kevinb@redhat.com>
1840 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
1841 * configure: Regenerate.
1842 * config.in: Regenerate.
1844 2002-07-09 David O'Brien <obrien@FreeBSD.org>
1846 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
1847 (perror_with_name, remote_close, remote_open, expect, play): Static.
1849 2002-07-04 Michal Ludvig <mludvig@suse.cz>
1851 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
1852 byte offsets instead of an array of indexes.
1853 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
1855 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
1857 * regcache.c: Add comment.
1859 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
1861 * thread-db.c: New file.
1862 * proc-service.c: New file.
1863 * acinclude.m4: New file.
1864 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
1865 proc-service.o, and thread-db.o.
1866 (linux-low.o): Add USE_THREAD_DB.
1867 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
1868 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
1869 * aclocal.m4: Regenerated.
1870 * config.in: Regenerated.
1871 * configure: Regenerated.
1872 * configure.in: Check for proc_service.h, sys/procfs.h,
1873 thread_db.h, and linux/elf.h headrs.
1874 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
1875 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
1876 Check for -lthread_db and thread support.
1877 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
1878 PowerPC, and SuperH.
1879 * i387-fp.c: Constify arguments.
1880 * i387-fp.h: Likewise.
1881 * inferiors.c: (struct thread_info): Renamed from
1882 `struct inferior_info'. Remove PID member. Use generic inferior
1883 list header. All uses updated.
1884 (inferiors, signal_pid): Removed.
1885 (all_threads): New variable.
1886 (get_thread): Define.
1887 (add_inferior_to_list): New function.
1888 (for_each_inferior): New function.
1889 (change_inferior_id): New function.
1890 (add_inferior): Removed.
1891 (remove_inferior): New function.
1892 (add_thread): New function.
1893 (free_one_thread): New function.
1894 (remove_thread): New function.
1895 (clear_inferiors): Use for_each_inferior and free_one_thread.
1896 (find_inferior): New function.
1897 (find_inferior_id): New function.
1898 (inferior_target_data): Update argument type.
1899 (set_inferior_target_data): Likewise.
1900 (inferior_regcache_data): Likewise.
1901 (set_inferior_regcache_data): Likewise.
1902 * linux-low.c (linux_bp_reinsert): Remove.
1903 (all_processes, stopping_threads, using_thrads)
1904 (struct pending_signals, debug_threads, pid_of): New.
1905 (inferior_pid): Replace with macro.
1906 (struct inferior_linux_data): Remove.
1907 (get_stop_pc, add_process): New functions.
1908 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
1909 Use add_process and add_thread.
1910 (linux_attach_lwp): New function, based on old linux_attach. Use
1911 add_process and add_thread. Set stop_expected for new threads.
1912 (linux_attach): New function.
1913 (linux_kill_one_process): New function.
1914 (linux_kill): Kill all LWPs.
1915 (linux_thread_alive): Use find_inferior_id.
1916 (check_removed_breakpoints, status_pending_p): New functions.
1917 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
1918 Update. Use WNOHANG. Wait for cloned processes also. Update process
1919 struct for the found process.
1920 (linux_wait_for_event): New function.
1921 (linux_wait): Use it. Support LWPs.
1922 (send_sigstop, wait_for_sigstop, stop_all_processes)
1923 (linux_resume_one_process, linux_continue_one_process): New functions.
1924 (linux_resume): Support LWPs.
1925 (REGISTER_RAW_SIZE): Remove.
1926 (fetch_register): Use register_size instead. Call supply_register.
1927 (usr_store_inferior_registers): Likewise. Call collect_register.
1929 (regsets_fetch_inferior_registers): Improve error message.
1930 (regsets_store_inferior_registers): Add debugging.
1931 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
1932 (unstopped_p, linux_signal_pid): New functions.
1933 (linux_target_ops): Add linux_signal_pid.
1934 (linux_init_signals): New function.
1935 (initialize_low): Call it. Initialize using_threads.
1936 * regcache.c (inferior_regcache_data): Add valid
1938 (get_regcache): Fetch registers lazily. Add fetch argument
1939 and update all callers.
1940 (regcache_invalidate_one, regcache_invalidate): New
1942 (new_register_cache): Renamed from create_register_cache.
1943 Return the new regcache.
1944 (free_register_cache): Change argument to a void *.
1945 (registers_to_string, registers_from_string): Call get_regcache
1946 with fetch flag set.
1947 (register_data): Make static. Pass fetch flag to get_regcache.
1948 (supply_register): Call get_regcache with fetch flag clear.
1949 (collect_register): Call get_regcache with fetch flag set.
1950 (collect_register_as_string): New function.
1951 * regcache.h: Update.
1952 * remote-utils.c (putpkt): Flush after debug output and use
1954 Handle input interrupts while waiting for an ACK.
1955 (input_interrupt): Use signal_pid method.
1956 (getpkt): Flush after debug output and use stderr.
1957 (outreg): Use collect_register_as_string.
1958 (new_thread_notify, dead_thread_notify): New functions.
1959 (prepare_resume_reply): Check using_threads. Set thread_from_wait
1961 (look_up_one_symbol): Flush after debug output.
1962 * server.c (step_thread, server_waiting): New variables.
1963 (start_inferior): Don't use signal_pid. Update call to mywait.
1964 (attach_inferior): Update call to mywait.
1965 (handle_query): Handle qfThreadInfo and qsThreadInfo.
1966 (main): Don't fetch/store registers explicitly. Use
1967 set_desired_inferior. Support proposed ``Hs'' packet. Update
1970 (struct inferior_list, struct_inferior_list_entry): New.
1971 * target.c (set_desired_inferior): New.
1972 (write_inferior_memory): Constify.
1973 (mywait): New function.
1975 (struct target_ops): New signal_pid method.
1976 (mywait): Removed macro, added prototype.
1978 * linux-low.h (regset_func): Removed.
1979 (regset_fill_func, regset_store_func): New.
1980 (enum regset_type): New.
1981 (struct regset_info): Add type field. Use new operation types.
1982 (struct linux_target_ops): stop_pc renamed to get_pc.
1983 Add decr_pc_after_break and breakpoint_at.
1984 (get_process, get_thread_proess, get_process_thread)
1985 (strut process_info, all_processes, linux_attach_lwp)
1986 (thread_db_init): New.
1988 * linux-arm-low.c (arm_get_pc, arm_set_pc,
1989 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
1990 (the_low_target): Add new members.
1991 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
1992 (i386_store_fpxregset): Constify.
1993 (target_regsets): Add new kind identifier.
1994 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
1995 (i386_set_pc): Add debugging.
1996 (i386_breakpoint_at): New function.
1997 (the_low_target): Add new members.
1998 * linux-mips-low.c (mips_get_pc, mips_set_pc)
1999 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
2000 (mips_breakpoint_at): New.
2001 (the_low_target): Add new members.
2002 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
2003 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
2004 (the_low_target): Add new members.
2005 * linux-sh-low.c (sh_get_pc, sh_set_pc)
2006 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
2007 (the_low_target): Add new members.
2008 * linux-x86-64-low.c (target_regsets): Add new kind
2011 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
2013 From Martin Pool <mbp@samba.org>:
2014 * server.c (gdbserver_usage): New function.
2017 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
2019 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
2022 2002-05-04 Andrew Cagney <ac131313@redhat.com>
2024 * Makefile.in: Remove obsolete code.
2026 2002-04-24 Michal Ludvig <mludvig@suse.cz>
2028 * linux-low.c (regsets_fetch_inferior_registers),
2029 (regsets_store_inferior_registers): Removed cast to int from
2031 * regcache.h: Added declaration of struct inferior_info.
2033 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
2035 * inferiors.c (struct inferior_info): Add regcache_data.
2036 (add_inferior): Call create_register_cache.
2037 (clear_inferiors): Call free_register_cache.
2038 (inferior_regcache_data, set_inferior_regcache_data): New functions.
2039 * regcache.c (struct inferior_regcache_data): New.
2040 (registers): Remove.
2041 (get_regcache): New function.
2042 (create_register_cache, free_register_cache): New functions.
2043 (set_register_cache): Don't initialize the register cache here.
2044 (registers_to_string, registers_from_string, register_data): Call
2046 * regcache.h: Add prototypes.
2047 * server.h: Likewise.
2049 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
2051 * mem-break.c: New file.
2052 * mem-break.h: New file.
2053 * Makefile.in: Add mem-break.o rule; update server.h
2055 * inferiors.c (struct inferior_info): Add target_data
2057 (clear_inferiors): Free target_data member if set.
2058 (inferior_target_data, set_inferior_target_data): New functions.
2059 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
2060 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
2061 * linux-low.c (linux_bp_reinsert): New variable.
2062 (struct inferior_linux_data): New.
2063 (linux_create_inferior): Use set_inferior_target_data.
2064 (linux_attach): Likewise. Call add_inferior.
2065 (linux_wait_for_one_inferior): New function.
2066 (linux_wait): Call it.
2067 (linux_write_memory): Add const.
2068 (initialize_low): Call set_breakpoint_data.
2069 * linux-low.h (struct linux_target_ops): Add breakpoint
2071 * server.c (attach_inferior): Remove extra add_inferior
2073 * server.h: Include mem-break.h. Update inferior.c
2075 * target.c (read_inferior_memory)
2076 (write_inferior_memory): New functions.
2077 * target.h (read_inferior_memory)
2078 (write_inferior_memory): Change macros to prototypes.
2079 (struct target_ops): Update comments. Add const to write_memory
2082 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
2084 * linux-low.c (usr_store_inferior_registers): Support
2085 registers which are allowed to fail to store.
2086 * linux-low.h (linux_target_ops): Likewise.
2087 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
2088 (ppc_cannot_store_register): FPSCR may not be storable.
2090 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
2092 * server.h: Include <string.h> if HAVE_STRING_H.
2093 * ChangeLog: Correct paths in last ChangeLog entry.
2095 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
2097 * linux-low.h: Remove obsolete prototypes.
2098 (struct linux_target_ops): New.
2099 (extern the_low_target): New.
2100 * linux-low.c (num_regs, regmap): Remove declarations.
2101 (register_addr): Use the_low_target explicitly.
2102 (fetch_register): Likewise.
2103 (usr_fetch_inferior_registers): Likewise.
2104 (usr_store_inferior_registers): Likewise.
2105 * linux-arm-low.c (num_regs): Remove.
2106 (arm_num_regs): Define.
2107 (arm_regmap): Renamed from regmap, made static.
2108 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
2110 (arm_cannot_store_register): Renamed from cannot_store_register,
2112 (the_low_target): New.
2113 * linux-i386-low.c (num_regs): Remove.
2114 (i386_num_regs): Define.
2115 (i386_regmap): Renamed from regmap, made static.
2116 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
2118 (i386_cannot_store_register): Renamed from cannot_store_register,
2120 (the_low_target): New.
2121 * linux-ia64-low.c (num_regs): Remove.
2122 (ia64_num_regs): Define.
2123 (ia64_regmap): Renamed from regmap, made static.
2124 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
2126 (ia64_cannot_store_register): Renamed from cannot_store_register,
2128 (the_low_target): New.
2129 * linux-m68k-low.c (num_regs): Remove.
2130 (m68k_num_regs): Define.
2131 (m68k_regmap): Renamed from regmap, made static.
2132 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
2134 (m68k_cannot_store_register): Renamed from cannot_store_register,
2136 (the_low_target): New.
2137 * linux-mips-low.c (num_regs): Remove.
2138 (mips_num_regs): Define.
2139 (mips_regmap): Renamed from regmap, made static.
2140 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
2142 (mips_cannot_store_register): Renamed from cannot_store_register,
2144 (the_low_target): New.
2145 * linux-ppc-low.c (num_regs): Remove.
2146 (ppc_num_regs): Define.
2147 (ppc_regmap): Renamed from regmap, made static.
2148 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
2150 (ppc_cannot_store_register): Renamed from cannot_store_register,
2152 (the_low_target): New.
2153 * linux-s390-low.c (num_regs): Remove.
2154 (s390_num_regs): Define.
2155 (s390_regmap): Renamed from regmap, made static.
2156 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
2158 (s390_cannot_store_register): Renamed from cannot_store_register,
2160 (the_low_target): New.
2161 * linux-sh-low.c (num_regs): Remove.
2162 (sh_num_regs): Define.
2163 (sh_regmap): Renamed from regmap, made static.
2164 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
2166 (sh_cannot_store_register): Renamed from cannot_store_register,
2168 (the_low_target): New.
2169 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
2170 (the_low_target): New.
2172 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
2174 * Makefile.in: Add stamp-h target.
2175 * configure.in: Create stamp-h.
2176 * configure: Regenerated.
2178 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
2180 * inferiors.c: New file.
2181 * target.c: New file.
2182 * target.h: New file.
2183 * Makefile.in: Add target.o and inferiors.o. Update
2185 * linux-low.c (inferior_pid): New static variable,
2186 moved from server.c.
2187 (linux_create_inferior): Renamed from create_inferior.
2188 Call add_inferior. Return 0 on success instead of a PID.
2189 (linux_attach): Renamed from myattach.
2190 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
2191 (linux_thread_alive): Renamed from mythread_alive.
2192 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
2194 (linux_resume): Renamed from myresume. Add missing ``return 0''.
2195 (regsets_store_inferior_registers): Correct error message.
2196 Add missing ``return 0''.
2197 (linux_fetch_registers): Renamed from fetch_inferior_registers.
2198 (linux_store_registers): Renamed from store_inferior_registers.
2199 (linux_read_memory): Renamed from read_inferior_memory.
2200 (linux_write_memory): Renamed from write_inferior_memory.
2201 (linux_target_ops): New structure.
2202 (initialize_low): Call set_target_ops ().
2203 * remote-utils.c (unhexify): New function.
2204 (hexify): New function.
2205 (input_interrupt): Send signals to ``signal_pid''.
2206 * server.c (inferior_pid): Remove.
2207 (start_inferior): Update create_inferior call.
2208 (attach_inferior): Call add_inferior.
2209 (handle_query): New function.
2210 (main): Call handle_query for `q' packets.
2211 * server.h: Include "target.h". Remove obsolete prototypes.
2212 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
2214 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
2216 * Makefile.in: Add WARN_CFLAGS. Update configury
2218 * configure.in: Check for <string.h>
2219 * configure: Regenerate.
2220 * config.in: Regenerate.
2221 * gdbreplay.c: Include needed system headers.
2222 (remote_open): Remove strchr prototype.
2223 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
2224 * regcache.c (supply_register): Change buf argument to const void *.
2225 (supply_register_by_name): Likewise.
2226 (collect_register): Change buf argument to void *.
2227 (collect_register_by_name): Likewise.
2228 * regcache.h: Add missing prototypes.
2229 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
2230 * server.c (handle_query): New function.
2231 (attached): New static variable, moved out of main.
2232 (main): Quiet longjmp clobber warnings.
2233 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
2234 * utils.c (error): Remove NORETURN.