]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/gdbserver/ChangeLog
2007-03-30 Paul Brook <paul@codesourcery.com>
[thirdparty/binutils-gdb.git] / gdb / gdbserver / ChangeLog
CommitLineData
d99f33d8
PA
12007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
2
3 * configure.srv (arm*-*-mingw32ce*): Move near the other
4 arm targets.
5
68070c10
PA
62007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
7
2482afc6 8 * configure.ac: Add errno checking.
68070c10
PA
9 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
10 sys/file.h and malloc.h.
11 (AC_CHECK_DECLS): Add perror.
12 (srv_mingwce): Handle.
2482afc6 13 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
14 win32-i386-low.o to srv_tgtobj.
15 (i[34567]86-*-mingw*): Likewise.
16 (arm*-*-mingw32ce*): Add case.
17 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
19 [__MINGW32CE__] (strerror): New function.
20 [__MINGW32CE__] (errno): Define to GetLastError.
21 [__MINGW32CE__] (COUNTOF): New macro.
22 (remote_open): Remove extra close call.
23 * mem-break.c (delete_breakpoint_at): New function.
24 * mem-break.h (delete_breakpoint_at): Declare.
25 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
26 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
27 [USE_WIN32API] (read, write): Add char* casts.
28 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
29 * server.h: Include wincecompat.h on Windows CE.
30 [HAVE_ERRNO_H]: Check.
31 (perror): Declare if not declared.
32 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
33 (perror_with_name): Remove errno declaration.
34 * wincecompat.h: New.
35 * wincecompat.c: New.
36 * win32-low.h: New.
37 * win32-arm-low.c: New.
38 * win32-i386-low.c: New.
39 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
40 (OUTMSG2): Make it safe.
41 (_T): New macro.
42 (COUNTOF): New macro.
43 (NUM_REGS): Get it from the low target.
44 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
45 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
46 (thread_rec): Let low target handle debug registers.
47 (child_add_thread): Likewise.
48 (child_init_thread_list): Likewise.
49 (continue_one_thread): Likewise.
50 (regptr): New.
51 (do_child_fetch_inferior_registers): Move to ...
52 * win32-i386-low.c: ... here, and rename to ...
53 (do_fetch_inferior_registers): ... this.
54 * win32-low.c (child_fetch_inferior_registers):
55 Go through the low target.
56 (do_child_store_inferior_registers): Use regptr.
57 (strwinerror): New function.
58 (win32_create_inferior): Handle Windows CE.
59 Use strwinerror instead of strerror on Windows error
60 codes. Add program to the error output.
61 Don't close the main thread handle on Windows CE.
62 (win32_attach): Use coredll.dll on Windows CE.
63 (win32_kill): Close current process and current
64 thread handles.
65 (win32_detach): Use coredll.dll on Windows CE.
66 (win32_resume): Let low target handle debug registers, and
67 step request.
68 (handle_exception): Add/Remove initial breakpoint. Avoid
69 non-existant WSTOPSIG on Windows CE.
70 (win32_read_inferior_memory): Cast to remove warning.
71 (win32_arch_string): Go through the low target.
72 (initialize_low): Call set_breakpoint_data with the low
73 target's breakpoint.
74 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
75 FOP_REGNUM, mappings): Move to ...
76 * win32-i386-low.c: ... here.
77 * win32-low.c (win32_thread_info): Move to ...
78 * win32-low.h: ... here.
79 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
80 win32-arm-low.c and wincecompat.c.
81 (all:): Add $EXEEXT.
82 (install-only:): Likewise.
83 (gdbserver:): Likewise.
84 (gdbreplay:): Likewise.
85 * config.in: Regenerate.
86 * configure: Regenerate.
87
41093d81
PA
882007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
89
90 * win32-low.c: Rename typedef thread_info to
91 win32_thread_info throughout.
92
544afa54
PA
932007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
94
95 * win32-i386-low.c: Rename to ...
96 * win32-low.c: ... this.
97 * configure.srv: Replace win32-i386-low.o with win32-low.o.
98 * Makefile.in: Likewise.
99
bce7165d
PA
1002007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
101
102 * remote-utils.c (monitor_output): Constify msg parameter.
103 * server.h (monitor_output): Likewise.
104 * win32-i386-low.c (handle_output_debug_string): New.
105 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
106 handle_output_debug_string.
107 (get_child_debug_event): Likewise.
108
506c7aa0
DJ
1092007-03-27 Mat Hostetter <mat@lcs.mit.edu>
110
111 * server.c (main): Correct strtoul check.
112
42c81e2a
DJ
1132007-03-27 Jon Ringle <jon@ringle.org>
114
115 * linux-low.c: Check __ARCH_HAS_MMU__ also.
116
9453113a
DJ
1172007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
118
119 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
120
64a69107
DJ
1212007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
122
123 * terminal.h: Check HAVE_SGTTY_H.
124
1252007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
126
127 * remote-utils.c (remote_open): Print out the assigned port number.
128
c74d0ad8
DJ
1292007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
130
131 * remote-utils.c (monitor_output): New function.
132 * server.c (debug_threads): Define here.
133 (monitor_show_help): New function.
134 (handle_query): Handle qRcmd.
135 (main): Do not handle 'd' packet.
136 * server.h (debug_threads, remote_debug, monitor_output): Declare.
137 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
138 of debug_threads.
139
de7c3b4a
PA
1402007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
141
142 * Makefile.in (EXEEXT): New.
143 (clean): Use $(EXEEXT).
144
ef57601b
PA
1452007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
146
147 * target.h (target_ops): Rename send_signal to request_interrupt,
148 and remove enum target_signal parameter.
149 * linux-low.c (linux_request_interrupt): Rename from
150 linux_send_signal, and always send SIGINT.
151 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
152 and always send SIGINT.
153 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
154 of send_signal.
155 (input_interrupt): Likewise.
156
820f2bda
PA
1572007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
158
159 * server.c (get_features_xml): Check if target implemented
160 arch_string.
161 * win32-i386-low.c (win32_arch_string): New.
162 (win32_target_ops): Add win32_arch_string as arch_string member.
163
ab39bf24
UW
1642007-02-22 Markus Deuling <deuling@de.ibm.com>
165
166 * spu-low.c (spu_arch_string): New.
167 (spu_target_ops): Add spu_arch_string.
168
61ff6e04
DJ
1692007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
170
171 * remote-utils.c: Remove HAVE_TERMINAL_H check.
172 * configure.ac: Do not check for terminal.h.
173 * configure, config.in: Regenerated.
174
fb1e4ffc
DJ
1752007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
176
177 * Makefile.in (OBS): Add $(XML_BUILTIN).
178 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
179 (clean): Update.
180 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
181 (arm-with-iwmmxt.c): New.
182 * config.in, configure: Regenerate.
183 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
184 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
185 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
186 (arm*-*-linux*): Add iWMMXt and regset support.
187 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
188 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
189 (arm_store_wmmxregset, target_regsets): New.
190 * server.c (get_features_xml): Take annex argument. Check builtin
191 XML documents.
192 (handle_query): Handle multiple annexes.
193
0f48aa01
DJ
1942007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
195
196 * remote-utils.c [USE_WIN32API] (read, write): Define.
197 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
198 write.
199
23181151
DJ
2002007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
201
202 * linux-i386-low.c (the_low_target): Set arch_string.
203 * linux-x86-64-low.c (the_low_target): Likewise.
204 * linux-low.c (linux_arch_string): New.
205 (linux_target_ops): Add it.
206 * linux-low.h (struct linux_target_ops): Add arch_string.
207 * server.c (write_qxfer_response): Use const void * for DATA.
208 (get_features_xml): New.
209 (handle_query): Handle qXfer:features:read. Report it for qSupported.
210 * target.h (struct target_ops): Add arch_string method.
211
9d606399
DJ
2122007-01-03 Denis Pilat <denis.pilat@st.com>
213 Daniel Jacobowitz <dan@codesourcery.com>
214
215 * linux-low.c (linux_kill): Handle being called with no threads.
216 * win32-i386-low.c (win32_kill): Likewise.
217 (get_child_debug_event): Clear current_process_handle.
218
2192006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
220 Daniel Jacobowitz <dan@codesourcery.com>
221
222 * remote-utils.c (remote_open): Check the type of specified
223 serial port devices before opening them.
224 * server.c (main): Kill the inferior if an error occurs during
225 the first remote_open.
226
a5e13d24
DJ
2272006-12-05 Markus Deuling <deuling@de.ibm.com>
228
229 * README: Update supported targets.
230
186947f7
DJ
2312006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
232
233 * Makefile.in (clean): Remove reg-mips64.c.
234 (reg-mips64.c, reg-mips64.o): New rules.
235 * configure.srv: Handle mips64. Include regset support for mips.
236 * linux-mips-low.c (union mips_register): New.
237 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
238 (mips_breakpoint, mips_breakpoint_at): Use int.
239 (mips_collect_register, mips_supply_register)
240 (mips_collect_register_32bit, mips_supply_register_32bit)
241 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
242 (mips_store_fpregset, target_regsets): New.
243 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
244
a13e2c95
UW
2452006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
246
247 * configure.srv: Add target "spu*-*-*".
248 * Makefile.in (clean): Remove reg-spu.c.
249 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
250 * spu-low.c: New file.
251
cb7283db
DJ
2522006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
253
254 * configure.ac: Correct td_thr_tls_get_addr test.
255 * configure: Regenerated.
256
89be2091
DJ
2572006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
258
259 * linux-low.c (linux_wait_for_event): Reformat. Use the
260 pass_signals array.
261 * remote-utils.c (decode_address_to_semicolon): New.
262 * server.c (pass_signals, handle_general_set): New.
263 (handle_query): Mention QPassSignals for qSupported.
264 (main): Call handle_general_set.
265 * server.h (pass_signals, decode_address_to_semicolon): New.
266
000ef4f0
DJ
2672006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
268
269 * server.c (handle_query): Correct error handling for read_auxv.
270
b7149293
UW
2712005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
272
273 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
274 and srv_linux_thread_db to yes.
275 * linux-s390-low.c (s390_fill_gregset): New function.
276 (target_regsets): Define data structure.
277
dae5f5cf
DJ
2782006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
279
280 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
281 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
282 * config.in, configure: Regenerated.
283 * inferiors.c (gdb_id_to_thread): New function.
284 (gdb_id_to_thread_id): Use it.
285 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
286 * linux-low.h (struct process_info): Add th member.
287 (thread_db_get_tls_address): New prototype.
288 * remote-utils.c (decode_address): Make non-static.
289 * server.c (handle_query): Handle qGetTLSAddr.
290 * server.h (gdb_id_to_thread, decode_address): New prototypes.
291 * target.h (struct target_ops): Add get_tls_address.
292 * thread-db.c (maybe_attach_thread): Save the thread handle.
293 (thread_db_get_tls_address): New.
294
32ca6d61
DJ
2952006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
296
297 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
298 (linux_resume_one_process): Take a siginfo_t *. Update all
299 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
300 (struct pending_signals): Add a siginfo_t.
301 (linux_wait_for_process): Always set last_status.
302 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
303 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
304 * linux-low.h (struct process_info): Add last_status.
305
5ffff7c1
DJ
3062006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
307
308 * remote-utils.c (try_rle): New function.
309 (putpkt_binary): Use it.
310
8695c747
DJ
3112006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
312
313 * Makefile.in (clean): Clean reg-x86-64-linux.c.
314 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
315 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
316 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
317 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
318 point registers.
319
290fadea
RS
3202006-08-08 Richard Sandiford <richard@codesourcery.com>
321
322 * server.c (terminal_fd): New variable.
323 (old_foreground_pgrp): Likewise.
324 (restore_old_foreground_pgrp): New function.
325 (start_inferior): Record the terminal file descriptor in terminal_fd
326 and its original foreground group in old_foreground_pgrp. Register
327 restore_old_foreground_pgrp with atexit().
328
9f2e1e63
DJ
3292006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
330
331 * server.c (handle_query): Correct qPart to qXfer.
332
b80864fb
DJ
3332006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
334
335 * configure.ac: Check for more headers which are missing on
336 Windows. Automatically supply -lwsock32 and USE_WIN32API.
337 * configure.srv: Add Cygwin and mingw32.
338 * remote-utils.c: Don't include headers unconditionally which
339 are missing on mingw32. Include <winsock.h> for mingw32.
340 (remote_open): Adjust for mingw32 support. Flush
341 standard error after writing to it.
342 (remote_close, putpkt_binary, input_interrupt, block_async_io)
343 (unblock_async_io, enable_async_io, disable_async_io)
344 (readchar, getpkt): Update for Winsock support.
345 (prepare_resume_reply): Expect a protocol signal number.
346 * server.c: Disable <sys/wait.h> on mingw32.
347 (start_inferior): Adjust for mingw32 support. Flush
348 standard error after writing to it.
349 (attach_inferior): Likewise. Use protocol signal
350 numbers.
351 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
352 and names.
353 * win32-i386-low.c: New file.
354 * Makefile.in (XM_CLIBS): Set.
355 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
356 (win32-i386-low.o): New dependency rule.
357 * linux-low.c (linux_wait): Use target signal numbers.
358 * target.h (struct target_ops): Doc fix.
359 * server.h (target_signal_to_name): New prototype.
360 * gdbreplay.c: Don't include headers unconditionally which
361 are missing on mingw32. Include <winsock.h> for mingw32.
362 (remote_close, remote_open): Adjust for Winsock support.
363 * configure, config.in: Regenerated.
364
0876f84a
DJ
3652006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
366
367 * server.c (decode_xfer_read, write_qxfer_response): New.
368 (handle_query): Take a packet length argument. Handle
369 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
370 the qSupported response.
371 (main): Update call to handle_query.
372
01f9e8fa
DJ
3732006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
374
375 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
376 (putpkt_binary): Renamed from putpkt and adjusted for binary
377 data.
378 (putpkt): New wrapper for putpkt_binary.
379 (readchar): Don't mask off the high bit.
380 (decode_X_packet): New function.
381 * server.c (main): Call putpkt_binary if a handler sets the packet
382 length. Save the length of the incoming packet. Handle 'X'.
383 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
384
be2a5f71
DJ
3852006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
386
387 * server.c (handle_query): Handle qSupported.
388
ea025f5f
DJ
3892006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
390
391 * remote-utils.c (all_symbols_looked_up): New variable.
392 (look_up_one_symbol): Check it.
393 * server.h (look_up_one_symbol): New declaration.
394 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
395
9308fc88
DJ
3962006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
397
398 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 399 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
400 (PTRACE_GET_THREAD_AREA): Define.
401 (ps_get_thread_area): New function.
402
52fb6437
NS
4032006-05-09 Nathan Sidwell <nathan@codesourcery.com>
404
405 * configure.srv (m68k*-*-uclinux*): New target.
406 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
407 (linux_resume_one_process): Remove extraneous cast.
408 (linux_read_offsets): New.
409 (linux_target_op): Add linux_read_offsets on mmuless systems.
410 * server.c (handle_query): Add qOffsets logic.
411 * target.h (struct target_ops): Add read_offsets.
412
21b0f40c
DJ
4132006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
414
415 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
416 (PTRACE_GET_THREAD_AREA): Define.
417 (ps_get_thread_area): New function.
418 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
419 (linux-x86-64-low.o): Update.
420
0050a760
DJ
4212006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
422
423 * configure.ac: Remove checks for prfpregset_t.
424 * gdb_proc_service.h: New file.
425 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
426 new "gdb_proc_service.h".
427 * proc-service.c: Likewise.
428 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
429 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
430 * Makefile.in (gdb_proc_service_h): Updated.
431 * configure, config.in: Regenerated.
432
b92a518e
DJ
4332006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
434
435 * remote-utils.c (prepare_resume_reply): Move declaration
436 of gdb_id_from_wait to the top of the block.
437
545587ee
DJ
4382006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
439
440 * linux-low.c (regsets_store_inferior_registers): Read the regset
441 from the target before filling it.
442
9db87ebd
DJ
4432006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
444
445 * server.c (attach_inferior): Return SIGTRAP for a successful
446 attach.
447
dd24457d
DJ
4482006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
449
450 * Makefile.in (OBS): Add version.o.
451 (STAGESTUFF): Delete.
452 (version.o): Add dependencies.
453 (version.c): Replace rule.
454 (clean): Remove version.c.
455 * server.c (gdbserver_version): New.
456 (gdbserver_usage): Use printf.
457 (main): Handle --version and --help.
458 * server.h (version, host_name): Add declarations.
459
6f0f660e
EZ
4602005-12-23 Eli Zaretskii <eliz@gnu.org>
461
462 * linux-arm-low.c:
463 * linux-arm-low.c:
464 * inferiors.c:
465 * i387-fp.h:
466 * i387-fp.c:
467 * gdbreplay.c:
468 * regcache.c:
469 * proc-service.c:
470 * mem-break.h:
471 * mem-break.c:
472 * linux-x86-64-low.c:
473 * linux-sh-low.c:
474 * linux-s390-low.c:
475 * linux-ppc64-low.c:
476 * linux-ppc-low.c:
477 * linux-mips-low.c:
478 * linux-m68k-low.c:
479 * linux-m32r-low.c:
480 * linux-low.h:
481 * linux-low.c:
482 * linux-ia64-low.c:
483 * linux-i386-low.c:
484 * linux-crisv32-low.c:
485 * thread-db.c:
486 * terminal.h:
487 * target.h:
488 * target.c:
489 * server.h:
490 * server.c:
491 * remote-utils.c:
492 * regcache.h:
493 * utils.c:
494 * Makefile.in:
495 * configure.ac:
496 * gdbserver.1: Add (C) after Copyright. Update the FSF
497 address.
498
9d1fb177
DJ
4992005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
500
501 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
502 (arm_breakpoint_at): Recognize both breakpoints.
503 (the_low_target): Use the correct breakpoint instruction.
504
011a70c2
DJ
5052005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
506
507 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
508 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
509 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
510 (the_low_target): Update.
511
7fb85e41
AS
5122005-10-25 Andreas Schwab <schwab@suse.de>
513
514 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
515
516 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
517 (ia64_num_regs): Reduce to 462.
518
3db0444b
DJ
5192005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
520
521 * acinclude.m4: Correct quoting.
522 * aclocal.m4: Regenerated.
523
524 Suggested by SZOKOVACS Robert <szo@ies.hu>:
525 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
526 (thread_db_init): Call thread_db_err_str.
527 * configure.ac: Check for TD_VERSION.
528 * config.in, configure: Regenerated.
529
bee0189a
DJ
5302005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
531
532 * server.h (error, fatal, warning): Add ATTR_FORMAT.
533
e9d25b98
DJ
5342005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
535
536 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
537 is not available. Define HAVE_PTRACE_GETREGS if it is.
538 * config.in, configure: Regenerated.
539 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
540 * linux-i386-low.c, linux-m68k-low.c: Update to use
541 HAVE_PTRACE_GETREGS.
542 * linux-low.c (regsets_fetch_inferior_registers)
543 (regsets_store_inferior_registers): Only return 0 if we processed
544 GENERAL_REGS.
545 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
546 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
547
a06660f7
DJ
5482005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
549
550 * inferiors.c (struct thread_info): Add gdb_id.
551 (add_thread): Add gdb_id argument.
552 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
553 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
554 calls to add_thread.
555 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
556 * server.c (handle_query): Use thread_to_gdb_id.
557 (handle_v_cont, main): Use gdb_id_to_thread_id.
558 * server.h (add_thread): Update prototype.
559 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
560 prototypes.
561
5a1f5858
DJ
5622005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
563
564 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
565 left-padded registers.
566 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
567 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
568
e122f1f5
SE
5692005-07-01 Steve Ellcey <sje@cup.hp.com>
570
571 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
572 * configure: Regenerate.
573 * config.in: Regenerate.
574 * server.h (NEED_DECLARATION_STRERROR):
575 Replace with !HAVE_DECL_STRERROR.
576
d592fa2f
DJ
5772005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
578
579 * linux-low.c (linux_wait, linux_send_signal): Don't test
580 an unsigned long variable for > 0 if it could be MAX_ULONG.
581 * server.c (myresume): Likewise.
582 * target.c (set_desired_inferior): Likewise.
583
ccbd4912
MK
5842005-06-13 Mark Kettenis <kettenis@gnu.org>
585
586 * configure.ac: Simplify and improve check for socklen_t.
587 * configure, config.in: Regenerate.
588
f450004a
DJ
5892005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
590
591 * acconfig.h: Remove.
592 * configure.ac: Add a test for socklen_t. Use three-argument
593 AC_DEFINE throughout.
594 * config.in: Regenerated using autoheader 2.59.
595 * configure: Regenerated.
596
597 * gdbreplay.c (socklen_t): Provide a default.
598 (remote_open): Use socklen_t.
599 * remote-utils.c (socklen_t): Provide a default.
600 (remote_open): Use socklen_t.
601 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
602 unsigned char.
603
604 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
605 char for buffers.
606 * linux-low.c (linux_read_memory, linux_write_memory)
607 (linux_read_auxv): Likewise.
608 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
609 (check_mem_write): Likewise.
610 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
611 Likewise.
612 * regcache.c (struct inferior_rgcache_data, registers_to_string)
613 (registers_from_string, register_data): Likewise.
614 * server.c (handle_query, main): Likewise.
615 * server.h (convert_ascii_to_int, convert_int_to_ascii)
616 (decode_M_packet): Likewise.
617 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
618 * target.h (struct target_ops): Update read_memory, write_memory,
619 and read_auxv.
620 (read_inferior_memory, write_inferior_memory): Update.
621 * linux-low.h (struct linux_target_ops): Change type of breakpoint
622 to unsigned char *.
623 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
624 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
625 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
626 linux-s390-low.c, linux-sh-low.c: Update for changes in
627 read_inferior_memory and the_low_target->breakpoint.
628
eee84df1
DJ
6292005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
630
631 * Makefile.in (SFILES): Add linux-ppc64-low.c.
632 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
633 * configure.srv: Add powerpc64-*-linux*.
634 * linux-ppc64-low.c: New file.
635
45b134e5
OF
6362005-05-23 Orjan Friberg <orjanf@axis.com>
637
638 * linux-cris-low.c: New file with support for CRIS.
639 * linux-crisv32-low.c: Ditto for CRISv32.
640 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
641 (clean): Add reg-cris.c and reg-crisv32.c.
642 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
643 reg-crisv32.o, and reg-crisv32.c to make rules.
644 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
645 recognized targets.
646
48d93c75
UW
6472005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
648
649 * linux-low.c (fetch_register): Ensure buffer size is a multiple
650 of sizeof (PTRACE_XFER_TYPE).
651 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
652
e013ee27
OF
6532005-05-12 Orjan Friberg <orjanf@axis.com>
654
655 * target.h (struct target_ops): Add insert_watchpoint,
656 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
657 pointers for hardware watchpoint support.
658 * linux-low.h (struct linux_target_ops): Ditto.
659 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
660 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
661 to linux_target_ops.
662 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
663 reply packet.
664 * server.c (main): Recognize 'Z' and 'z' packets.
665
b0ded00b
UW
6662005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
667
668 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
669 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
670 (the_low_target): Add new members.
671
8643e2ad
DJ
6722005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
673
674 * proc-service.c (ps_lgetregs): Search all_processes instead of
675 all_threads.
676
fc620387
DJ
6772005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
678
679 * server.c (start_inferior): Change return type to int.
680 (attach_inferior): Change sigptr to int *.
681 (handle_v_cont, handle_v_requests): Change signal to int *.
682 (main): Change signal to int.
683
6842005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
685
686 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
687 * configure.srv: Add m32r*-*-linux*.
688 * linux-m32r-low.c: New file.
689
e0e76420
DJ
6902005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
691
692 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
693
a1928bad
DJ
6942005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
695
696 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
697 Take unsigned long arguments for PIDs.
698 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
699 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
700 (wait_for_sigstop, linux_resume_one_process)
701 (regsets_fetch_inferior_registers, linux_send_signal)
702 (linux_read_auxv): Likewise. Update the types of variables holding
703 PIDs. Update format string specifiers.
704 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
705 * remote-utils.c (prepare_resume_reply): Likewise.
706 * server.c (cont_thread, general_thread, step_thread)
707 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
708 unsigned long.
709 (handle_query): Update format specifiers.
710 (handle_v_cont, main): Use strtoul for thread IDs.
711 * server.h (struct inferior_list_entry): Use unsigned long for ID.
712 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
713 (general_thread, step_thread, thread_from_wait)
714 (old_thread_from_wait): Update.
715 * target.h (struct thread_resume): Use unsigned long for THREAD.
716 (struct target_ops): Use unsigned long for arguments to attach and
717 thread_alive.
718
dcdb98d2
DJ
7192005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
720
721 * acinclude.m4: Include bfd/bfd.m4 directly.
722 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
723 <agriffis@toolchain.org>.
724 * aclocal.m4, configure: Regenerated.
725
bec39cab
AC
7262005-01-07 Andrew Cagney <cagney@gnu.org>
727
728 * configure.ac: Rename configure.in, require autoconf 2.59.
729 * configure: Re-generate.
730
434c4c77
DJ
7312004-12-08 Daniel Jacobowitz <dan@debian.org>
732
733 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
734 LIBS when finished.
735 * aclocal.m4: Regenerated.
736 * configure: Regenerated.
737
db1d3e1b
AS
7382004-11-21 Andreas Schwab <schwab@suse.de>
739
740 * linux-m68k-low.c (m68k_num_gregs): Define.
741 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
742 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
743 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
744 (m68k_breakpoint_at): New. Add to the_low_target.
745
746 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
747 srv_linux_thread_db to yes.
748
43360365
JB
7492004-10-20 Joel Brobecker <brobecker@gnat.com>
750
751 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
752 (ARCH_SET_FS): Likewise.
753 (ARCH_GET_FS): Likewise.
754 (ARCH_GET_GS): Likewise.
755
fd500816
DJ
7562004-10-16 Daniel Jacobowitz <dan@debian.org>
757
758 * linux-i386-low.c (ps_get_thread_area): New.
759 * linux-x86-64-low.c (ps_get_thread_area): New.
760 * linux-low.c: Include <sys/syscall.h>.
761 (linux_kill_one_process): Don't kill the first thread here.
762 (linux_kill): Kill the first thread here.
763 (kill_lwp): New function.
764 (send_sigstop, linux_send_signal): Use it.
765 * proc-service.c: Clean up #ifdefs.
766 (fpregset_info): Delete.
767 (ps_lgetregs): Update and enable implementation.
768 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
769 implementations.
770 * remote-utils.c (struct sym_cache, symbol_cache): New.
771 (input_interrupt): Print a clearer message.
772 (async_io_enabled): New variable.
773 (enable_async_io, disable_async_io): Use it. Update comments.
774 (look_up_one_symbol): Use the symbol cache.
775 * thread-db.c (thread_db_look_up_symbols): New function.
776 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
777
f6de3c42
DJ
7782004-10-16 Daniel Jacobowitz <dan@debian.org>
779
780 * configure.in: Test for -rdynamic.
781 * configure: Regenerated.
782 * Makefile (INTERNAL_LDFLAGS): New.
783 (gdbserver, gdbreplay): Use it.
784
2c0fc042
AC
7852004-09-02 Andrew Cagney <cagney@gnu.org>
786
787 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
788
075b3282
DJ
7892004-03-23 Daniel Jacobowitz <drow@mvista.com>
790
791 * linux-low.c (linux_wait): Clear all_processes list also.
792
fa6a77dc
DJ
7932004-03-12 Daniel Jacobowitz <drow@mvista.com>
794
795 * linux-low.c: Include <errno.h>. Remove extern declaration of
796 errno.
797
6d782a97
DJ
7982004-03-12 Daniel Jacobowitz <drow@mvista.com>
799
800 * gdbreplay.c, server.h, utils.c: Update copyright years.
801
3a7fb99b
DJ
8022004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
803
804 * server.c (main): Print child status or termination signal from
805 variable 'signal', not 'sig'.
806
c3e735a6
DJ
8072004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
808
809 * linux-low.c (linux_read_memory): Change return type to
810 int. Check for and return error from ptrace().
811 * target.c (read_inferior_memory): Change return type to int. Pass
812 back return status from the_target->read_memory().
813 * target.h (struct target_ops): Adapt *read_memory() prototype.
814 Update comment.
815 (read_inferior_memory): Adapt prototype.
816 * server.c (main): Return an error packet if
817 read_inferior_memory() returns an error.
818
a59d1c82
DJ
8192004-03-04 Daniel Jacobowitz <drow@mvista.com>
820
821 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
822 Unify with other clean targets.
823
dc3f8883
DJ
8242004-02-29 Daniel Jacobowitz <drow@mvista.com>
825
826 * server.c (handle_v_cont): Call set_desired_inferior.
827
89a208da
DJ
8282004-02-29 Daniel Jacobowitz <drow@mvista.com>
829
830 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
831
62ea82f5
DJ
8322004-02-29 Daniel Jacobowitz <drow@mvista.com>
833
834 * linux-low.c (linux_wait): Unblock async I/O.
835 (linux_resume): Block and enable async I/O.
836 * remote-utils.c (block_async_io, unblock_async_io): New functions.
837 * server.h (block_async_io, unblock_async_io): Add prototypes.
838
6910d122
DJ
8392004-02-29 Daniel Jacobowitz <drow@mvista.com>
840
841 * remote-utils.c (remote_open): Print a status notice after
842 opening a TCP port.
843 * server.c (attach_inferior): Print a status notice after
844 attaching.
845
8462004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
847
848 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
849
c89dc5d4
DJ
8502004-02-26 Daniel Jacobowitz <drow@mvista.com>
851
852 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
853 error packet.
854 * server.c, target.h: Update copyright years.
855
4b8dad4a
RM
8562004-02-25 Roland McGrath <roland@redhat.com>
857
858 * target.h (struct target_ops): New member `read_auxv'.
859 * server.c (handle_query): Handle qPart:auxv:read: query using that.
860 * linux-low.c (linux_read_auxv): New function.
861 (linux_target_ops): Initialize `read_auxv' member to that.
862
d7446758
JB
8632004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
864
865 Committed by Jim Blandy <jimb@redhat.com>.
866
867 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 868 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
869 instead of GPR_SIZE to distiguish s390 and s390x targets.
870
5544ad89
DJ
8712004-01-31 Daniel Jacobowitz <drow@mvista.com>
872
873 * linux-low.c: Update copyright year.
874 (check_removed_breakpoint): Clear pending_is_breakpoint.
875 (linux_set_resume_request, linux_queue_one_thread)
876 (resume_status_pending_p): New functions.
877 (linux_continue_one_thread): Use process->resume.
878 (linux_resume): Only resume threads if there are no pending events.
879 * linux-low.h (struct process_info): Add resume request
880 pointer.
881
2a68b70e
DJ
8822004-01-30 Daniel Jacobowitz <drow@mvista.com>
883
884 * regcache.c (new_register_cache): Clear the allocated register
885 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
886
64386c31
DJ
8872003-10-13 Daniel Jacobowitz <drow@mvista.com>
888
889 * linux-low.c (linux_resume): Take a struct thread_resume *
890 argument.
891 (linux_wait): Update call.
892 (resume_ptr): New static variable.
893 (linux_continue_one_thread): Renamed from
894 linux_continue_one_process. Use resume_ptr.
895 (linux_resume): Use linux_continue_one_thread.
896 * server.c (handle_v_cont, handle_v_requests): New functions.
897 (myresume): New function.
898 (main): Handle 'v' case.
899 * target.h (struct thread_resume): New type.
900 (struct target_ops): Change argument of "resume" to struct
901 thread_resume *.
902 (myresume): Delete macro.
903
c938e9b0
L
9042003-08-08 H.J. Lu <hongjiu.lu@intel.com>
905
906 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
907 (uninstall): Support DESTDIR.
908
7f313d07
BC
909Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
910
911 * configure.srv: Add xscale*linux copy of arm*linux entry.
912
3b2fc2ea
DJ
9132003-07-24 Daniel Jacobowitz <drow@mvista.com>
914
915 * linux-arm-low.c (arm_reinsert_addr): New function.
916 (the_low_target): Add arm_reinsert_addr.
917
1c0a559e
MK
9182003-07-08 Mark Kettenis <kettenis@gnu.org>
919
920 * mem-break.c: Remove whitespace at end of file.
921
43d5792c
DJ
9222003-06-28 Daniel Jacobowitz <drow@mvista.com>
923
924 * configure.in: Check whether we need to prototype strerror.
925 * server.h: Optionally prototype strerror.
926 * gdbreplay.c (perror_with_name): Use strerror.
927 * linux-low.c (linux_attach_lwp): Use strerror.
928 * utils.c (perror_with_name): Use strerror.
929 * config.in, configure: Regenerated.
930
c8a86edf
DJ
9312003-06-28 Daniel Jacobowitz <drow@mvista.com>
932
933 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
934 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
935
73d37363
DJ
9362003-06-20 Daniel Jacobowitz <drow@mvista.com>
937
938 * Makefile.in (SFILES): Update.
939 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
940 low-sun3.c: Remove files.
941
6ad8ae5c
DJ
9422003-06-17 Daniel Jacobowitz <drow@mvista.com>
943
944 * linux-low.c: Move comment to linux_thread_alive where it belonged.
945 (linux_detach_one_process, linux_detach): New functions.
946 (linux_target_ops): Add linux_detach.
947 * server.c (main): Handle 'D' packet.
948 * target.h (struct target_ops): Add "detach" member.
949 (detach_inferior): Define.
950
1581182a
MK
9512003-06-13 Mark Kettenis <kettenis@gnu.org>
952
953 From Kelley Cook <kelleycook@wideopenwest.com>:
954 * configure.srv: Accept i[34567]86 variants.
955
e5379b03
DJ
9562003-06-05 Daniel Jacobowitz <drow@mvista.com>
957
958 * linux-low.c (linux_wait_for_event): Correct comment typos.
959 (linux_resume_one_process): Call check_removed_breakpoint.
960 (linux_send_signal): New function.
961 (linux_target_ops): Add linux_send_signal.
962 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
963 of kill.
964 * target.h (struct target_ops): Add send_signal.
965
2ff29de4
JB
9662003-05-29 Jim Blandy <jimb@redhat.com>
967
968 * linux-low.c (usr_store_inferior_registers): Transfer buf in
969 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
970 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
971 away part of the register's value.
972
254787d4
DJ
9732003-03-26 Daniel Jacobowitz <drow@mvista.com>
974
975 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
976 (linux_wait_for_event, linux_init_signals): Likewise.
977
94e10508
DJ
9782003-03-17 Daniel Jacobowitz <drow@mvista.com>
979
980 * configure.in: Check for stdlib.h.
981 * configure: Regenerated.
982 * config.in: Regenerated.
983
4c0711e0
DJ
9842003-01-04 Andreas Schwab <schwab@suse.de>
985
986 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
987
ef66e766
AC
9882003-01-02 Andrew Cagney <ac131313@redhat.com>
989
990 * Makefile.in: Remove obsolete code.
991
a1358604
DJ
9922002-11-20 Daniel Jacobowitz <drow@mvista.com>
993
994 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
995 defined(PT_FPR0_HI).
996
23ce3b1c
DJ
9972002-11-17 Stuart Hughes <seh@zee2.com>
998
999 * linux-arm-low.c (arm_num_regs): Increase.
1000 (arm_regmap): Include status register.
1001
10022002-11-17 Daniel Jacobowitz <drow@mvista.com>
1003
1004 * linux-low.c (register_addr): Remove incorrect -1 check.
1005
a9fa9f7d
DJ
10062002-08-29 Daniel Jacobowitz <drow@mvista.com>
1007
1008 * linux-low.c (linux_create_inferior): Call setpgid. Return
1009 the new PID.
1010 (unstopped_p, linux_signal_pid): Remove.
1011 (linux_target_ops): Remove linux_signal_pid.
1012 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
1013 global instead of target method.
1014 * target.h (struct target_ops): Remove signal_pid. Update comment
1015 for create_inferior.
1016 * server.c (signal_pid): New variable.
1017 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 1018 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
1019 (attach_inferior): Set signal_pid.
1020
17574093
DJ
10212002-08-23 Daniel Jacobowitz <drow@mvista.com>
1022
1023 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
1024
10252002-08-20 Jim Blandy <jimb@redhat.com>
1026
1027 * Makefile.in (LDFLAGS): Allow the configure script to establish a
1028 default for this.
1029
10302002-08-01 Andrew Cagney <cagney@redhat.com>
1031
1032 * Makefile.in: Make chill references obsolete.
1033
10342002-07-24 Kevin Buettner <kevinb@redhat.com>
1035
1036 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
1037 * configure: Regenerate.
1038 * config.in: Regenerate.
1039
10402002-07-09 David O'Brien <obrien@FreeBSD.org>
1041
1042 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
1043 (perror_with_name, remote_close, remote_open, expect, play): Static.
1044
10452002-07-04 Michal Ludvig <mludvig@suse.cz>
1046
4b8dad4a 1047 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
1048 byte offsets instead of an array of indexes.
1049 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
1050
10512002-06-13 Daniel Jacobowitz <drow@mvista.com>
1052
1053 * regcache.c: Add comment.
1054
10552002-06-11 Daniel Jacobowitz <drow@mvista.com>
1056
1057 * thread-db.c: New file.
1058 * proc-service.c: New file.
1059 * acinclude.m4: New file.
1060 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
1061 proc-service.o, and thread-db.o.
1062 (linux-low.o): Add USE_THREAD_DB.
1063 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
1064 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
1065 * aclocal.m4: Regenerated.
1066 * config.in: Regenerated.
1067 * configure: Regenerated.
1068 * configure.in: Check for proc_service.h, sys/procfs.h,
1069 thread_db.h, and linux/elf.h headrs.
1070 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
1071 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
1072 Check for -lthread_db and thread support.
1073 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
1074 PowerPC, and SuperH.
1075 * i387-fp.c: Constify arguments.
1076 * i387-fp.h: Likewise.
1077 * inferiors.c: (struct thread_info): Renamed from
1078 `struct inferior_info'. Remove PID member. Use generic inferior
1079 list header. All uses updated.
1080 (inferiors, signal_pid): Removed.
1081 (all_threads): New variable.
1082 (get_thread): Define.
1083 (add_inferior_to_list): New function.
1084 (for_each_inferior): New function.
1085 (change_inferior_id): New function.
1086 (add_inferior): Removed.
1087 (remove_inferior): New function.
1088 (add_thread): New function.
1089 (free_one_thread): New function.
1090 (remove_thread): New function.
1091 (clear_inferiors): Use for_each_inferior and free_one_thread.
1092 (find_inferior): New function.
1093 (find_inferior_id): New function.
1094 (inferior_target_data): Update argument type.
1095 (set_inferior_target_data): Likewise.
1096 (inferior_regcache_data): Likewise.
1097 (set_inferior_regcache_data): Likewise.
1098 * linux-low.c (linux_bp_reinsert): Remove.
1099 (all_processes, stopping_threads, using_thrads)
1100 (struct pending_signals, debug_threads, pid_of): New.
1101 (inferior_pid): Replace with macro.
1102 (struct inferior_linux_data): Remove.
1103 (get_stop_pc, add_process): New functions.
1104 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
1105 Use add_process and add_thread.
1106 (linux_attach_lwp): New function, based on old linux_attach. Use
1107 add_process and add_thread. Set stop_expected for new threads.
1108 (linux_attach): New function.
1109 (linux_kill_one_process): New function.
1110 (linux_kill): Kill all LWPs.
1111 (linux_thread_alive): Use find_inferior_id.
1112 (check_removed_breakpoints, status_pending_p): New functions.
1113 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
1114 Update. Use WNOHANG. Wait for cloned processes also. Update process
1115 struct for the found process.
1116 (linux_wait_for_event): New function.
1117 (linux_wait): Use it. Support LWPs.
1118 (send_sigstop, wait_for_sigstop, stop_all_processes)
1119 (linux_resume_one_process, linux_continue_one_process): New functions.
1120 (linux_resume): Support LWPs.
1121 (REGISTER_RAW_SIZE): Remove.
1122 (fetch_register): Use register_size instead. Call supply_register.
1123 (usr_store_inferior_registers): Likewise. Call collect_register.
1124 Fix recursive case.
1125 (regsets_fetch_inferior_registers): Improve error message.
1126 (regsets_store_inferior_registers): Add debugging.
1127 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
1128 (unstopped_p, linux_signal_pid): New functions.
1129 (linux_target_ops): Add linux_signal_pid.
1130 (linux_init_signals): New function.
1131 (initialize_low): Call it. Initialize using_threads.
1132 * regcache.c (inferior_regcache_data): Add valid
1133 flag.
1134 (get_regcache): Fetch registers lazily. Add fetch argument
1135 and update all callers.
1136 (regcache_invalidate_one, regcache_invalidate): New
1137 functions.
1138 (new_register_cache): Renamed from create_register_cache.
1139 Return the new regcache.
1140 (free_register_cache): Change argument to a void *.
1141 (registers_to_string, registers_from_string): Call get_regcache
1142 with fetch flag set.
1143 (register_data): Make static. Pass fetch flag to get_regcache.
1144 (supply_register): Call get_regcache with fetch flag clear.
1145 (collect_register): Call get_regcache with fetch flag set.
1146 (collect_register_as_string): New function.
1147 * regcache.h: Update.
1148 * remote-utils.c (putpkt): Flush after debug output and use
1149 stderr.
1150 Handle input interrupts while waiting for an ACK.
1151 (input_interrupt): Use signal_pid method.
1152 (getpkt): Flush after debug output and use stderr.
1153 (outreg): Use collect_register_as_string.
1154 (new_thread_notify, dead_thread_notify): New functions.
1155 (prepare_resume_reply): Check using_threads. Set thread_from_wait
1156 and general_thread.
1157 (look_up_one_symbol): Flush after debug output.
1158 * server.c (step_thread, server_waiting): New variables.
1159 (start_inferior): Don't use signal_pid. Update call to mywait.
1160 (attach_inferior): Update call to mywait.
1161 (handle_query): Handle qfThreadInfo and qsThreadInfo.
1162 (main): Don't fetch/store registers explicitly. Use
1163 set_desired_inferior. Support proposed ``Hs'' packet. Update
1164 calls to mywait.
1165 * server.h: Update.
1166 (struct inferior_list, struct_inferior_list_entry): New.
1167 * target.c (set_desired_inferior): New.
1168 (write_inferior_memory): Constify.
1169 (mywait): New function.
1170 * target.h: Update.
1171 (struct target_ops): New signal_pid method.
1172 (mywait): Removed macro, added prototype.
1173
1174 * linux-low.h (regset_func): Removed.
1175 (regset_fill_func, regset_store_func): New.
1176 (enum regset_type): New.
1177 (struct regset_info): Add type field. Use new operation types.
1178 (struct linux_target_ops): stop_pc renamed to get_pc.
1179 Add decr_pc_after_break and breakpoint_at.
1180 (get_process, get_thread_proess, get_process_thread)
1181 (strut process_info, all_processes, linux_attach_lwp)
1182 (thread_db_init): New.
1183
1184 * linux-arm-low.c (arm_get_pc, arm_set_pc,
1185 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
1186 (the_low_target): Add new members.
1187 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
1188 (i386_store_fpxregset): Constify.
1189 (target_regsets): Add new kind identifier.
1190 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
1191 (i386_set_pc): Add debugging.
1192 (i386_breakpoint_at): New function.
1193 (the_low_target): Add new members.
1194 * linux-mips-low.c (mips_get_pc, mips_set_pc)
1195 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
1196 (mips_breakpoint_at): New.
1197 (the_low_target): Add new members.
1198 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
1199 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
1200 (the_low_target): Add new members.
1201 * linux-sh-low.c (sh_get_pc, sh_set_pc)
1202 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
1203 (the_low_target): Add new members.
1204 * linux-x86-64-low.c (target_regsets): Add new kind
1205 identifier.
1206
12072002-05-15 Daniel Jacobowitz <drow@mvista.com>
1208
1209 From Martin Pool <mbp@samba.org>:
1210 * server.c (gdbserver_usage): New function.
1211 (main): Call it.
1212
12132002-05-14 Daniel Jacobowitz <drow@mvista.com>
1214
1215 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
1216 stop_at -> stop_pc.
1217
12182002-05-04 Andrew Cagney <ac131313@redhat.com>
1219
1220 * Makefile.in: Remove obsolete code.
1221
12222002-04-24 Michal Ludvig <mludvig@suse.cz>
1223
1224 * linux-low.c (regsets_fetch_inferior_registers),
1225 (regsets_store_inferior_registers): Removed cast to int from
1226 ptrace() calls.
1227 * regcache.h: Added declaration of struct inferior_info.
1228
12292002-04-20 Daniel Jacobowitz <drow@mvista.com>
1230
1231 * inferiors.c (struct inferior_info): Add regcache_data.
1232 (add_inferior): Call create_register_cache.
1233 (clear_inferiors): Call free_register_cache.
1234 (inferior_regcache_data, set_inferior_regcache_data): New functions.
1235 * regcache.c (struct inferior_regcache_data): New.
1236 (registers): Remove.
1237 (get_regcache): New function.
1238 (create_register_cache, free_register_cache): New functions.
1239 (set_register_cache): Don't initialize the register cache here.
1240 (registers_to_string, registers_from_string, register_data): Call
1241 get_regcache.
1242 * regcache.h: Add prototypes.
1243 * server.h: Likewise.
1244
12452002-04-20 Daniel Jacobowitz <drow@mvista.com>
1246
1247 * mem-break.c: New file.
1248 * mem-break.h: New file.
1249 * Makefile.in: Add mem-break.o rule; update server.h
1250 dependencies.
1251 * inferiors.c (struct inferior_info): Add target_data
1252 member.
1253 (clear_inferiors): Free target_data member if set.
1254 (inferior_target_data, set_inferior_target_data): New functions.
1255 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
1256 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
1257 * linux-low.c (linux_bp_reinsert): New variable.
1258 (struct inferior_linux_data): New.
1259 (linux_create_inferior): Use set_inferior_target_data.
1260 (linux_attach): Likewise. Call add_inferior.
1261 (linux_wait_for_one_inferior): New function.
1262 (linux_wait): Call it.
1263 (linux_write_memory): Add const.
1264 (initialize_low): Call set_breakpoint_data.
1265 * linux-low.h (struct linux_target_ops): Add breakpoint
1266 handling members.
1267 * server.c (attach_inferior): Remove extra add_inferior
1268 call.
1269 * server.h: Include mem-break.h. Update inferior.c
1270 prototypes.
1271 * target.c (read_inferior_memory)
1272 (write_inferior_memory): New functions.
1273 * target.h (read_inferior_memory)
1274 (write_inferior_memory): Change macros to prototypes.
1275 (struct target_ops): Update comments. Add const to write_memory
1276 definition.
1277
12782002-04-11 Daniel Jacobowitz <drow@mvista.com>
1279
1280 * linux-low.c (usr_store_inferior_registers): Support
1281 registers which are allowed to fail to store.
1282 * linux-low.h (linux_target_ops): Likewise.
1283 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
1284 (ppc_cannot_store_register): FPSCR may not be storable.
1285
12862002-04-09 Daniel Jacobowitz <drow@mvista.com>
1287
1288 * server.h: Include <string.h> if HAVE_STRING_H.
1289 * ChangeLog: Correct paths in last ChangeLog entry.
1290
12912002-04-09 Daniel Jacobowitz <drow@mvista.com>
1292
1293 * linux-low.h: Remove obsolete prototypes.
1294 (struct linux_target_ops): New.
1295 (extern the_low_target): New.
1296 * linux-low.c (num_regs, regmap): Remove declarations.
1297 (register_addr): Use the_low_target explicitly.
1298 (fetch_register): Likewise.
1299 (usr_fetch_inferior_registers): Likewise.
1300 (usr_store_inferior_registers): Likewise.
1301 * linux-arm-low.c (num_regs): Remove.
1302 (arm_num_regs): Define.
1303 (arm_regmap): Renamed from regmap, made static.
1304 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
1305 made static.
1306 (arm_cannot_store_register): Renamed from cannot_store_register,
1307 made static.
1308 (the_low_target): New.
1309 * linux-i386-low.c (num_regs): Remove.
1310 (i386_num_regs): Define.
1311 (i386_regmap): Renamed from regmap, made static.
1312 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
1313 made static.
1314 (i386_cannot_store_register): Renamed from cannot_store_register,
1315 made static.
1316 (the_low_target): New.
1317 * linux-ia64-low.c (num_regs): Remove.
1318 (ia64_num_regs): Define.
1319 (ia64_regmap): Renamed from regmap, made static.
1320 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
1321 made static.
1322 (ia64_cannot_store_register): Renamed from cannot_store_register,
1323 made static.
1324 (the_low_target): New.
1325 * linux-m68k-low.c (num_regs): Remove.
1326 (m68k_num_regs): Define.
1327 (m68k_regmap): Renamed from regmap, made static.
1328 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
1329 made static.
1330 (m68k_cannot_store_register): Renamed from cannot_store_register,
1331 made static.
1332 (the_low_target): New.
1333 * linux-mips-low.c (num_regs): Remove.
1334 (mips_num_regs): Define.
1335 (mips_regmap): Renamed from regmap, made static.
1336 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
1337 made static.
1338 (mips_cannot_store_register): Renamed from cannot_store_register,
1339 made static.
1340 (the_low_target): New.
1341 * linux-ppc-low.c (num_regs): Remove.
1342 (ppc_num_regs): Define.
1343 (ppc_regmap): Renamed from regmap, made static.
1344 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
1345 made static.
1346 (ppc_cannot_store_register): Renamed from cannot_store_register,
1347 made static.
1348 (the_low_target): New.
1349 * linux-s390-low.c (num_regs): Remove.
1350 (s390_num_regs): Define.
1351 (s390_regmap): Renamed from regmap, made static.
1352 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
1353 made static.
1354 (s390_cannot_store_register): Renamed from cannot_store_register,
1355 made static.
1356 (the_low_target): New.
1357 * linux-sh-low.c (num_regs): Remove.
1358 (sh_num_regs): Define.
1359 (sh_regmap): Renamed from regmap, made static.
1360 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
1361 made static.
1362 (sh_cannot_store_register): Renamed from cannot_store_register,
1363 made static.
1364 (the_low_target): New.
1365 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
1366 (the_low_target): New.
1367
13682002-04-09 Daniel Jacobowitz <drow@mvista.com>
1369
1370 * Makefile.in: Add stamp-h target.
1371 * configure.in: Create stamp-h.
1372 * configure: Regenerated.
1373
13742002-04-09 Daniel Jacobowitz <drow@mvista.com>
1375
1376 * inferiors.c: New file.
1377 * target.c: New file.
1378 * target.h: New file.
1379 * Makefile.in: Add target.o and inferiors.o. Update
1380 dependencies.
1381 * linux-low.c (inferior_pid): New static variable,
1382 moved from server.c.
1383 (linux_create_inferior): Renamed from create_inferior.
1384 Call add_inferior. Return 0 on success instead of a PID.
1385 (linux_attach): Renamed from myattach.
1386 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
1387 (linux_thread_alive): Renamed from mythread_alive.
1388 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
1389 child dies.
1390 (linux_resume): Renamed from myresume. Add missing ``return 0''.
1391 (regsets_store_inferior_registers): Correct error message.
1392 Add missing ``return 0''.
1393 (linux_fetch_registers): Renamed from fetch_inferior_registers.
1394 (linux_store_registers): Renamed from store_inferior_registers.
1395 (linux_read_memory): Renamed from read_inferior_memory.
1396 (linux_write_memory): Renamed from write_inferior_memory.
1397 (linux_target_ops): New structure.
1398 (initialize_low): Call set_target_ops ().
1399 * remote-utils.c (unhexify): New function.
1400 (hexify): New function.
1401 (input_interrupt): Send signals to ``signal_pid''.
1402 * server.c (inferior_pid): Remove.
1403 (start_inferior): Update create_inferior call.
1404 (attach_inferior): Call add_inferior.
1405 (handle_query): New function.
1406 (main): Call handle_query for `q' packets.
1407 * server.h: Include "target.h". Remove obsolete prototypes.
1408 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
1409
14102002-04-09 Daniel Jacobowitz <drow@mvista.com>
1411
1412 * Makefile.in: Add WARN_CFLAGS. Update configury
1413 dependencies.
1414 * configure.in: Check for <string.h>
1415 * configure: Regenerate.
1416 * config.in: Regenerate.
1417 * gdbreplay.c: Include needed system headers.
1418 (remote_open): Remove strchr prototype.
1419 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
1420 * regcache.c (supply_register): Change buf argument to const void *.
1421 (supply_register_by_name): Likewise.
1422 (collect_register): Change buf argument to void *.
1423 (collect_register_by_name): Likewise.
1424 * regcache.h: Add missing prototypes.
1425 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
1426 * server.c (handle_query): New function.
1427 (attached): New static variable, moved out of main.
1428 (main): Quiet longjmp clobber warnings.
1429 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
1430 * utils.c (error): Remove NORETURN.
1431 (fatal): Likewise.