1 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
3 * linux-low.c (O_LARGEFILE): Define.
4 (linux_read_memory): Use /proc/PID/mem.
5 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
6 * configure, config.in: Regenerated.
8 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
10 * linux-low.c (linux_wait_for_event): Do not pass signals while
13 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15 * win32-low.c (create_process): New.
16 (win32_create_inferior): Use create_process instead of
17 CreateProcess. If create_process failed retry appending an ".exe"
18 suffix. Store the GetLastError result immediatelly after
19 create_process calls and use it on the call to error.
21 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
23 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
25 2007-08-23 Joel Brobecker <brobecker@adacore.com>
27 * configure.ac: Switch license to GPLv3.
29 2007-08-01 Michael Snyder <msnyder@access-company.com>
31 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
33 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
35 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
37 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
38 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
39 CloseToolhelp32Snapshot.
40 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
41 CloseToolhelp32Snapshot.
43 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
45 * server.c (main): Check for inferior exit before main loop.
47 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
49 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
50 instead of on tmp_desc.
52 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
53 Daniel Jacobowitz <dan@codesourcery.com>
55 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
56 (add_thread): Minor cleanups.
57 (clear_inferiors): Move lower in the file. Clear the DLL
59 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
60 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
61 (xml_escape_text): New.
62 * server.c (handle_query): Handle qXfer:libraries:read. Report it
64 (handle_v_cont): Report errors.
65 (gdbserver_version): Update.
66 (main): Correct size of own_buf. Do not report initial DLL events.
67 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
68 (unloaded_dll, xml_escape_text): New.
69 * win32-low.c (enum target_waitkind): Update comments.
70 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
71 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
72 (win32_EnumProcessModules, win32_GetModuleInformation)
73 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
74 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
75 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
76 (win32_Module32First, win32_Module32Next, load_toolhelp)
77 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
78 (get_child_debug_event): Handle DLL events.
79 (win32_wait): Likewise.
81 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
83 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
84 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
86 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
88 * win32-low.c (handle_output_debug_string): Ignore event if not
91 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
93 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
95 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
97 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
99 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
101 * inferiors.c (change_inferior_id): Add comment.
102 * linux-low.c (check_removed_breakpoint): Add an early
103 prototype. Improve debug output.
104 (linux_attach): Doc update.
105 (linux_detach_one_process, linux_detach): Clean up before releasing
107 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
108 * linux-low.h (struct process_info): Doc improvement.
109 * mem-break.c (delete_all_breakpoints): New.
110 * mem-break.h (delete_all_breakpoints): New prototype.
111 * thread-db.c (find_first_thread): New.
112 (thread_db_create_event): Call it instead of
113 thread_db_find_new_threads. Clean up unused variables.
114 (maybe_attach_thread): Remove first thread handling.
115 (thread_db_find_new_threads): Use find_first_thread.
116 (thread_db_get_tls_address): Likewise.
118 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
120 * thread-db.c (thread_db_find_new_threads): Add prototype.
121 (thread_db_create_event): Check for the main thread before adding
123 (maybe_attach_thread): Only enable event reporting if TID == 0.
124 (thread_db_get_tls_address): Check for new threads.
126 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
128 * linux-low.c (linux_create_inferior): Try execv before execvp.
129 * spu-low.c (spu_create_inferior): Likewise.
131 2007-06-13 Mike Frysinger <vapier@gentoo.org>
133 * linux-low.c (linux_create_inferior): Change execv to execvp.
134 * spu-low.c (spu_create_inferior): Likewies.
136 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
138 * Makefile.in (clean): Clean new files instead of deleted ones.
139 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
140 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
142 * configure.srv: Specify XML files and new regformats for MIPS and
144 * linux-mips-low.c (mips_num_regs): Set to only used registers.
145 (mips_regmap): Do not fetch $0. Remove unused registers. Add
146 an entry for the restart register.
147 (mips_cannot_fetch_register, mips_cannot_store_register)
148 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
149 register names to match the XML descriptions.
150 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
151 restart register instead of $0.
153 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
154 Markus Deuling <deuling@de.ibm.com>
156 * remote-utils.c (decode_xfer_write): New function.
157 * server.h (decode_xfer_write): Add prototype.
158 * server.c (handle_query): Add PACKET_LEN argument. Support
159 qXfer:spu:read and qXfer:spu:write packets.
160 (main): Pass packet_len to handle_query.
161 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
162 * target.h (target_ops): Add qxfer_spu.
164 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
166 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
167 accessing non-seekable spufs files.
169 2007-05-16 Markus Deuling <deuling@de.ibm.com>
171 * server.c (handle_query): Add reply for qC packet.
173 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
174 Leo Zayas <lerele@champenstudios@com>
176 * server.h (check_remote_input_interrupt_request): New function.
177 * remote_utils.c (INVALID_DESCRIPTOR): New define.
178 (remote_desc): Initialize with INVALID_DESCRIPTOR.
179 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
180 (check_remote_input_interrupt_request): New function.
181 * server.h (check_remote_input_interrupt_request): Declare.
182 * win32-low.c (winapi_DebugBreakProcess,
183 winapi_GenerateConsoleCtrlEvent): New typedefs.
184 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
186 (win32_wait): Check for remote interrupt request
187 with check_remote_input_interrupt_request.
188 (win32_request_interrupt): New function.
189 (win32_target_op): Set request_interrupt to win32_request_interrupt.
191 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
193 * win32-low.c (debug_registers_changed,
194 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
195 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
196 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
197 (thread_rec): Get context using the low target.
198 (child_add_thread): Call thread_added on the low target,
199 which does the same thing.
201 (do_initial_child_stuff): Remove debug registers references.
202 Set context using the low target. Resume threads after
203 setting the contexts.
204 (child_continue): Remove dead variable. Remove debug
205 registers references.
206 (child_fetch_inferior_registers): Go through the low target.
207 (do_child_store_inferior_registers): Remove.
208 (child_store_inferior_registers): Go through the low target.
209 (win32_resume): Remove debug registers references.
210 Set context using the low target.
211 (handle_exception): Change return type to void. Don't record
212 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
213 first chance exception.
214 (get_child_debug_event): Change return type to void. Remove
215 goto loop. Always return after waiting for debug event.
216 (win32_wait): Convert to switch statement. Handle spurious
219 * win32-i386-low.c (debug_registers_changed,
220 debug_registers_used): New.
221 (initial_stuff): Rename to ...
222 (i386_initial_stuff): ... this. Clear debug registers
224 (store_debug_registers): Delete.
225 (i386_get_thread_context): New.
226 (load_debug_registers): Delete.
227 (i386_set_thread_context): New.
228 (i386_thread_added): New.
229 (single_step): Rename to ...
230 (i386_single_step): ... this.
231 (do_fetch_inferior_registers): Rename to ...
232 (i386_fetch_inferior_register): ... this.
233 (i386_store_inferior_register): New.
234 (the_low_target): Adapt to new interface.
236 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
237 (arm_get_thread_context): New.
238 (arm_set_thread_context): New.
240 (do_fetch_inferior_registers): Rename to ...
241 (arm_fetch_inferior_register): ... this.
242 (arm_store_inferior_register): New.
243 (arm_wince_breakpoint): Reimplement as unsigned long.
244 (arm_wince_breakpoint_len): Define.
245 (the_low_target): Adapt to new interface.
247 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
248 load_debug_registers. Add get_thread_context, set_thread_context,
249 thread_added and store_inferior_register. Rename
250 fetch_inferior_registers to fetch_inferior_register.
251 (regptr): Remove declaration.
253 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
255 * linux-low.c (linux_detach): Change return type to int. Return 0.
256 * spu-low.c (spu_detach): Likewise.
258 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
260 * target.h (target_ops): Change return type of detach to int.
262 (join_inferior): New.
263 * server.c (main): Don't skip detach support on mingw32.
264 If the inferior doesn't support detaching return error.
265 Call join_inferior instead of using waitpid.
266 * linux-low.c (linux_join): New.
267 (linux_target_op): Add linux_join.
268 * spu-low.c (spu_join): New.
269 (spu_target_ops): Add spu_join.
270 * win32-low.c (win32_detach): Adapt to new interface.
271 Reopen current_process_handle before detaching. Issue a child
272 resume before detaching.
274 (win32_target_op): Add win32_join.
276 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
278 * win32-low.c (win32-attach): Fix return value.
279 * target.h (target_ops): Describe ATTACH return values.
281 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
283 * win32-low.c (GETPROCADDRESS): Define.
284 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
285 (winapi_DebugSetProcessKillOnExit): Likewise.
286 (win32_create_inferior): Force usage of ansi CreateProcessA.
287 (win32_attach): Use GETPROCADDRESS.
288 (win32_detach): Likewise.
290 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
292 * win32-low.c (win32_wait): Don't use WSTOPSIG.
294 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
296 * win32-low.c: Commit leftover changes from 2007-03-29.
298 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
300 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
301 fields short instead of int. Add explicit padding.
302 (i387_cache_to_fsave): Remove unnecessary casts.
303 (i387_fsave_to_cache): Doc fix.
304 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
306 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
308 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
309 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
311 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
313 * configure.srv (arm*-*-mingw32ce*): Move near the other
316 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
318 * configure.ac: Add errno checking.
319 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
320 sys/file.h and malloc.h.
321 (AC_CHECK_DECLS): Add perror.
322 (srv_mingwce): Handle.
323 * configure.srv (i[34567]86-*-cygwin*): Add
324 win32-i386-low.o to srv_tgtobj.
325 (i[34567]86-*-mingw*): Likewise.
326 (arm*-*-mingw32ce*): Add case.
327 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
328 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
329 [__MINGW32CE__] (strerror): New function.
330 [__MINGW32CE__] (errno): Define to GetLastError.
331 [__MINGW32CE__] (COUNTOF): New macro.
332 (remote_open): Remove extra close call.
333 * mem-break.c (delete_breakpoint_at): New function.
334 * mem-break.h (delete_breakpoint_at): Declare.
335 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
336 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
337 [USE_WIN32API] (read, write): Add char* casts.
338 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
339 * server.h: Include wincecompat.h on Windows CE.
340 [HAVE_ERRNO_H]: Check.
341 (perror): Declare if not declared.
342 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
343 (perror_with_name): Remove errno declaration.
344 * wincecompat.h: New.
345 * wincecompat.c: New.
347 * win32-arm-low.c: New.
348 * win32-i386-low.c: New.
349 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
350 (OUTMSG2): Make it safe.
352 (COUNTOF): New macro.
353 (NUM_REGS): Get it from the low target.
354 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
355 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
356 (thread_rec): Let low target handle debug registers.
357 (child_add_thread): Likewise.
358 (child_init_thread_list): Likewise.
359 (continue_one_thread): Likewise.
361 (do_child_fetch_inferior_registers): Move to ...
362 * win32-i386-low.c: ... here, and rename to ...
363 (do_fetch_inferior_registers): ... this.
364 * win32-low.c (child_fetch_inferior_registers):
365 Go through the low target.
366 (do_child_store_inferior_registers): Use regptr.
367 (strwinerror): New function.
368 (win32_create_inferior): Handle Windows CE.
369 Use strwinerror instead of strerror on Windows error
370 codes. Add program to the error output.
371 Don't close the main thread handle on Windows CE.
372 (win32_attach): Use coredll.dll on Windows CE.
373 (win32_kill): Close current process and current
375 (win32_detach): Use coredll.dll on Windows CE.
376 (win32_resume): Let low target handle debug registers, and
378 (handle_exception): Add/Remove initial breakpoint. Avoid
379 non-existant WSTOPSIG on Windows CE.
380 (win32_read_inferior_memory): Cast to remove warning.
381 (win32_arch_string): Go through the low target.
382 (initialize_low): Call set_breakpoint_data with the low
384 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
385 FOP_REGNUM, mappings): Move to ...
386 * win32-i386-low.c: ... here.
387 * win32-low.c (win32_thread_info): Move to ...
388 * win32-low.h: ... here.
389 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
390 win32-arm-low.c and wincecompat.c.
392 (install-only:): Likewise.
393 (gdbserver:): Likewise.
394 (gdbreplay:): Likewise.
395 * config.in: Regenerate.
396 * configure: Regenerate.
398 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
400 * win32-low.c: Rename typedef thread_info to
401 win32_thread_info throughout.
403 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
405 * win32-i386-low.c: Rename to ...
406 * win32-low.c: ... this.
407 * configure.srv: Replace win32-i386-low.o with win32-low.o.
408 * Makefile.in: Likewise.
410 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
412 * remote-utils.c (monitor_output): Constify msg parameter.
413 * server.h (monitor_output): Likewise.
414 * win32-i386-low.c (handle_output_debug_string): New.
415 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
416 handle_output_debug_string.
417 (get_child_debug_event): Likewise.
419 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
421 * server.c (main): Correct strtoul check.
423 2007-03-27 Jon Ringle <jon@ringle.org>
425 * linux-low.c: Check __ARCH_HAS_MMU__ also.
427 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
429 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
431 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
433 * terminal.h: Check HAVE_SGTTY_H.
435 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
437 * remote-utils.c (remote_open): Print out the assigned port number.
439 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
441 * remote-utils.c (monitor_output): New function.
442 * server.c (debug_threads): Define here.
443 (monitor_show_help): New function.
444 (handle_query): Handle qRcmd.
445 (main): Do not handle 'd' packet.
446 * server.h (debug_threads, remote_debug, monitor_output): Declare.
447 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
450 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
452 * Makefile.in (EXEEXT): New.
453 (clean): Use $(EXEEXT).
455 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
457 * target.h (target_ops): Rename send_signal to request_interrupt,
458 and remove enum target_signal parameter.
459 * linux-low.c (linux_request_interrupt): Rename from
460 linux_send_signal, and always send SIGINT.
461 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
462 and always send SIGINT.
463 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
465 (input_interrupt): Likewise.
467 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
469 * server.c (get_features_xml): Check if target implemented
471 * win32-i386-low.c (win32_arch_string): New.
472 (win32_target_ops): Add win32_arch_string as arch_string member.
474 2007-02-22 Markus Deuling <deuling@de.ibm.com>
476 * spu-low.c (spu_arch_string): New.
477 (spu_target_ops): Add spu_arch_string.
479 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
481 * remote-utils.c: Remove HAVE_TERMINAL_H check.
482 * configure.ac: Do not check for terminal.h.
483 * configure, config.in: Regenerated.
485 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
487 * Makefile.in (OBS): Add $(XML_BUILTIN).
488 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
490 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
491 (arm-with-iwmmxt.c): New.
492 * config.in, configure: Regenerate.
493 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
494 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
495 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
496 (arm*-*-linux*): Add iWMMXt and regset support.
497 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
498 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
499 (arm_store_wmmxregset, target_regsets): New.
500 * server.c (get_features_xml): Take annex argument. Check builtin
502 (handle_query): Handle multiple annexes.
504 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
506 * remote-utils.c [USE_WIN32API] (read, write): Define.
507 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
510 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
512 * linux-i386-low.c (the_low_target): Set arch_string.
513 * linux-x86-64-low.c (the_low_target): Likewise.
514 * linux-low.c (linux_arch_string): New.
515 (linux_target_ops): Add it.
516 * linux-low.h (struct linux_target_ops): Add arch_string.
517 * server.c (write_qxfer_response): Use const void * for DATA.
518 (get_features_xml): New.
519 (handle_query): Handle qXfer:features:read. Report it for qSupported.
520 * target.h (struct target_ops): Add arch_string method.
522 2007-01-03 Denis Pilat <denis.pilat@st.com>
523 Daniel Jacobowitz <dan@codesourcery.com>
525 * linux-low.c (linux_kill): Handle being called with no threads.
526 * win32-i386-low.c (win32_kill): Likewise.
527 (get_child_debug_event): Clear current_process_handle.
529 2006-12-30 Denis PILAT <denis.pilat@st.com>
530 Daniel Jacobowitz <dan@codesourcery.com>
532 * remote-utils.c (remote_open): Check the type of specified
533 serial port devices before opening them.
534 * server.c (main): Kill the inferior if an error occurs during
535 the first remote_open.
537 2006-12-05 Markus Deuling <deuling@de.ibm.com>
539 * README: Update supported targets.
541 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
543 * Makefile.in (clean): Remove reg-mips64.c.
544 (reg-mips64.c, reg-mips64.o): New rules.
545 * configure.srv: Handle mips64. Include regset support for mips.
546 * linux-mips-low.c (union mips_register): New.
547 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
548 (mips_breakpoint, mips_breakpoint_at): Use int.
549 (mips_collect_register, mips_supply_register)
550 (mips_collect_register_32bit, mips_supply_register_32bit)
551 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
552 (mips_store_fpregset, target_regsets): New.
553 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
555 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
557 * configure.srv: Add target "spu*-*-*".
558 * Makefile.in (clean): Remove reg-spu.c.
559 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
560 * spu-low.c: New file.
562 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
564 * configure.ac: Correct td_thr_tls_get_addr test.
565 * configure: Regenerated.
567 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
569 * linux-low.c (linux_wait_for_event): Reformat. Use the
571 * remote-utils.c (decode_address_to_semicolon): New.
572 * server.c (pass_signals, handle_general_set): New.
573 (handle_query): Mention QPassSignals for qSupported.
574 (main): Call handle_general_set.
575 * server.h (pass_signals, decode_address_to_semicolon): New.
577 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
579 * server.c (handle_query): Correct error handling for read_auxv.
581 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
583 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
584 and srv_linux_thread_db to yes.
585 * linux-s390-low.c (s390_fill_gregset): New function.
586 (target_regsets): Define data structure.
588 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
590 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
591 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
592 * config.in, configure: Regenerated.
593 * inferiors.c (gdb_id_to_thread): New function.
594 (gdb_id_to_thread_id): Use it.
595 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
596 * linux-low.h (struct process_info): Add th member.
597 (thread_db_get_tls_address): New prototype.
598 * remote-utils.c (decode_address): Make non-static.
599 * server.c (handle_query): Handle qGetTLSAddr.
600 * server.h (gdb_id_to_thread, decode_address): New prototypes.
601 * target.h (struct target_ops): Add get_tls_address.
602 * thread-db.c (maybe_attach_thread): Save the thread handle.
603 (thread_db_get_tls_address): New.
605 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
607 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
608 (linux_resume_one_process): Take a siginfo_t *. Update all
609 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
610 (struct pending_signals): Add a siginfo_t.
611 (linux_wait_for_process): Always set last_status.
612 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
613 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
614 * linux-low.h (struct process_info): Add last_status.
616 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
618 * remote-utils.c (try_rle): New function.
619 (putpkt_binary): Use it.
621 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
623 * Makefile.in (clean): Clean reg-x86-64-linux.c.
624 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
625 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
626 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
627 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
630 2006-08-08 Richard Sandiford <richard@codesourcery.com>
632 * server.c (terminal_fd): New variable.
633 (old_foreground_pgrp): Likewise.
634 (restore_old_foreground_pgrp): New function.
635 (start_inferior): Record the terminal file descriptor in terminal_fd
636 and its original foreground group in old_foreground_pgrp. Register
637 restore_old_foreground_pgrp with atexit().
639 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
641 * server.c (handle_query): Correct qPart to qXfer.
643 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
645 * configure.ac: Check for more headers which are missing on
646 Windows. Automatically supply -lwsock32 and USE_WIN32API.
647 * configure.srv: Add Cygwin and mingw32.
648 * remote-utils.c: Don't include headers unconditionally which
649 are missing on mingw32. Include <winsock.h> for mingw32.
650 (remote_open): Adjust for mingw32 support. Flush
651 standard error after writing to it.
652 (remote_close, putpkt_binary, input_interrupt, block_async_io)
653 (unblock_async_io, enable_async_io, disable_async_io)
654 (readchar, getpkt): Update for Winsock support.
655 (prepare_resume_reply): Expect a protocol signal number.
656 * server.c: Disable <sys/wait.h> on mingw32.
657 (start_inferior): Adjust for mingw32 support. Flush
658 standard error after writing to it.
659 (attach_inferior): Likewise. Use protocol signal
661 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
663 * win32-i386-low.c: New file.
664 * Makefile.in (XM_CLIBS): Set.
665 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
666 (win32-i386-low.o): New dependency rule.
667 * linux-low.c (linux_wait): Use target signal numbers.
668 * target.h (struct target_ops): Doc fix.
669 * server.h (target_signal_to_name): New prototype.
670 * gdbreplay.c: Don't include headers unconditionally which
671 are missing on mingw32. Include <winsock.h> for mingw32.
672 (remote_close, remote_open): Adjust for Winsock support.
673 * configure, config.in: Regenerated.
675 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
677 * server.c (decode_xfer_read, write_qxfer_response): New.
678 (handle_query): Take a packet length argument. Handle
679 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
680 the qSupported response.
681 (main): Update call to handle_query.
683 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
685 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
686 (putpkt_binary): Renamed from putpkt and adjusted for binary
688 (putpkt): New wrapper for putpkt_binary.
689 (readchar): Don't mask off the high bit.
690 (decode_X_packet): New function.
691 * server.c (main): Call putpkt_binary if a handler sets the packet
692 length. Save the length of the incoming packet. Handle 'X'.
693 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
695 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
697 * server.c (handle_query): Handle qSupported.
699 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
701 * remote-utils.c (all_symbols_looked_up): New variable.
702 (look_up_one_symbol): Check it.
703 * server.h (look_up_one_symbol): New declaration.
704 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
706 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
708 * Makefile.in (linux-arm-low.o): Update dependencies.
709 * linux-arm-low.c: Include "gdb_proc_service.h".
710 (PTRACE_GET_THREAD_AREA): Define.
711 (ps_get_thread_area): New function.
713 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
715 * configure.srv (m68k*-*-uclinux*): New target.
716 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
717 (linux_resume_one_process): Remove extraneous cast.
718 (linux_read_offsets): New.
719 (linux_target_op): Add linux_read_offsets on mmuless systems.
720 * server.c (handle_query): Add qOffsets logic.
721 * target.h (struct target_ops): Add read_offsets.
723 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
725 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
726 (PTRACE_GET_THREAD_AREA): Define.
727 (ps_get_thread_area): New function.
728 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
729 (linux-x86-64-low.o): Update.
731 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
733 * configure.ac: Remove checks for prfpregset_t.
734 * gdb_proc_service.h: New file.
735 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
736 new "gdb_proc_service.h".
737 * proc-service.c: Likewise.
738 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
739 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
740 * Makefile.in (gdb_proc_service_h): Updated.
741 * configure, config.in: Regenerated.
743 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
745 * remote-utils.c (prepare_resume_reply): Move declaration
746 of gdb_id_from_wait to the top of the block.
748 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
750 * linux-low.c (regsets_store_inferior_registers): Read the regset
751 from the target before filling it.
753 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
755 * server.c (attach_inferior): Return SIGTRAP for a successful
758 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
760 * Makefile.in (OBS): Add version.o.
761 (STAGESTUFF): Delete.
762 (version.o): Add dependencies.
763 (version.c): Replace rule.
764 (clean): Remove version.c.
765 * server.c (gdbserver_version): New.
766 (gdbserver_usage): Use printf.
767 (main): Handle --version and --help.
768 * server.h (version, host_name): Add declarations.
770 2005-12-23 Eli Zaretskii <eliz@gnu.org>
782 * linux-x86-64-low.c:
794 * linux-crisv32-low.c:
806 * gdbserver.1: Add (C) after Copyright. Update the FSF
809 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
811 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
812 (arm_breakpoint_at): Recognize both breakpoints.
813 (the_low_target): Use the correct breakpoint instruction.
815 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
817 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
818 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
819 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
820 (the_low_target): Update.
822 2005-10-25 Andreas Schwab <schwab@suse.de>
824 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
826 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
827 (ia64_num_regs): Reduce to 462.
829 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
831 * acinclude.m4: Correct quoting.
832 * aclocal.m4: Regenerated.
834 Suggested by SZOKOVACS Robert <szo@ies.hu>:
835 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
836 (thread_db_init): Call thread_db_err_str.
837 * configure.ac: Check for TD_VERSION.
838 * config.in, configure: Regenerated.
840 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
842 * server.h (error, fatal, warning): Add ATTR_FORMAT.
844 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
846 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
847 is not available. Define HAVE_PTRACE_GETREGS if it is.
848 * config.in, configure: Regenerated.
849 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
850 * linux-i386-low.c, linux-m68k-low.c: Update to use
852 * linux-low.c (regsets_fetch_inferior_registers)
853 (regsets_store_inferior_registers): Only return 0 if we processed
855 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
856 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
858 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
860 * inferiors.c (struct thread_info): Add gdb_id.
861 (add_thread): Add gdb_id argument.
862 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
863 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
865 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
866 * server.c (handle_query): Use thread_to_gdb_id.
867 (handle_v_cont, main): Use gdb_id_to_thread_id.
868 * server.h (add_thread): Update prototype.
869 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
872 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
874 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
875 left-padded registers.
876 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
877 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
879 2005-07-01 Steve Ellcey <sje@cup.hp.com>
881 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
882 * configure: Regenerate.
883 * config.in: Regenerate.
884 * server.h (NEED_DECLARATION_STRERROR):
885 Replace with !HAVE_DECL_STRERROR.
887 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
889 * linux-low.c (linux_wait, linux_send_signal): Don't test
890 an unsigned long variable for > 0 if it could be MAX_ULONG.
891 * server.c (myresume): Likewise.
892 * target.c (set_desired_inferior): Likewise.
894 2005-06-13 Mark Kettenis <kettenis@gnu.org>
896 * configure.ac: Simplify and improve check for socklen_t.
897 * configure, config.in: Regenerate.
899 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
901 * acconfig.h: Remove.
902 * configure.ac: Add a test for socklen_t. Use three-argument
903 AC_DEFINE throughout.
904 * config.in: Regenerated using autoheader 2.59.
905 * configure: Regenerated.
907 * gdbreplay.c (socklen_t): Provide a default.
908 (remote_open): Use socklen_t.
909 * remote-utils.c (socklen_t): Provide a default.
910 (remote_open): Use socklen_t.
911 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
914 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
916 * linux-low.c (linux_read_memory, linux_write_memory)
917 (linux_read_auxv): Likewise.
918 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
919 (check_mem_write): Likewise.
920 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
922 * regcache.c (struct inferior_rgcache_data, registers_to_string)
923 (registers_from_string, register_data): Likewise.
924 * server.c (handle_query, main): Likewise.
925 * server.h (convert_ascii_to_int, convert_int_to_ascii)
926 (decode_M_packet): Likewise.
927 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
928 * target.h (struct target_ops): Update read_memory, write_memory,
930 (read_inferior_memory, write_inferior_memory): Update.
931 * linux-low.h (struct linux_target_ops): Change type of breakpoint
933 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
934 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
935 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
936 linux-s390-low.c, linux-sh-low.c: Update for changes in
937 read_inferior_memory and the_low_target->breakpoint.
939 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
941 * Makefile.in (SFILES): Add linux-ppc64-low.c.
942 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
943 * configure.srv: Add powerpc64-*-linux*.
944 * linux-ppc64-low.c: New file.
946 2005-05-23 Orjan Friberg <orjanf@axis.com>
948 * linux-cris-low.c: New file with support for CRIS.
949 * linux-crisv32-low.c: Ditto for CRISv32.
950 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
951 (clean): Add reg-cris.c and reg-crisv32.c.
952 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
953 reg-crisv32.o, and reg-crisv32.c to make rules.
954 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
957 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
959 * linux-low.c (fetch_register): Ensure buffer size is a multiple
960 of sizeof (PTRACE_XFER_TYPE).
961 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
963 2005-05-12 Orjan Friberg <orjanf@axis.com>
965 * target.h (struct target_ops): Add insert_watchpoint,
966 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
967 pointers for hardware watchpoint support.
968 * linux-low.h (struct linux_target_ops): Ditto.
969 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
970 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
972 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
974 * server.c (main): Recognize 'Z' and 'z' packets.
976 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
978 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
979 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
980 (the_low_target): Add new members.
982 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
984 * proc-service.c (ps_lgetregs): Search all_processes instead of
987 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
989 * server.c (start_inferior): Change return type to int.
990 (attach_inferior): Change sigptr to int *.
991 (handle_v_cont, handle_v_requests): Change signal to int *.
992 (main): Change signal to int.
994 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
996 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
997 * configure.srv: Add m32r*-*-linux*.
998 * linux-m32r-low.c: New file.
1000 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
1002 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
1004 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
1006 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
1007 Take unsigned long arguments for PIDs.
1008 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
1009 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
1010 (wait_for_sigstop, linux_resume_one_process)
1011 (regsets_fetch_inferior_registers, linux_send_signal)
1012 (linux_read_auxv): Likewise. Update the types of variables holding
1013 PIDs. Update format string specifiers.
1014 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
1015 * remote-utils.c (prepare_resume_reply): Likewise.
1016 * server.c (cont_thread, general_thread, step_thread)
1017 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
1019 (handle_query): Update format specifiers.
1020 (handle_v_cont, main): Use strtoul for thread IDs.
1021 * server.h (struct inferior_list_entry): Use unsigned long for ID.
1022 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
1023 (general_thread, step_thread, thread_from_wait)
1024 (old_thread_from_wait): Update.
1025 * target.h (struct thread_resume): Use unsigned long for THREAD.
1026 (struct target_ops): Use unsigned long for arguments to attach and
1029 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
1031 * acinclude.m4: Include bfd/bfd.m4 directly.
1032 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
1033 <agriffis@toolchain.org>.
1034 * aclocal.m4, configure: Regenerated.
1036 2005-01-07 Andrew Cagney <cagney@gnu.org>
1038 * configure.ac: Rename configure.in, require autoconf 2.59.
1039 * configure: Re-generate.
1041 2004-12-08 Daniel Jacobowitz <dan@debian.org>
1043 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
1045 * aclocal.m4: Regenerated.
1046 * configure: Regenerated.
1048 2004-11-21 Andreas Schwab <schwab@suse.de>
1050 * linux-m68k-low.c (m68k_num_gregs): Define.
1051 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
1052 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
1053 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
1054 (m68k_breakpoint_at): New. Add to the_low_target.
1056 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
1057 srv_linux_thread_db to yes.
1059 2004-10-20 Joel Brobecker <brobecker@gnat.com>
1061 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
1062 (ARCH_SET_FS): Likewise.
1063 (ARCH_GET_FS): Likewise.
1064 (ARCH_GET_GS): Likewise.
1066 2004-10-16 Daniel Jacobowitz <dan@debian.org>
1068 * linux-i386-low.c (ps_get_thread_area): New.
1069 * linux-x86-64-low.c (ps_get_thread_area): New.
1070 * linux-low.c: Include <sys/syscall.h>.
1071 (linux_kill_one_process): Don't kill the first thread here.
1072 (linux_kill): Kill the first thread here.
1073 (kill_lwp): New function.
1074 (send_sigstop, linux_send_signal): Use it.
1075 * proc-service.c: Clean up #ifdefs.
1076 (fpregset_info): Delete.
1077 (ps_lgetregs): Update and enable implementation.
1078 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
1080 * remote-utils.c (struct sym_cache, symbol_cache): New.
1081 (input_interrupt): Print a clearer message.
1082 (async_io_enabled): New variable.
1083 (enable_async_io, disable_async_io): Use it. Update comments.
1084 (look_up_one_symbol): Use the symbol cache.
1085 * thread-db.c (thread_db_look_up_symbols): New function.
1086 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
1088 2004-10-16 Daniel Jacobowitz <dan@debian.org>
1090 * configure.in: Test for -rdynamic.
1091 * configure: Regenerated.
1092 * Makefile (INTERNAL_LDFLAGS): New.
1093 (gdbserver, gdbreplay): Use it.
1095 2004-09-02 Andrew Cagney <cagney@gnu.org>
1097 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
1099 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
1101 * linux-low.c (linux_wait): Clear all_processes list also.
1103 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
1105 * linux-low.c: Include <errno.h>. Remove extern declaration of
1108 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
1110 * gdbreplay.c, server.h, utils.c: Update copyright years.
1112 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1114 * server.c (main): Print child status or termination signal from
1115 variable 'signal', not 'sig'.
1117 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1119 * linux-low.c (linux_read_memory): Change return type to
1120 int. Check for and return error from ptrace().
1121 * target.c (read_inferior_memory): Change return type to int. Pass
1122 back return status from the_target->read_memory().
1123 * target.h (struct target_ops): Adapt *read_memory() prototype.
1125 (read_inferior_memory): Adapt prototype.
1126 * server.c (main): Return an error packet if
1127 read_inferior_memory() returns an error.
1129 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
1131 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
1132 Unify with other clean targets.
1134 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1136 * server.c (handle_v_cont): Call set_desired_inferior.
1138 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1140 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
1142 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1144 * linux-low.c (linux_wait): Unblock async I/O.
1145 (linux_resume): Block and enable async I/O.
1146 * remote-utils.c (block_async_io, unblock_async_io): New functions.
1147 * server.h (block_async_io, unblock_async_io): Add prototypes.
1149 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1151 * remote-utils.c (remote_open): Print a status notice after
1153 * server.c (attach_inferior): Print a status notice after
1156 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
1158 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
1160 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
1162 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
1164 * server.c, target.h: Update copyright years.
1166 2004-02-25 Roland McGrath <roland@redhat.com>
1168 * target.h (struct target_ops): New member `read_auxv'.
1169 * server.c (handle_query): Handle qPart:auxv:read: query using that.
1170 * linux-low.c (linux_read_auxv): New function.
1171 (linux_target_ops): Initialize `read_auxv' member to that.
1173 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1175 Committed by Jim Blandy <jimb@redhat.com>.
1177 * linux-s390-low.c (s390_num_regs): Update.
1178 (s390_regmap): Remove control registers. Use __s390x__ predefine
1179 instead of GPR_SIZE to distiguish s390 and s390x targets.
1181 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
1183 * linux-low.c: Update copyright year.
1184 (check_removed_breakpoint): Clear pending_is_breakpoint.
1185 (linux_set_resume_request, linux_queue_one_thread)
1186 (resume_status_pending_p): New functions.
1187 (linux_continue_one_thread): Use process->resume.
1188 (linux_resume): Only resume threads if there are no pending events.
1189 * linux-low.h (struct process_info): Add resume request
1192 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
1194 * regcache.c (new_register_cache): Clear the allocated register
1195 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
1197 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
1199 * linux-low.c (linux_resume): Take a struct thread_resume *
1201 (linux_wait): Update call.
1202 (resume_ptr): New static variable.
1203 (linux_continue_one_thread): Renamed from
1204 linux_continue_one_process. Use resume_ptr.
1205 (linux_resume): Use linux_continue_one_thread.
1206 * server.c (handle_v_cont, handle_v_requests): New functions.
1207 (myresume): New function.
1208 (main): Handle 'v' case.
1209 * target.h (struct thread_resume): New type.
1210 (struct target_ops): Change argument of "resume" to struct
1212 (myresume): Delete macro.
1214 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
1216 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
1217 (uninstall): Support DESTDIR.
1219 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
1221 * configure.srv: Add xscale*linux copy of arm*linux entry.
1223 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
1225 * linux-arm-low.c (arm_reinsert_addr): New function.
1226 (the_low_target): Add arm_reinsert_addr.
1228 2003-07-08 Mark Kettenis <kettenis@gnu.org>
1230 * mem-break.c: Remove whitespace at end of file.
1232 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
1234 * configure.in: Check whether we need to prototype strerror.
1235 * server.h: Optionally prototype strerror.
1236 * gdbreplay.c (perror_with_name): Use strerror.
1237 * linux-low.c (linux_attach_lwp): Use strerror.
1238 * utils.c (perror_with_name): Use strerror.
1239 * config.in, configure: Regenerated.
1241 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
1243 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
1244 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
1246 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
1248 * Makefile.in (SFILES): Update.
1249 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
1250 low-sun3.c: Remove files.
1252 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
1254 * linux-low.c: Move comment to linux_thread_alive where it belonged.
1255 (linux_detach_one_process, linux_detach): New functions.
1256 (linux_target_ops): Add linux_detach.
1257 * server.c (main): Handle 'D' packet.
1258 * target.h (struct target_ops): Add "detach" member.
1259 (detach_inferior): Define.
1261 2003-06-13 Mark Kettenis <kettenis@gnu.org>
1263 From Kelley Cook <kelleycook@wideopenwest.com>:
1264 * configure.srv: Accept i[34567]86 variants.
1266 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
1268 * linux-low.c (linux_wait_for_event): Correct comment typos.
1269 (linux_resume_one_process): Call check_removed_breakpoint.
1270 (linux_send_signal): New function.
1271 (linux_target_ops): Add linux_send_signal.
1272 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
1274 * target.h (struct target_ops): Add send_signal.
1276 2003-05-29 Jim Blandy <jimb@redhat.com>
1278 * linux-low.c (usr_store_inferior_registers): Transfer buf in
1279 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
1280 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
1281 away part of the register's value.
1283 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
1285 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
1286 (linux_wait_for_event, linux_init_signals): Likewise.
1288 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
1290 * configure.in: Check for stdlib.h.
1291 * configure: Regenerated.
1292 * config.in: Regenerated.
1294 2003-01-04 Andreas Schwab <schwab@suse.de>
1296 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
1298 2003-01-02 Andrew Cagney <ac131313@redhat.com>
1300 * Makefile.in: Remove obsolete code.
1302 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
1304 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
1305 defined(PT_FPR0_HI).
1307 2002-11-17 Stuart Hughes <seh@zee2.com>
1309 * linux-arm-low.c (arm_num_regs): Increase.
1310 (arm_regmap): Include status register.
1312 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
1314 * linux-low.c (register_addr): Remove incorrect -1 check.
1316 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
1318 * linux-low.c (linux_create_inferior): Call setpgid. Return
1320 (unstopped_p, linux_signal_pid): Remove.
1321 (linux_target_ops): Remove linux_signal_pid.
1322 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
1323 global instead of target method.
1324 * target.h (struct target_ops): Remove signal_pid. Update comment
1325 for create_inferior.
1326 * server.c (signal_pid): New variable.
1327 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
1328 gdbserver. Set the child to be the foreground process group.
1329 (attach_inferior): Set signal_pid.
1331 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
1333 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
1335 2002-08-20 Jim Blandy <jimb@redhat.com>
1337 * Makefile.in (LDFLAGS): Allow the configure script to establish a
1340 2002-08-01 Andrew Cagney <cagney@redhat.com>
1342 * Makefile.in: Make chill references obsolete.
1344 2002-07-24 Kevin Buettner <kevinb@redhat.com>
1346 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
1347 * configure: Regenerate.
1348 * config.in: Regenerate.
1350 2002-07-09 David O'Brien <obrien@FreeBSD.org>
1352 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
1353 (perror_with_name, remote_close, remote_open, expect, play): Static.
1355 2002-07-04 Michal Ludvig <mludvig@suse.cz>
1357 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
1358 byte offsets instead of an array of indexes.
1359 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
1361 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
1363 * regcache.c: Add comment.
1365 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
1367 * thread-db.c: New file.
1368 * proc-service.c: New file.
1369 * acinclude.m4: New file.
1370 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
1371 proc-service.o, and thread-db.o.
1372 (linux-low.o): Add USE_THREAD_DB.
1373 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
1374 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
1375 * aclocal.m4: Regenerated.
1376 * config.in: Regenerated.
1377 * configure: Regenerated.
1378 * configure.in: Check for proc_service.h, sys/procfs.h,
1379 thread_db.h, and linux/elf.h headrs.
1380 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
1381 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
1382 Check for -lthread_db and thread support.
1383 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
1384 PowerPC, and SuperH.
1385 * i387-fp.c: Constify arguments.
1386 * i387-fp.h: Likewise.
1387 * inferiors.c: (struct thread_info): Renamed from
1388 `struct inferior_info'. Remove PID member. Use generic inferior
1389 list header. All uses updated.
1390 (inferiors, signal_pid): Removed.
1391 (all_threads): New variable.
1392 (get_thread): Define.
1393 (add_inferior_to_list): New function.
1394 (for_each_inferior): New function.
1395 (change_inferior_id): New function.
1396 (add_inferior): Removed.
1397 (remove_inferior): New function.
1398 (add_thread): New function.
1399 (free_one_thread): New function.
1400 (remove_thread): New function.
1401 (clear_inferiors): Use for_each_inferior and free_one_thread.
1402 (find_inferior): New function.
1403 (find_inferior_id): New function.
1404 (inferior_target_data): Update argument type.
1405 (set_inferior_target_data): Likewise.
1406 (inferior_regcache_data): Likewise.
1407 (set_inferior_regcache_data): Likewise.
1408 * linux-low.c (linux_bp_reinsert): Remove.
1409 (all_processes, stopping_threads, using_thrads)
1410 (struct pending_signals, debug_threads, pid_of): New.
1411 (inferior_pid): Replace with macro.
1412 (struct inferior_linux_data): Remove.
1413 (get_stop_pc, add_process): New functions.
1414 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
1415 Use add_process and add_thread.
1416 (linux_attach_lwp): New function, based on old linux_attach. Use
1417 add_process and add_thread. Set stop_expected for new threads.
1418 (linux_attach): New function.
1419 (linux_kill_one_process): New function.
1420 (linux_kill): Kill all LWPs.
1421 (linux_thread_alive): Use find_inferior_id.
1422 (check_removed_breakpoints, status_pending_p): New functions.
1423 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
1424 Update. Use WNOHANG. Wait for cloned processes also. Update process
1425 struct for the found process.
1426 (linux_wait_for_event): New function.
1427 (linux_wait): Use it. Support LWPs.
1428 (send_sigstop, wait_for_sigstop, stop_all_processes)
1429 (linux_resume_one_process, linux_continue_one_process): New functions.
1430 (linux_resume): Support LWPs.
1431 (REGISTER_RAW_SIZE): Remove.
1432 (fetch_register): Use register_size instead. Call supply_register.
1433 (usr_store_inferior_registers): Likewise. Call collect_register.
1435 (regsets_fetch_inferior_registers): Improve error message.
1436 (regsets_store_inferior_registers): Add debugging.
1437 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
1438 (unstopped_p, linux_signal_pid): New functions.
1439 (linux_target_ops): Add linux_signal_pid.
1440 (linux_init_signals): New function.
1441 (initialize_low): Call it. Initialize using_threads.
1442 * regcache.c (inferior_regcache_data): Add valid
1444 (get_regcache): Fetch registers lazily. Add fetch argument
1445 and update all callers.
1446 (regcache_invalidate_one, regcache_invalidate): New
1448 (new_register_cache): Renamed from create_register_cache.
1449 Return the new regcache.
1450 (free_register_cache): Change argument to a void *.
1451 (registers_to_string, registers_from_string): Call get_regcache
1452 with fetch flag set.
1453 (register_data): Make static. Pass fetch flag to get_regcache.
1454 (supply_register): Call get_regcache with fetch flag clear.
1455 (collect_register): Call get_regcache with fetch flag set.
1456 (collect_register_as_string): New function.
1457 * regcache.h: Update.
1458 * remote-utils.c (putpkt): Flush after debug output and use
1460 Handle input interrupts while waiting for an ACK.
1461 (input_interrupt): Use signal_pid method.
1462 (getpkt): Flush after debug output and use stderr.
1463 (outreg): Use collect_register_as_string.
1464 (new_thread_notify, dead_thread_notify): New functions.
1465 (prepare_resume_reply): Check using_threads. Set thread_from_wait
1467 (look_up_one_symbol): Flush after debug output.
1468 * server.c (step_thread, server_waiting): New variables.
1469 (start_inferior): Don't use signal_pid. Update call to mywait.
1470 (attach_inferior): Update call to mywait.
1471 (handle_query): Handle qfThreadInfo and qsThreadInfo.
1472 (main): Don't fetch/store registers explicitly. Use
1473 set_desired_inferior. Support proposed ``Hs'' packet. Update
1476 (struct inferior_list, struct_inferior_list_entry): New.
1477 * target.c (set_desired_inferior): New.
1478 (write_inferior_memory): Constify.
1479 (mywait): New function.
1481 (struct target_ops): New signal_pid method.
1482 (mywait): Removed macro, added prototype.
1484 * linux-low.h (regset_func): Removed.
1485 (regset_fill_func, regset_store_func): New.
1486 (enum regset_type): New.
1487 (struct regset_info): Add type field. Use new operation types.
1488 (struct linux_target_ops): stop_pc renamed to get_pc.
1489 Add decr_pc_after_break and breakpoint_at.
1490 (get_process, get_thread_proess, get_process_thread)
1491 (strut process_info, all_processes, linux_attach_lwp)
1492 (thread_db_init): New.
1494 * linux-arm-low.c (arm_get_pc, arm_set_pc,
1495 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
1496 (the_low_target): Add new members.
1497 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
1498 (i386_store_fpxregset): Constify.
1499 (target_regsets): Add new kind identifier.
1500 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
1501 (i386_set_pc): Add debugging.
1502 (i386_breakpoint_at): New function.
1503 (the_low_target): Add new members.
1504 * linux-mips-low.c (mips_get_pc, mips_set_pc)
1505 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
1506 (mips_breakpoint_at): New.
1507 (the_low_target): Add new members.
1508 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
1509 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
1510 (the_low_target): Add new members.
1511 * linux-sh-low.c (sh_get_pc, sh_set_pc)
1512 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
1513 (the_low_target): Add new members.
1514 * linux-x86-64-low.c (target_regsets): Add new kind
1517 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
1519 From Martin Pool <mbp@samba.org>:
1520 * server.c (gdbserver_usage): New function.
1523 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
1525 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
1528 2002-05-04 Andrew Cagney <ac131313@redhat.com>
1530 * Makefile.in: Remove obsolete code.
1532 2002-04-24 Michal Ludvig <mludvig@suse.cz>
1534 * linux-low.c (regsets_fetch_inferior_registers),
1535 (regsets_store_inferior_registers): Removed cast to int from
1537 * regcache.h: Added declaration of struct inferior_info.
1539 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
1541 * inferiors.c (struct inferior_info): Add regcache_data.
1542 (add_inferior): Call create_register_cache.
1543 (clear_inferiors): Call free_register_cache.
1544 (inferior_regcache_data, set_inferior_regcache_data): New functions.
1545 * regcache.c (struct inferior_regcache_data): New.
1546 (registers): Remove.
1547 (get_regcache): New function.
1548 (create_register_cache, free_register_cache): New functions.
1549 (set_register_cache): Don't initialize the register cache here.
1550 (registers_to_string, registers_from_string, register_data): Call
1552 * regcache.h: Add prototypes.
1553 * server.h: Likewise.
1555 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
1557 * mem-break.c: New file.
1558 * mem-break.h: New file.
1559 * Makefile.in: Add mem-break.o rule; update server.h
1561 * inferiors.c (struct inferior_info): Add target_data
1563 (clear_inferiors): Free target_data member if set.
1564 (inferior_target_data, set_inferior_target_data): New functions.
1565 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
1566 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
1567 * linux-low.c (linux_bp_reinsert): New variable.
1568 (struct inferior_linux_data): New.
1569 (linux_create_inferior): Use set_inferior_target_data.
1570 (linux_attach): Likewise. Call add_inferior.
1571 (linux_wait_for_one_inferior): New function.
1572 (linux_wait): Call it.
1573 (linux_write_memory): Add const.
1574 (initialize_low): Call set_breakpoint_data.
1575 * linux-low.h (struct linux_target_ops): Add breakpoint
1577 * server.c (attach_inferior): Remove extra add_inferior
1579 * server.h: Include mem-break.h. Update inferior.c
1581 * target.c (read_inferior_memory)
1582 (write_inferior_memory): New functions.
1583 * target.h (read_inferior_memory)
1584 (write_inferior_memory): Change macros to prototypes.
1585 (struct target_ops): Update comments. Add const to write_memory
1588 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
1590 * linux-low.c (usr_store_inferior_registers): Support
1591 registers which are allowed to fail to store.
1592 * linux-low.h (linux_target_ops): Likewise.
1593 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
1594 (ppc_cannot_store_register): FPSCR may not be storable.
1596 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
1598 * server.h: Include <string.h> if HAVE_STRING_H.
1599 * ChangeLog: Correct paths in last ChangeLog entry.
1601 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
1603 * linux-low.h: Remove obsolete prototypes.
1604 (struct linux_target_ops): New.
1605 (extern the_low_target): New.
1606 * linux-low.c (num_regs, regmap): Remove declarations.
1607 (register_addr): Use the_low_target explicitly.
1608 (fetch_register): Likewise.
1609 (usr_fetch_inferior_registers): Likewise.
1610 (usr_store_inferior_registers): Likewise.
1611 * linux-arm-low.c (num_regs): Remove.
1612 (arm_num_regs): Define.
1613 (arm_regmap): Renamed from regmap, made static.
1614 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
1616 (arm_cannot_store_register): Renamed from cannot_store_register,
1618 (the_low_target): New.
1619 * linux-i386-low.c (num_regs): Remove.
1620 (i386_num_regs): Define.
1621 (i386_regmap): Renamed from regmap, made static.
1622 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
1624 (i386_cannot_store_register): Renamed from cannot_store_register,
1626 (the_low_target): New.
1627 * linux-ia64-low.c (num_regs): Remove.
1628 (ia64_num_regs): Define.
1629 (ia64_regmap): Renamed from regmap, made static.
1630 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
1632 (ia64_cannot_store_register): Renamed from cannot_store_register,
1634 (the_low_target): New.
1635 * linux-m68k-low.c (num_regs): Remove.
1636 (m68k_num_regs): Define.
1637 (m68k_regmap): Renamed from regmap, made static.
1638 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
1640 (m68k_cannot_store_register): Renamed from cannot_store_register,
1642 (the_low_target): New.
1643 * linux-mips-low.c (num_regs): Remove.
1644 (mips_num_regs): Define.
1645 (mips_regmap): Renamed from regmap, made static.
1646 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
1648 (mips_cannot_store_register): Renamed from cannot_store_register,
1650 (the_low_target): New.
1651 * linux-ppc-low.c (num_regs): Remove.
1652 (ppc_num_regs): Define.
1653 (ppc_regmap): Renamed from regmap, made static.
1654 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
1656 (ppc_cannot_store_register): Renamed from cannot_store_register,
1658 (the_low_target): New.
1659 * linux-s390-low.c (num_regs): Remove.
1660 (s390_num_regs): Define.
1661 (s390_regmap): Renamed from regmap, made static.
1662 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
1664 (s390_cannot_store_register): Renamed from cannot_store_register,
1666 (the_low_target): New.
1667 * linux-sh-low.c (num_regs): Remove.
1668 (sh_num_regs): Define.
1669 (sh_regmap): Renamed from regmap, made static.
1670 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
1672 (sh_cannot_store_register): Renamed from cannot_store_register,
1674 (the_low_target): New.
1675 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
1676 (the_low_target): New.
1678 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
1680 * Makefile.in: Add stamp-h target.
1681 * configure.in: Create stamp-h.
1682 * configure: Regenerated.
1684 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
1686 * inferiors.c: New file.
1687 * target.c: New file.
1688 * target.h: New file.
1689 * Makefile.in: Add target.o and inferiors.o. Update
1691 * linux-low.c (inferior_pid): New static variable,
1692 moved from server.c.
1693 (linux_create_inferior): Renamed from create_inferior.
1694 Call add_inferior. Return 0 on success instead of a PID.
1695 (linux_attach): Renamed from myattach.
1696 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
1697 (linux_thread_alive): Renamed from mythread_alive.
1698 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
1700 (linux_resume): Renamed from myresume. Add missing ``return 0''.
1701 (regsets_store_inferior_registers): Correct error message.
1702 Add missing ``return 0''.
1703 (linux_fetch_registers): Renamed from fetch_inferior_registers.
1704 (linux_store_registers): Renamed from store_inferior_registers.
1705 (linux_read_memory): Renamed from read_inferior_memory.
1706 (linux_write_memory): Renamed from write_inferior_memory.
1707 (linux_target_ops): New structure.
1708 (initialize_low): Call set_target_ops ().
1709 * remote-utils.c (unhexify): New function.
1710 (hexify): New function.
1711 (input_interrupt): Send signals to ``signal_pid''.
1712 * server.c (inferior_pid): Remove.
1713 (start_inferior): Update create_inferior call.
1714 (attach_inferior): Call add_inferior.
1715 (handle_query): New function.
1716 (main): Call handle_query for `q' packets.
1717 * server.h: Include "target.h". Remove obsolete prototypes.
1718 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
1720 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
1722 * Makefile.in: Add WARN_CFLAGS. Update configury
1724 * configure.in: Check for <string.h>
1725 * configure: Regenerate.
1726 * config.in: Regenerate.
1727 * gdbreplay.c: Include needed system headers.
1728 (remote_open): Remove strchr prototype.
1729 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
1730 * regcache.c (supply_register): Change buf argument to const void *.
1731 (supply_register_by_name): Likewise.
1732 (collect_register): Change buf argument to void *.
1733 (collect_register_by_name): Likewise.
1734 * regcache.h: Add missing prototypes.
1735 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
1736 * server.c (handle_query): New function.
1737 (attached): New static variable, moved out of main.
1738 (main): Quiet longjmp clobber warnings.
1739 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
1740 * utils.c (error): Remove NORETURN.