]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/gdbserver/ChangeLog
2008-08-31 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
[thirdparty/binutils-gdb.git] / gdb / gdbserver / ChangeLog
CommitLineData
400b20f5
MR
12008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
2
3 * Makefile.in (uninstall): Apply $(EXEEXT) too.
4
677c5bb1
LM
52008-08-18 Luis Machado <luisgpm@br.ibm.com>
6
7 * Makefile.in: Add required vsx dependencies.
8
9 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
10 Declare init_registers_powerpc_vsx32l.
11 Declare init_registers_powerpc_vsx64l.
12 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
13 (ppc_arch_setup): Check for VSX in hwcap.
14 (ppc_fill_vsxregset): New function.
15 (ppc_store_vsxregset): New function.
16 Add new VSX entry in regset_info target_regsets.
17
18 * configure.srv: Add new VSX dependencies.
19
a6f3e723
SL
202008-08-12 Pedro Alves <pedro@codesourcery.com>
21
22 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
23 (remote_open): Set or clear transport_is_reliable.
24 (putpkt_binary): Don't expect acks in noack mode.
25 (getpkt): Don't send ack/nac in noack mode.
26 * server.c (handle_general_set): Handle QStartNoAckMode.
27 (handle_query): If connected by tcp pass QStartNoAckMode+ in
28 qSupported.
29 (main): Reset noack_mode on every connection.
30 * server.h (noack_mode): Declare.
31
a417dc56
RW
322008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
33
34 * Makefile.in (GDBREPLAY_OBS): New variable.
35 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
36
3221518c
UW
372008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
38 Daniel Jacobowitz <dan@codesourcery.com>
39
40 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
41 (usr_store_inferior_registers): Likewise.
42 (regsets_store_inferior_registers): Likewise.
43
ec56be1b
PA
442008-07-31 Rolf Jansen <rj@surtec.com>
45 Pedro Alves <pedro@codesourcery.com>
46
47 * configure.ac: Check for memmem declaration.
48 * server.c [HAVE_MALLOC_H]: Include malloc.h.
49 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
50 (disable_packet_qfThreadInfo): Unconditionally compile.
51 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
52 * configure, config.in: Regenerate.
53
2fe5e3ff
DE
542008-07-28 Doug Kwan <dougkwan@google.com>
55
56 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
57 (linux_write_memory): Remove declaration of errno.
58
836acd6d
UW
592008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
60
61 * linux-low.c (handle_extended_wait): Do not use "status"
62 variable uninitialized.
63
aeba519e
PA
642008-07-07 Pedro Alves <pedro@codesourcery.com>
65
66 * server.c (handle_v_attach): Inhibit reporting dll changes.
67
db42f210
PA
682008-06-27 Pedro Alves <pedro@codesourcery.com>
69
70 * remote-utils.c (prepare_resume_reply): If requested, don't
71 output "thread:TID" in the T stop reply.
72
73 * server.c (disable_packet_vCont, disable_packet_Tthread)
74 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
75 (handle_query): If requested, disable support for qC, qfThreadInfo
76 and qsThreadInfo.
77 (handle_v_requests): If requested, disable support for vCont.
78 (gdbserver_show_disableable): New.
79 (main): Handle --disable-packet and --disable-packet=LIST.
80
81 * server.h (disable_packet_vCont, disable_packet_Tthread)
82 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
83
8e4c5421
CD
842008-06-20 Carlos O'Donell <carlos@codesourcery.com>
85
86 * server.c (gdbserver_usage): Mention --version.
87
6e23a804
DJ
882008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
89
90 * Makefile.in (gdbreplay.o): New rule.
91
90aa6a40
JM
922008-06-06 Joseph Myers <joseph@codesourcery.com>
93
94 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
95 message, not gdbserver.
96
c16158bc
JM
972008-06-05 Vladimir Prus <vladimir@codesourcery.com>
98 Nathan Sidwell <nathan@codesourcery.com>
99 Joseph Myers <joseph@codesourcery.com>
100
101 * acinclude.m4: Include ../../config/acx.m4.
102 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
103 * configure, config.in: Regenerate.
104 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
105 * server.c (gdbserver_version): Print PKGVERSION.
106 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
107 (main): Adjust gdbserver_usage calls.
108 * gdbreplay.c (version, host_name): Add declarations.
109 (gdbreplay_version, gdbreplay_usage): New.
110 (main): Accept --version and --help options.
111
aeb75bf5
DJ
1122008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
113
114 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
115 (arm_breakpoint_at): Handle Thumb.
116 (the_low_target): Add comment.
117
76b233dd
UW
1182008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
119
120 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
121
08388c79
DE
1222008-05-09 Doug Evans <dje@google.com>
123
a3c83fae
DE
124 * server.h (decode_search_memory_packet): Declare.
125 * remote-utils.c (decode_search_memory_packet): New fn.
126 * server.c (handle_search_memory_1): New fn.
08388c79
DE
127 (handle_search_memory): New fn.
128 (handle_query): Process qSearch:memory packets.
129
bb9c3d36
UW
1302008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
131
132 * regcache.c (registers_length): Remove.
133 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
134 full register packet.
135 * regcache.h (registers_length): Remove prototype.
136 * server.h (PBUFSIZ): Define to 16384.
137
7284e1be
UW
1382008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
139
140 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
141 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
142 powerpc-64l.o, and powerpc-altivec64l.o.
143 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
144 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
145 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
146 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
147 rs6000/power-linux.xml, and rs6000/power64-linux.xml
148 to srv_xmlfiles.
149
150 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
151 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
152 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
153 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
154 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
155 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
156 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
157 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
158 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
159 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
160 (clean): Update.
161
162 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
163 (init_registers_powerpc_32l): ... this new prototype.
164 (init_registers_powerpc_32): Remove, replace by ...
165 (init_registers_powerpc_altivec32l): ... this new prototype.
166 (init_registers_powerpc_e500): Remove, replace by ...
167 (init_registers_powerpc_e500l): ... this new prototype.
168 (init_registers_ppc64): Remove, replace by ...
169 (init_registers_powerpc_64l): ... this new prototype.
170 (init_registers_powerpc_64): Remove, replace by ...
171 (init_registers_powerpc_altivec64l): ... this new prototype.
172 (ppc_num_regs): Set to 73.
173 (PT_ORIG_R3, PT_TRAP): Define if necessary.
174 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
175 (ppc_cannot_store_register): Handle orig_r3 and trap.
176 (ppc_arch_setup): Update init_registers_... calls.
177 (ppc_fill_gregset): Handle orig_r3 and trap.
178
179 * inferiors.c (clear_inferiors): Reset current_inferior.
180
fdc59709
PB
1812008-04-23 Paolo Bonzini <bonzini@gnu.org>
182
183 * acinclude.m4: Add override.m4.
184 * configure: Regenerate.
185
c9b2f845
UW
1862008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
187
188 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
189 initial call to init_register_ppc64.
190
550512b8
UW
1912008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
192
193 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into single
194 powerpc*-*-linux* case.
195 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
196
b6430ec3
UW
1972008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
198
199 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
200 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
201 from reg_xmlfiles.
202 * linux-ppc-low.c: Include <elf.h>.
203 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
204 (ppc_hwcap): New global variable.
205 (ppc_regmap): Remove __SPE__ #ifdef sections.
206 (ppc_regmap_e500): New global variable.
207 (ppc_cannot_store_register): Update __SPE__ special case.
208 (ppc_get_hwcap): New function.
209 (ppc_arch_setup): Use it to determine whether inferior supports
210 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
211 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
212 Do not access registers if target does not support AltiVec.
213 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
214 Do not access registers if target does not support SPE.
215 (target_regsets): Unconditionally include AltiVec and SPE regsets.
216
52fa2412
UW
2172008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
218
219 * linux-low.c (disabled_regsets, num_regsets): New.
220 (use_regsets_p): Delete.
221 (linux_wait_for_process): Clear disabled_regsets.
222 (regsets_fetch_inferior_registers): Check and set it.
223 (regsets_store_inferior_registers): Likewise.
224 (linux_fetch_registers, linux_store_registers): Do not use
225 use_regsets_p.
226 (initialize_low): Allocate disabled_regsets.
227
e28b3332
DJ
2282008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
229
230 * Makefile.in (LIBOBJS): New.
231 (OBS): Use LIBOBJS.
232 (memmem.o): New rule.
233 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
234 * configure: Regenerated.
235
4536995d
UW
2362008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
237
238 * server.c (handle_query): Never return "unsupported" for
239 qXfer:features:read queries.
240
221c031f
UW
2412008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
242
243 * server.c (get_features_xml): Fix inverted condition.
244 (handle_query): Always support qXfer:feature:read.
245
ccd213ac
DJ
2462008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
247
248 * server.c (wrapper_argv): New.
249 (start_inferior): Handle wrapper_argv. If set, expect an extra
250 trap.
251 (gdbserver_usage): Document --wrapper.
252 (main): Parse --wrapper.
253
6fe305f7
UW
2542008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
255
256 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
257 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
258 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
259 (ppc_set_pc): Likewise.
260 (ppc_arch_setup): New function.
261 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
262 of collect_register.
263 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
264
5b0a002e
UW
2652008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
266
267 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
268 instead of linux-ppc64-low.o.
269 * linux-ppc64-low.c: Remove file.
270 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
271 (linux-ppc64-low.o): Remove rule.
272
273 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
274 (init_registers_powerpc_64): Likewise.
275 (ppc_regmap): Conditionally define depending on __powerpc64__.
276 (ppc_cannot_store_register): Do not special-case "fpscr" when
277 compiled on __powerpc64__.
278 (ppc_collect_ptrace_register): New function.
279 (ppc_supply_ptrace_register): New function.
280 (ppc_breakpoint): Change type to "unsigned int".
281 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
282 (the_low_target): Conditionally provide initializers for the
283 arch_setup member depending on __powerpc64__. Install
284 collect_ptrace_register and supply_ptrace_register members.
285
9b4b61c8
UW
2862008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
287
288 * regcache.h (gdbserver_xmltarget): Add extern declaration.
289 * server.c (gdbserver_xmltarget): Define.
290 (get_features_xml): Use it to replace "target.xml" and arch_string.
291
292 * configure.srv: Remove srv_xmltarget. Add XML files that were
293 mentioned there to srv_xmlfiles instead. Remove conditional tests
294 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
295 srv_xmlfiles and srv_regobj to include all possible choices.
296 * configure.ac (srv_xmltarget): Remove.
297 (srv_xmlfiles): Do not add "target.xml".
298 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
299 checks for supplementary target information.
300 * configure: Regenerate.
301 * Makefile.in (XML_TARGET): Remove.
302 (target.xml): Remove rule.
303 (clean): Do not clean up target.xml.
304 (.PRECIOUS): Do not mention target.xml.
305
306 * target.h (struct target_ops): Remove arch_string member.
307 * linux-low.c (linux_arch_string): Remove.
308 (linux_target_ops): Remove arch_string initializer.
309 * linux-low.h (struct linux_target_ops): Remove arch_string member.
310 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
311 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
312 * spu-low.c (spu_arch_string): Remove.
313 (spu_target_ops): Remove arch_string initializer.
314 * win32-low.c (win32_arch_string): Remove.
315 (win32_target_ops): Remove arch_string initializer.
316 * win32-low.h (struct win32_target_ops): Remove arch_string member.
317 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
318 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
319
ee1a7ae4
UW
3202008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
321
322 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
323 by collect_ptrace_register and supply_ptrace_register hooks.
324 * linux-low.c (fetch_register): Use supply_ptrace_register callback
325 instead of checking for the_low_target.left_pad_xfer.
326 (usr_store_inferior_registers): Use collect_ptrace_register callback
327 instead of checking for the_low_target.left_pad_xfer.
328
329 * linux-s390-low.c (s390_collect_ptrace_register): New function.
330 (s390_supply_ptrace_register): Likewise.
331 (s390_fill_gregset): Call s390_collect_ptrace_register.
332 (the_low_target): Update.
333
334 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
335 (ppc_supply_ptrace_register): Likewise.
336 (the_low_target): Update.
337
338 * linux-i386-low.c (the_low_target): Update.
339 * linux-x86-64-low.c (the_low_target): Update.
340
d61ddec4
UW
3412008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
342
343 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
344 reg-s390.o and reg-s390x.o.
345
346 * linux-low.c (new_inferior): New global variable.
347 (linux_create_inferior, linux_attach): Set it.
348 (linux_wait_for_process): Call the_low_target.arch_setup after the
349 target has stopped for the first time.
350 (initialize_low): Do not call the_low_target.arch_setup.
351
352 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
353 (s390_set_pc): Likewise.
354 (s390_arch_setup): New function.
355 (the_low_target): Use s390_arch_setup as arch_setup routine.
356
357 * regcache.c (realloc_register_cache): New function.
358 (set_register_cache): Call it for each existing regcache.
359
d05b4ac3
UW
3602008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
361
362 * server.h (init_registers): Remove prototype.
363
364 * linux-low.h (struct linux_target_ops): Add arch_setup field.
365 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
366 instead of init_registers ().
367 * linux-arm-low.c (init_registers_arm): Add prototype.
368 (init_registers_arm_with_iwmmxt): Likewise.
369 (the_low_target): Add initializer for arch_setup field.
370 * linux-cris-low.c (init_registers_cris): Add prototype.
371 (the_low_target): Add initializer for arch_setup field.
372 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
373 (the_low_target): Add initializer for arch_setup field.
374 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
375 (the_low_target): Add initializer for arch_setup field.
376 * linux-ia64-low.c (init_registers_ia64): Add prototype.
377 (the_low_target): Add initializer for arch_setup field.
378 * linux-m32r-low.c (init_registers_m32r): Add prototype.
379 (the_low_target): Add initializer for arch_setup field.
380 * linux-m68k-low.c (init_registers_m68k): Add prototype.
381 (the_low_target): Add initializer for arch_setup field.
382 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
383 (init_registers_mips64_linux): Likewise.
384 (the_low_target): Add initializer for arch_setup field.
385 * linux-ppc-low.c (init_registers_ppc): Add prototype.
386 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
387 (the_low_target): Add initializer for arch_setup field.
388 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
389 (init_registers_powerpc_64): Likewise.
390 (the_low_target): Add initializer for arch_setup field.
391 * linux-s390-low.c (init_registers_s390): Add prototype.
392 (init_registers_s390x): Likewise.
393 (the_low_target): Add initializer for arch_setup field.
394 * linux-sh-low.c (init_registers_sh): Add prototype.
395 (the_low_target): Add initializer for arch_setup field.
396 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
397 (the_low_target): Add initializer for arch_setup field.
398 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
399 (the_low_target): Add initializer for arch_setup field.
400
401 * win32-low.h (struct win32_target_ops): Add arch_setup field.
402 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
403 instead of init_registers ().
404 * win32-arm-low.c (init_registers_arm): Add prototype.
405 (the_low_target): Add initializer for arch_setup field.
406 * win32-i386-low.c (init_registers_i386): Add prototype.
407 (the_low_target): Add initializer for arch_setup field.
408
409 * spu-low.c (init_registers_spu): Add prototype.
410 (initialize_low): Call initialie_registers_spu () instead of
411 initialize_registers ().
412
fd96d250
PA
4132008-02-19 Pedro Alves <pedro@codesourcery.com>
414
415 * server.c (handle_v_requests): When handling the vRun and vAttach
416 packets, if already debugging a process, don't kill it. Return an
417 error instead.
418
d41b6bb4
DJ
4192008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
420
421 * server.c (handle_query): Correct length check.
422
5ac588cf
PA
4232008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
424
425 * win32-low.c (do_initial_child_stuff): Add process handle
426 parameter. Set current_process_handle and current_process_id from the
427 parameters. Clear globals.
428 (win32_create_inferior): Don't set current_process_handle and
429 current_process_id here. Instead pass them on the call to
430 do_initial_child_stuff.
431 (win32_attach): Likewise.
432 (win32_clear_inferiors): New.
433 (win32_kill): Don't close the current process handle or the
434 current thread handle here. Instead call win32_clear_inferiors.
435 (win32_detach): Don't open a new handle to the process. Call
436 win32_clear_inferiors.
437 (win32_join): Don't rely on current_process_handle; open a new
438 handle using the process id.
439 (win32_wait): Call win32_clear_inferiors when the inferior process
440 has exited.
441
ecd7ecbc
DJ
4422008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
443
444 * server.c (monitor_show_help): Add "exit".
445
1525d545
MG
4462008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
447
ecd7ecbc 448 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
449 (clean): Add reg-xtensa.c.
450 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
451 * configure.srv (xtensa*-*-linux*) New target.
452 * linux-xtensa-low.c: New.
453 * xtensa-xtregs.c: New.
1525d545 454
59a016f0
PA
4552008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
456
457 * hostio.c: Don't include errno.h.
458 (errno_to_fileio_errno): Move to hostio-errno.
459 * hostio.c: (hostio_error): Remove the error parameter. Defer the
460 error number outputting to the target->hostio_last_error callback.
461 (hostio_packet_error): Use FILEIO_EINVAL directly.
462 (handle_open, handle_pread, hostio_error, handle_unlink): Update
463 calls to hostio_error.
464 * hostio-errno.c: New.
465 * server.h (hostio_last_error_from_errno): Declare.
466 * target.h (target_ops): Add hostio_last_error member.
467 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
468 as hostio_last_error handler.
469 * spu-low.c (spu_target_ops): Likewise.
470 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
471 (wince_hostio_last_error): New functions.
472 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
473 as hostio_last_error handler.
474 (win32_target_ops) [!_WIN32_WCE]: Register
475 hostio_last_error_from_errno as hostio_last_error handler.
476 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
477 (hostio-errno.o): New rule.
478 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
479 * configure.srv (srv_hostio_err_objs): New variable. Default to
480 hostio-errno.o.
481 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
482 * configure: Regenerate.
483
2d717e4f
DJ
4842008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
485
486 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
487 (linux_kill, linux_detach): Clean up the process list.
488 * remote-utils.c (remote_open): Improve port number parsing.
489 (putpkt_binary, input_interrupt): Only send interrupts if the target
490 is running.
491 * server.c (extended_protocol): Make static.
492 (attached): Define earlier.
493 (exit_requested, response_needed, program_argv): New variables.
494 (target_running): New.
495 (start_inferior): Clear attached here.
496 (attach_inferior): Set attached here.
497 (require_running): Define.
498 (handle_query): Use require_running and target_running. Implement
499 "monitor exit".
500 (handle_v_attach, handle_v_run): New.
501 (handle_v_requests): Use require_running. Handle vAttach and vRun.
502 (gdbserver_usage): Update.
503 (main): Redo argument parsing. Handle --debug and --multi. Handle
504 --attach along with other options or after the port. Save
505 program_argv. Support no initial program. Resynchronize
506 communication with GDB after an error. Handle "monitor exit".
507 Use require_running and target_running. Always allow the extended
508 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
509 restart in extended mode.
510 * README: Refer to the GDB manual. Update --attach usage.
511
7407e2de
AS
5122007-12-20 Andreas Schwab <schwab@suse.de>
513
514 * linux-low.c (STACK_SIZE): Define.
515 (linux_tracefork_child): Use it. Use __clone2 on ia64.
516 (linux_test_for_tracefork): Likewise.
517
b65d95c5
DJ
5182007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
519
520 * linux-low.c (linux_wait_for_event): Update messages. Do not
521 reinsert auto-delete breakpoints.
522 * mem-break.c (struct breakpoint): Change return type of handler to
523 int.
524 (set_breakpoint_at): Update handler type.
525 (reinsert_breakpoint_handler): Return 1 instead of calling
526 delete_breakpoint.
527 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
528 setting a new one.
529 (check_breakpoints): Delete auto-delete breakpoints and return 2.
530 * mem-break.h (set_breakpoint_at): Update handler type.
531 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
532 * win32-low.c (auto_delete_breakpoint): New.
533 (get_child_debug_event): Use it.
534
4e799345
DJ
5352007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
536
537 * configure.ac: Check for pread and pwrite.
538 * hostio.c (handle_pread): Fall back to lseek and read.
539 (handle_pwrite): Fall back to lseek and write.
540 * config.in, configure: Regenerated.
541
27524b67
DJ
5422007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
543
544 * server.c (myresume): Add own_buf argument.
545 (main): Update calls.
546
a20d5e98
DJ
5472007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
548
549 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
550 * remote-utils.c (remote_open): Do not call disable_async_io.
551 (block_async_io): Delete.
552 (unblock_async_io): Make static.
553 (initialize_async_io): New.
554 * server.c (handle_v_cont): Handle async I/O here.
555 (myresume): Likewise. Move other common resume tasks here...
556 (main): ... from here. Call initialize_async_io. Disable async
557 I/O before the main loop.
558 * server.h (initialize_async_io): Declare.
559 (block_async_io, unblock_async_io): Delete prototypes.
560 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
561
b79d787e
DJ
5622007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
563
564 * remote-utils.c (readchar): Allow binary data in received messages.
565
d97903b2
PA
5662007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
567
568 * win32-low.c (attaching): New global.
569 (win32_create_inferior): Clear the `attaching' global.
570 (win32_attach): Set the `attaching' global.
571 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
572 attaching. Only set a breakpoint at the entry point if not
573 attaching.
574
311de423
PA
5752007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
576
577 * server.c (main): Don't report dll events on the initial
578 connection on attaches.
579
6c2d16d2
PA
5802007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
581
582 * server.c (main): Relax numerical bases supported for the pid of
583 the --attach command line argument.
584
5ca906e6
PA
5852007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
586
587 * win32-low.c (win32_attach): Call OpenProcess before
588 DebugActiveProcess, not after. Add last error output to error
589 call.
590
9c6c8194
PA
5912007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
592
593 * win32-low.c (win32_get_thread_context)
594 (win32_set_thread_context): New functions.
595 (thread_rec): Use win32_get_thread_context.
596 (continue_one_thread, win32_resume): Use win32_set_thread_context.
597 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
598 field.
599
4d5d1aaa
PA
6002007-12-03 Leo Zayas
601 Pedro Alves <pedro_alves@portugalmail.pt>
602
603 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
604 global variables.
605 (child_add_thread): Minor cleanup.
606 (child_continue): Resume artificially suspended threads before
607 calling ContinueDebugEvent.
608 (suspend_one_thread): New.
609 (fake_breakpoint_event): New.
610 (get_child_debug_event): Change return type to int. Check here if
611 gdb sent an interrupt request. If a soft interrupt was requested,
612 fake a breakpoint event. Return 0 if there is no event to handle,
613 and 1 otherwise.
614 (win32_wait): Don't check here if gdb sent an interrupt request.
615 Ensure there is a valid event to handle.
616 (win32_request_interrupt): Add soft interruption method as last
617 resort.
618
c436e841
PA
6192007-12-03 Leo Zayas
620 Pedro Alves <pedro_alves@portugalmail.pt>
621
622 * win32-low.h (win32_thread_info): Add descriptions to the
623 structure members. Replace `suspend_count' counter by a
624 `suspended' flag.
625 * win32-low.c (thread_rec): Update condition of when to get the
626 context from the inferior. Rely on ContextFlags being set if it
627 has already been retrieved. Only suspend the inferior thread if
628 we haven't already. Warn if that fails.
629 (continue_one_thread): s/suspend_count/suspended/. Only call
630 ResumeThread once. Warn if that fails.
631
e7b5fa67
PA
6322007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
633
634 * win32-low.c (win32_wait): Don't read from the inferior when it
635 has already exited.
636
a385171d
PA
6372007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
638
639 * Makefile.in (win32_low_h): New variable.
640 (win32-low.o): Add dependency on $(win32_low_h).
641 (win32-arm-low.o, win32-i386-low.o): New rules.
642
f80c84b3
DJ
6432007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
644
645 * hostio.c: Correct copyright year.
646
a6b151f1
DJ
6472007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
648
649 * Makefile.in (OBS): Add hostio.o.
650 (hostio.o): New rule.
651 * server.h (handle_vFile): Declare.
652 * hostio.c: New file.
653 * server.c (handle_v_requests): Take packet_len and new_packet_len
654 for binary packets. Call handle_vFile.
655 (main): Update call to handle_v_requests.
656
f9387fc3
DJ
6572007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
658
659 * linux-low.c: Include <sched.h>.
660
51c2684e
DJ
6612007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
662
663 * linux-low.c (linux_tracefork_grandchild): New.
664 (linux_tracefork_child): Use clone.
665 (linux_test_for_tracefork): Use clone; allocate and free a stack.
666
75f83163
JB
6672007-10-31 Joel Brobecker <brobecker@adacore.com>
668
669 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
670
da5898ce
DJ
6712007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
672
673 * linux-low.c (handle_extended_wait): Handle unexpected signals.
674
24a09b5f
DJ
6752007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
676
677 * inferiors.c (change_inferior_id): Delete.
678 (add_pid_to_list, pull_pid_from_list): New.
679 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
680 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
681 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
682 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
683 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
684 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
685 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
686 (using_threads): Always set to 1.
687 (handle_extended_wait): New.
688 (add_process): Do not set TID.
689 (linux_create_inferior): Set must_set_ptrace_flags.
690 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
691 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
692 (linux_thread_alive): Rename TID argument to LWPID.
693 (linux_wait_for_process): Handle unknown processes. Do not use TID.
694 (linux_wait_for_event): Do not use TID or check using_threads. Update
695 call to dead_thread_notify. Call handle_extended_wait.
696 (linux_create_inferior): Use PTRACE_SETOPTIONS.
697 (send_sigstop): Delete sigstop_sent.
698 (wait_for_sigstop): Avoid TID.
699 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
700 (linux_test_for_tracefork): New.
701 (linux_lookup_signals): Use thread_db_active and
702 linux_supports_tracefork_flag.
703 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
704 * linux-low.h (get_process_thread): Avoid TID.
705 (struct process_ifo): Move thread_known and tid to the end. Remove
706 sigstop_sent.
707 (linux_attach_lwp, thread_db_init): Update prototypes.
708 * server.h (change_inferior_id): Delete prototype.
709 (add_pid_to_list, pull_pid_from_list): New prototypes.
710 * thread-db.c (thread_db_use_events): New.
711 (find_first_thread): Rename to...
712 (find_one_thread): ...this. Update callers and messages. Do not
713 call fatal. Check thread_db_use_events. Do not call
714 change_inferior_id or new_thread_notify.
715 (maybe_attach_thread): Update. Do not call new_thread_notify.
716 (thread_db_init): Set thread_db_use_events. Check use_events.
717 * utils.c (fatal, warning): Correct message prefix.
718
30ed0a8f
DJ
7192007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
720
721 * Makefile.in (clean): Remove new files.
722 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
723 (powerpc-64.o, powerpc-64.c): New rules.
724 * configure.srv: Use alternate register sets for powerpc64-*-linux*
725 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
726 with SPE.
727 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
728 SPE targets.
729 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
730 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
731 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
732 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
733 (target_regsets): Add AltiVec and SPE register sets.
734 * configure.ac: Check for AltiVec and SPE.
735 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
736 (ppc_fill_vrregset, ppc_store_vrregset): New.
737 (target_regsets): Add AltiVec register set.
738 * configure: Regenerated.
739
fd462a61
DJ
7402007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
741
742 * linux-low.c (O_LARGEFILE): Define.
743 (linux_read_memory): Use /proc/PID/mem.
744 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
745 * configure, config.in: Regenerated.
746
69f223ed
DJ
7472007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
748
749 * linux-low.c (linux_wait_for_event): Do not pass signals while
750 single-stepping.
751
aec18585
PA
7522007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
753
754 * win32-low.c (create_process): New.
755 (win32_create_inferior): Use create_process instead of
756 CreateProcess. If create_process failed retry appending an ".exe"
757 suffix. Store the GetLastError result immediatelly after
758 create_process calls and use it on the call to error.
759
34d86ddd
PA
7602007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
761
762 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
763
5a0e3bd0
JB
7642007-08-23 Joel Brobecker <brobecker@adacore.com>
765
766 * configure.ac: Switch license to GPLv3.
767
f88c79e6
MS
7682007-08-01 Michael Snyder <msnyder@access-company.com>
769
770 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
771
6b3d9b83
PA
7722007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
773
774 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
775 typedef.
776 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
777 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
778 CloseToolhelp32Snapshot.
779 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
780 CloseToolhelp32Snapshot.
781
c588c53c
MS
7822007-07-27 Michael Snyder <michael.snyder@access-company.com>
783
784 * server.c (main): Check for inferior exit before main loop.
785
aa0403d9
PA
7862007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
787
788 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
789 instead of on tmp_desc.
790
255e7678
DJ
7912007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
792 Daniel Jacobowitz <dan@codesourcery.com>
793
794 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
795 (add_thread): Minor cleanups.
796 (clear_inferiors): Move lower in the file. Clear the DLL
797 list.
798 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
799 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
800 (xml_escape_text): New.
801 * server.c (handle_query): Handle qXfer:libraries:read. Report it
802 for qSupported.
803 (handle_v_cont): Report errors.
804 (gdbserver_version): Update.
805 (main): Correct size of own_buf. Do not report initial DLL events.
806 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
807 (unloaded_dll, xml_escape_text): New.
808 * win32-low.c (enum target_waitkind): Update comments.
809 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
810 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
811 (win32_EnumProcessModules, win32_GetModuleInformation)
812 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
813 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
814 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
815 (win32_Module32First, win32_Module32Next, load_toolhelp)
816 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
817 (get_child_debug_event): Handle DLL events.
818 (win32_wait): Likewise.
819
0d37add9
DJ
8202007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
821
822 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
823 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
824
45e2715e
PA
8252007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
826
827 * win32-low.c (handle_output_debug_string): Ignore event if not
828 waiting.
829
c5674cf1
PA
8302007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
831
832 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
833
2bbe3cc1
DJ
8342007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
835
836 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
837
ae13219e
DJ
8382007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
839
840 * inferiors.c (change_inferior_id): Add comment.
841 * linux-low.c (check_removed_breakpoint): Add an early
842 prototype. Improve debug output.
843 (linux_attach): Doc update.
844 (linux_detach_one_process, linux_detach): Clean up before releasing
845 each process.
846 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
847 * linux-low.h (struct process_info): Doc improvement.
848 * mem-break.c (delete_all_breakpoints): New.
849 * mem-break.h (delete_all_breakpoints): New prototype.
850 * thread-db.c (find_first_thread): New.
851 (thread_db_create_event): Call it instead of
852 thread_db_find_new_threads. Clean up unused variables.
853 (maybe_attach_thread): Remove first thread handling.
854 (thread_db_find_new_threads): Use find_first_thread.
855 (thread_db_get_tls_address): Likewise.
856
4105de34
DJ
8572007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
858
859 * thread-db.c (thread_db_find_new_threads): Add prototype.
860 (thread_db_create_event): Check for the main thread before adding
861 a new thread.
862 (maybe_attach_thread): Only enable event reporting if TID == 0.
863 (thread_db_get_tls_address): Check for new threads.
864
2b876972
DJ
8652007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
866
867 * linux-low.c (linux_create_inferior): Try execv before execvp.
868 * spu-low.c (spu_create_inferior): Likewise.
869
7a245884
DJ
8702007-06-13 Mike Frysinger <vapier@gentoo.org>
871
872 * linux-low.c (linux_create_inferior): Change execv to execvp.
873 * spu-low.c (spu_create_inferior): Likewies.
874
117ce543
DJ
8752007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
876
877 * Makefile.in (clean): Clean new files instead of deleted ones.
878 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
879 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
880 rules.
881 * configure.srv: Specify XML files and new regformats for MIPS and
882 MIPS64 GNU/Linux.
883 * linux-mips-low.c (mips_num_regs): Set to only used registers.
884 (mips_regmap): Do not fetch $0. Remove unused registers. Add
885 an entry for the restart register.
886 (mips_cannot_fetch_register, mips_cannot_store_register)
887 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
888 register names to match the XML descriptions.
889 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
890 restart register instead of $0.
891
0e7f50da
UW
8922007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
893 Markus Deuling <deuling@de.ibm.com>
894
895 * remote-utils.c (decode_xfer_write): New function.
896 * server.h (decode_xfer_write): Add prototype.
897 * server.c (handle_query): Add PACKET_LEN argument. Support
898 qXfer:spu:read and qXfer:spu:write packets.
899 (main): Pass packet_len to handle_query.
900 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
901 * target.h (target_ops): Add qxfer_spu.
902
374c1d38
UW
9032007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
904
905 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
906 accessing non-seekable spufs files.
907
bb63802a
UW
9082007-05-16 Markus Deuling <deuling@de.ibm.com>
909
910 * server.c (handle_query): Add reply for qC packet.
911
7390519e
PA
9122007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
913 Leo Zayas <lerele@champenstudios@com>
914
915 * server.h (check_remote_input_interrupt_request): New function.
916 * remote_utils.c (INVALID_DESCRIPTOR): New define.
917 (remote_desc): Initialize with INVALID_DESCRIPTOR.
918 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
919 (check_remote_input_interrupt_request): New function.
920 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 921 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
922 winapi_GenerateConsoleCtrlEvent): New typedefs.
923 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
924 to 250 ms.
925 (win32_wait): Check for remote interrupt request
926 with check_remote_input_interrupt_request.
927 (win32_request_interrupt): New function.
928 (win32_target_op): Set request_interrupt to win32_request_interrupt.
929
34b34921
PA
9302007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
931
932 * win32-low.c (debug_registers_changed,
933 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
934 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
935 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
936 (thread_rec): Get context using the low target.
937 (child_add_thread): Call thread_added on the low target,
938 which does the same thing.
939 (regptr): Delete.
940 (do_initial_child_stuff): Remove debug registers references.
941 Set context using the low target. Resume threads after
942 setting the contexts.
943 (child_continue): Remove dead variable. Remove debug
944 registers references.
945 (child_fetch_inferior_registers): Go through the low target.
946 (do_child_store_inferior_registers): Remove.
947 (child_store_inferior_registers): Go through the low target.
948 (win32_resume): Remove debug registers references.
949 Set context using the low target.
950 (handle_exception): Change return type to void. Don't record
951 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
952 first chance exception.
953 (get_child_debug_event): Change return type to void. Remove
954 goto loop. Always return after waiting for debug event.
955 (win32_wait): Convert to switch statement. Handle spurious
956 events.
957
958 * win32-i386-low.c (debug_registers_changed,
959 debug_registers_used): New.
960 (initial_stuff): Rename to ...
961 (i386_initial_stuff): ... this. Clear debug registers
962 state variables.
963 (store_debug_registers): Delete.
964 (i386_get_thread_context): New.
965 (load_debug_registers): Delete.
966 (i386_set_thread_context): New.
967 (i386_thread_added): New.
968 (single_step): Rename to ...
969 (i386_single_step): ... this.
970 (do_fetch_inferior_registers): Rename to ...
971 (i386_fetch_inferior_register): ... this.
972 (i386_store_inferior_register): New.
973 (the_low_target): Adapt to new interface.
974
975 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
976 (arm_get_thread_context): New.
977 (arm_set_thread_context): New.
978 (regptr): New.
979 (do_fetch_inferior_registers): Rename to ...
980 (arm_fetch_inferior_register): ... this.
981 (arm_store_inferior_register): New.
982 (arm_wince_breakpoint): Reimplement as unsigned long.
983 (arm_wince_breakpoint_len): Define.
984 (the_low_target): Adapt to new interface.
985
986 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
987 load_debug_registers. Add get_thread_context, set_thread_context,
988 thread_added and store_inferior_register. Rename
989 fetch_inferior_registers to fetch_inferior_register.
990 (regptr): Remove declaration.
991
dd6953e1
PA
9922007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
993
994 * linux-low.c (linux_detach): Change return type to int. Return 0.
995 * spu-low.c (spu_detach): Likewise.
996
444d6139
PA
9972007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
998
999 * target.h (target_ops): Change return type of detach to int.
1000 Add join.
1001 (join_inferior): New.
1002 * server.c (main): Don't skip detach support on mingw32.
1003 If the inferior doesn't support detaching return error.
1004 Call join_inferior instead of using waitpid.
1005 * linux-low.c (linux_join): New.
1006 (linux_target_op): Add linux_join.
1007 * spu-low.c (spu_join): New.
1008 (spu_target_ops): Add spu_join.
1009 * win32-low.c (win32_detach): Adapt to new interface.
1010 Reopen current_process_handle before detaching. Issue a child
1011 resume before detaching.
1012 (win32_join): New.
1013 (win32_target_op): Add win32_join.
1014
1d5315fe
PA
10152007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
1016
1017 * win32-low.c (win32-attach): Fix return value.
1018 * target.h (target_ops): Describe ATTACH return values.
1019
bf914831
PA
10202007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
1021
1022 * win32-low.c (GETPROCADDRESS): Define.
1023 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
1024 (winapi_DebugSetProcessKillOnExit): Likewise.
1025 (win32_create_inferior): Force usage of ansi CreateProcessA.
1026 (win32_attach): Use GETPROCADDRESS.
1027 (win32_detach): Likewise.
1028
f72f3e60
PA
10292007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
1030
1031 * win32-low.c (win32_wait): Don't use WSTOPSIG.
1032
ed50f18f
PA
10332007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
1034
1035 * win32-low.c: Commit leftover changes from 2007-03-29.
1036
0c2ead7e
DJ
10372007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
1038
1039 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
1040 fields short instead of int. Add explicit padding.
1041 (i387_cache_to_fsave): Remove unnecessary casts.
1042 (i387_fsave_to_cache): Doc fix.
1043 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
1044
73725ff3
DJ
10452007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
1046
1047 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
1048 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
1049
d99f33d8
PA
10502007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
1051
1052 * configure.srv (arm*-*-mingw32ce*): Move near the other
1053 arm targets.
1054
68070c10
PA
10552007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
1056
2482afc6 1057 * configure.ac: Add errno checking.
68070c10
PA
1058 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
1059 sys/file.h and malloc.h.
1060 (AC_CHECK_DECLS): Add perror.
1061 (srv_mingwce): Handle.
2482afc6 1062 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
1063 win32-i386-low.o to srv_tgtobj.
1064 (i[34567]86-*-mingw*): Likewise.
1065 (arm*-*-mingw32ce*): Add case.
1066 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
1067 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
1068 [__MINGW32CE__] (strerror): New function.
1069 [__MINGW32CE__] (errno): Define to GetLastError.
1070 [__MINGW32CE__] (COUNTOF): New macro.
1071 (remote_open): Remove extra close call.
1072 * mem-break.c (delete_breakpoint_at): New function.
1073 * mem-break.h (delete_breakpoint_at): Declare.
1074 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
1075 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
1076 [USE_WIN32API] (read, write): Add char* casts.
1077 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
1078 * server.h: Include wincecompat.h on Windows CE.
1079 [HAVE_ERRNO_H]: Check.
1080 (perror): Declare if not declared.
1081 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
1082 (perror_with_name): Remove errno declaration.
1083 * wincecompat.h: New.
1084 * wincecompat.c: New.
1085 * win32-low.h: New.
1086 * win32-arm-low.c: New.
1087 * win32-i386-low.c: New.
1088 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
1089 (OUTMSG2): Make it safe.
1090 (_T): New macro.
1091 (COUNTOF): New macro.
1092 (NUM_REGS): Get it from the low target.
1093 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
1094 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
1095 (thread_rec): Let low target handle debug registers.
1096 (child_add_thread): Likewise.
1097 (child_init_thread_list): Likewise.
1098 (continue_one_thread): Likewise.
1099 (regptr): New.
1100 (do_child_fetch_inferior_registers): Move to ...
1101 * win32-i386-low.c: ... here, and rename to ...
1102 (do_fetch_inferior_registers): ... this.
1103 * win32-low.c (child_fetch_inferior_registers):
1104 Go through the low target.
1105 (do_child_store_inferior_registers): Use regptr.
1106 (strwinerror): New function.
1107 (win32_create_inferior): Handle Windows CE.
1108 Use strwinerror instead of strerror on Windows error
1109 codes. Add program to the error output.
1110 Don't close the main thread handle on Windows CE.
1111 (win32_attach): Use coredll.dll on Windows CE.
1112 (win32_kill): Close current process and current
1113 thread handles.
1114 (win32_detach): Use coredll.dll on Windows CE.
1115 (win32_resume): Let low target handle debug registers, and
1116 step request.
1117 (handle_exception): Add/Remove initial breakpoint. Avoid
1118 non-existant WSTOPSIG on Windows CE.
1119 (win32_read_inferior_memory): Cast to remove warning.
1120 (win32_arch_string): Go through the low target.
1121 (initialize_low): Call set_breakpoint_data with the low
1122 target's breakpoint.
1123 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
1124 FOP_REGNUM, mappings): Move to ...
1125 * win32-i386-low.c: ... here.
1126 * win32-low.c (win32_thread_info): Move to ...
1127 * win32-low.h: ... here.
1128 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
1129 win32-arm-low.c and wincecompat.c.
1130 (all:): Add $EXEEXT.
1131 (install-only:): Likewise.
1132 (gdbserver:): Likewise.
1133 (gdbreplay:): Likewise.
1134 * config.in: Regenerate.
1135 * configure: Regenerate.
1136
41093d81
PA
11372007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
1138
1139 * win32-low.c: Rename typedef thread_info to
1140 win32_thread_info throughout.
1141
544afa54
PA
11422007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
1143
1144 * win32-i386-low.c: Rename to ...
1145 * win32-low.c: ... this.
1146 * configure.srv: Replace win32-i386-low.o with win32-low.o.
1147 * Makefile.in: Likewise.
1148
bce7165d
PA
11492007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
1150
1151 * remote-utils.c (monitor_output): Constify msg parameter.
1152 * server.h (monitor_output): Likewise.
1153 * win32-i386-low.c (handle_output_debug_string): New.
1154 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
1155 handle_output_debug_string.
1156 (get_child_debug_event): Likewise.
1157
506c7aa0
DJ
11582007-03-27 Mat Hostetter <mat@lcs.mit.edu>
1159
1160 * server.c (main): Correct strtoul check.
1161
42c81e2a
DJ
11622007-03-27 Jon Ringle <jon@ringle.org>
1163
1164 * linux-low.c: Check __ARCH_HAS_MMU__ also.
1165
9453113a
DJ
11662007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
1167
1168 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
1169
64a69107
DJ
11702007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
1171
1172 * terminal.h: Check HAVE_SGTTY_H.
1173
11742007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
1175
1176 * remote-utils.c (remote_open): Print out the assigned port number.
1177
c74d0ad8
DJ
11782007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
1179
1180 * remote-utils.c (monitor_output): New function.
1181 * server.c (debug_threads): Define here.
1182 (monitor_show_help): New function.
1183 (handle_query): Handle qRcmd.
1184 (main): Do not handle 'd' packet.
1185 * server.h (debug_threads, remote_debug, monitor_output): Declare.
1186 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
1187 of debug_threads.
1188
de7c3b4a
PA
11892007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
1190
1191 * Makefile.in (EXEEXT): New.
1192 (clean): Use $(EXEEXT).
1193
ef57601b
PA
11942007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
1195
1196 * target.h (target_ops): Rename send_signal to request_interrupt,
1197 and remove enum target_signal parameter.
1198 * linux-low.c (linux_request_interrupt): Rename from
1199 linux_send_signal, and always send SIGINT.
1200 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
1201 and always send SIGINT.
1202 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
1203 of send_signal.
1204 (input_interrupt): Likewise.
1205
820f2bda
PA
12062007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
1207
1208 * server.c (get_features_xml): Check if target implemented
1209 arch_string.
1210 * win32-i386-low.c (win32_arch_string): New.
1211 (win32_target_ops): Add win32_arch_string as arch_string member.
1212
ab39bf24
UW
12132007-02-22 Markus Deuling <deuling@de.ibm.com>
1214
1215 * spu-low.c (spu_arch_string): New.
1216 (spu_target_ops): Add spu_arch_string.
1217
61ff6e04
DJ
12182007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
1219
1220 * remote-utils.c: Remove HAVE_TERMINAL_H check.
1221 * configure.ac: Do not check for terminal.h.
1222 * configure, config.in: Regenerated.
1223
fb1e4ffc
DJ
12242007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
1225
1226 * Makefile.in (OBS): Add $(XML_BUILTIN).
1227 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
1228 (clean): Update.
1229 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
1230 (arm-with-iwmmxt.c): New.
1231 * config.in, configure: Regenerate.
1232 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
1233 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
1234 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
1235 (arm*-*-linux*): Add iWMMXt and regset support.
1236 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
1237 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
1238 (arm_store_wmmxregset, target_regsets): New.
1239 * server.c (get_features_xml): Take annex argument. Check builtin
1240 XML documents.
1241 (handle_query): Handle multiple annexes.
1242
0f48aa01
DJ
12432007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
1244
1245 * remote-utils.c [USE_WIN32API] (read, write): Define.
1246 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
1247 write.
1248
23181151
DJ
12492007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
1250
1251 * linux-i386-low.c (the_low_target): Set arch_string.
1252 * linux-x86-64-low.c (the_low_target): Likewise.
1253 * linux-low.c (linux_arch_string): New.
1254 (linux_target_ops): Add it.
1255 * linux-low.h (struct linux_target_ops): Add arch_string.
1256 * server.c (write_qxfer_response): Use const void * for DATA.
1257 (get_features_xml): New.
1258 (handle_query): Handle qXfer:features:read. Report it for qSupported.
1259 * target.h (struct target_ops): Add arch_string method.
1260
9d606399
DJ
12612007-01-03 Denis Pilat <denis.pilat@st.com>
1262 Daniel Jacobowitz <dan@codesourcery.com>
1263
1264 * linux-low.c (linux_kill): Handle being called with no threads.
1265 * win32-i386-low.c (win32_kill): Likewise.
1266 (get_child_debug_event): Clear current_process_handle.
1267
12682006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
1269 Daniel Jacobowitz <dan@codesourcery.com>
1270
1271 * remote-utils.c (remote_open): Check the type of specified
1272 serial port devices before opening them.
1273 * server.c (main): Kill the inferior if an error occurs during
1274 the first remote_open.
1275
a5e13d24
DJ
12762006-12-05 Markus Deuling <deuling@de.ibm.com>
1277
1278 * README: Update supported targets.
1279
186947f7
DJ
12802006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
1281
1282 * Makefile.in (clean): Remove reg-mips64.c.
1283 (reg-mips64.c, reg-mips64.o): New rules.
1284 * configure.srv: Handle mips64. Include regset support for mips.
1285 * linux-mips-low.c (union mips_register): New.
1286 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
1287 (mips_breakpoint, mips_breakpoint_at): Use int.
1288 (mips_collect_register, mips_supply_register)
1289 (mips_collect_register_32bit, mips_supply_register_32bit)
1290 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
1291 (mips_store_fpregset, target_regsets): New.
1292 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
1293
a13e2c95
UW
12942006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1295
1296 * configure.srv: Add target "spu*-*-*".
1297 * Makefile.in (clean): Remove reg-spu.c.
1298 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
1299 * spu-low.c: New file.
1300
cb7283db
DJ
13012006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
1302
1303 * configure.ac: Correct td_thr_tls_get_addr test.
1304 * configure: Regenerated.
1305
89be2091
DJ
13062006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
1307
1308 * linux-low.c (linux_wait_for_event): Reformat. Use the
1309 pass_signals array.
1310 * remote-utils.c (decode_address_to_semicolon): New.
1311 * server.c (pass_signals, handle_general_set): New.
1312 (handle_query): Mention QPassSignals for qSupported.
1313 (main): Call handle_general_set.
1314 * server.h (pass_signals, decode_address_to_semicolon): New.
1315
000ef4f0
DJ
13162006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
1317
1318 * server.c (handle_query): Correct error handling for read_auxv.
1319
b7149293
UW
13202005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
1321
1322 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
1323 and srv_linux_thread_db to yes.
1324 * linux-s390-low.c (s390_fill_gregset): New function.
1325 (target_regsets): Define data structure.
1326
dae5f5cf
DJ
13272006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
1328
1329 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
1330 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
1331 * config.in, configure: Regenerated.
1332 * inferiors.c (gdb_id_to_thread): New function.
1333 (gdb_id_to_thread_id): Use it.
1334 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
1335 * linux-low.h (struct process_info): Add th member.
1336 (thread_db_get_tls_address): New prototype.
1337 * remote-utils.c (decode_address): Make non-static.
1338 * server.c (handle_query): Handle qGetTLSAddr.
1339 * server.h (gdb_id_to_thread, decode_address): New prototypes.
1340 * target.h (struct target_ops): Add get_tls_address.
1341 * thread-db.c (maybe_attach_thread): Save the thread handle.
1342 (thread_db_get_tls_address): New.
1343
32ca6d61
DJ
13442006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
1345
1346 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
1347 (linux_resume_one_process): Take a siginfo_t *. Update all
1348 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
1349 (struct pending_signals): Add a siginfo_t.
1350 (linux_wait_for_process): Always set last_status.
1351 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
1352 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
1353 * linux-low.h (struct process_info): Add last_status.
1354
5ffff7c1
DJ
13552006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
1356
1357 * remote-utils.c (try_rle): New function.
1358 (putpkt_binary): Use it.
1359
8695c747
DJ
13602006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
1361
1362 * Makefile.in (clean): Clean reg-x86-64-linux.c.
1363 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
1364 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
1365 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
1366 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
1367 point registers.
1368
290fadea
RS
13692006-08-08 Richard Sandiford <richard@codesourcery.com>
1370
1371 * server.c (terminal_fd): New variable.
1372 (old_foreground_pgrp): Likewise.
1373 (restore_old_foreground_pgrp): New function.
1374 (start_inferior): Record the terminal file descriptor in terminal_fd
1375 and its original foreground group in old_foreground_pgrp. Register
1376 restore_old_foreground_pgrp with atexit().
1377
9f2e1e63
DJ
13782006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
1379
1380 * server.c (handle_query): Correct qPart to qXfer.
1381
b80864fb
DJ
13822006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
1383
1384 * configure.ac: Check for more headers which are missing on
1385 Windows. Automatically supply -lwsock32 and USE_WIN32API.
1386 * configure.srv: Add Cygwin and mingw32.
1387 * remote-utils.c: Don't include headers unconditionally which
1388 are missing on mingw32. Include <winsock.h> for mingw32.
1389 (remote_open): Adjust for mingw32 support. Flush
1390 standard error after writing to it.
1391 (remote_close, putpkt_binary, input_interrupt, block_async_io)
1392 (unblock_async_io, enable_async_io, disable_async_io)
1393 (readchar, getpkt): Update for Winsock support.
1394 (prepare_resume_reply): Expect a protocol signal number.
1395 * server.c: Disable <sys/wait.h> on mingw32.
1396 (start_inferior): Adjust for mingw32 support. Flush
1397 standard error after writing to it.
1398 (attach_inferior): Likewise. Use protocol signal
1399 numbers.
1400 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
1401 and names.
1402 * win32-i386-low.c: New file.
1403 * Makefile.in (XM_CLIBS): Set.
1404 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
1405 (win32-i386-low.o): New dependency rule.
1406 * linux-low.c (linux_wait): Use target signal numbers.
1407 * target.h (struct target_ops): Doc fix.
1408 * server.h (target_signal_to_name): New prototype.
1409 * gdbreplay.c: Don't include headers unconditionally which
1410 are missing on mingw32. Include <winsock.h> for mingw32.
1411 (remote_close, remote_open): Adjust for Winsock support.
1412 * configure, config.in: Regenerated.
1413
0876f84a
DJ
14142006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
1415
1416 * server.c (decode_xfer_read, write_qxfer_response): New.
1417 (handle_query): Take a packet length argument. Handle
1418 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
1419 the qSupported response.
1420 (main): Update call to handle_query.
1421
01f9e8fa
DJ
14222006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
1423
1424 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
1425 (putpkt_binary): Renamed from putpkt and adjusted for binary
1426 data.
1427 (putpkt): New wrapper for putpkt_binary.
1428 (readchar): Don't mask off the high bit.
1429 (decode_X_packet): New function.
1430 * server.c (main): Call putpkt_binary if a handler sets the packet
1431 length. Save the length of the incoming packet. Handle 'X'.
1432 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
1433
be2a5f71
DJ
14342006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
1435
1436 * server.c (handle_query): Handle qSupported.
1437
ea025f5f
DJ
14382006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
1439
1440 * remote-utils.c (all_symbols_looked_up): New variable.
1441 (look_up_one_symbol): Check it.
1442 * server.h (look_up_one_symbol): New declaration.
1443 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
1444
9308fc88
DJ
14452006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
1446
1447 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 1448 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
1449 (PTRACE_GET_THREAD_AREA): Define.
1450 (ps_get_thread_area): New function.
1451
52fb6437
NS
14522006-05-09 Nathan Sidwell <nathan@codesourcery.com>
1453
1454 * configure.srv (m68k*-*-uclinux*): New target.
1455 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
1456 (linux_resume_one_process): Remove extraneous cast.
1457 (linux_read_offsets): New.
1458 (linux_target_op): Add linux_read_offsets on mmuless systems.
1459 * server.c (handle_query): Add qOffsets logic.
1460 * target.h (struct target_ops): Add read_offsets.
1461
21b0f40c
DJ
14622006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
1463
1464 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
1465 (PTRACE_GET_THREAD_AREA): Define.
1466 (ps_get_thread_area): New function.
1467 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
1468 (linux-x86-64-low.o): Update.
1469
0050a760
DJ
14702006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
1471
1472 * configure.ac: Remove checks for prfpregset_t.
1473 * gdb_proc_service.h: New file.
1474 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
1475 new "gdb_proc_service.h".
1476 * proc-service.c: Likewise.
1477 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
1478 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
1479 * Makefile.in (gdb_proc_service_h): Updated.
1480 * configure, config.in: Regenerated.
1481
b92a518e
DJ
14822006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
1483
1484 * remote-utils.c (prepare_resume_reply): Move declaration
1485 of gdb_id_from_wait to the top of the block.
1486
545587ee
DJ
14872006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
1488
1489 * linux-low.c (regsets_store_inferior_registers): Read the regset
1490 from the target before filling it.
1491
9db87ebd
DJ
14922006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
1493
1494 * server.c (attach_inferior): Return SIGTRAP for a successful
1495 attach.
1496
dd24457d
DJ
14972006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
1498
1499 * Makefile.in (OBS): Add version.o.
1500 (STAGESTUFF): Delete.
1501 (version.o): Add dependencies.
1502 (version.c): Replace rule.
1503 (clean): Remove version.c.
1504 * server.c (gdbserver_version): New.
1505 (gdbserver_usage): Use printf.
1506 (main): Handle --version and --help.
1507 * server.h (version, host_name): Add declarations.
1508
6f0f660e
EZ
15092005-12-23 Eli Zaretskii <eliz@gnu.org>
1510
1511 * linux-arm-low.c:
1512 * linux-arm-low.c:
1513 * inferiors.c:
1514 * i387-fp.h:
1515 * i387-fp.c:
1516 * gdbreplay.c:
1517 * regcache.c:
1518 * proc-service.c:
1519 * mem-break.h:
1520 * mem-break.c:
1521 * linux-x86-64-low.c:
1522 * linux-sh-low.c:
1523 * linux-s390-low.c:
1524 * linux-ppc64-low.c:
1525 * linux-ppc-low.c:
1526 * linux-mips-low.c:
1527 * linux-m68k-low.c:
1528 * linux-m32r-low.c:
1529 * linux-low.h:
1530 * linux-low.c:
1531 * linux-ia64-low.c:
1532 * linux-i386-low.c:
1533 * linux-crisv32-low.c:
1534 * thread-db.c:
1535 * terminal.h:
1536 * target.h:
1537 * target.c:
1538 * server.h:
1539 * server.c:
1540 * remote-utils.c:
1541 * regcache.h:
1542 * utils.c:
1543 * Makefile.in:
1544 * configure.ac:
1545 * gdbserver.1: Add (C) after Copyright. Update the FSF
1546 address.
1547
9d1fb177
DJ
15482005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
1549
1550 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
1551 (arm_breakpoint_at): Recognize both breakpoints.
1552 (the_low_target): Use the correct breakpoint instruction.
1553
011a70c2
DJ
15542005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
1555
1556 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
1557 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
1558 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
1559 (the_low_target): Update.
1560
7fb85e41
AS
15612005-10-25 Andreas Schwab <schwab@suse.de>
1562
1563 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
1564
1565 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
1566 (ia64_num_regs): Reduce to 462.
1567
3db0444b
DJ
15682005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
1569
1570 * acinclude.m4: Correct quoting.
1571 * aclocal.m4: Regenerated.
1572
1573 Suggested by SZOKOVACS Robert <szo@ies.hu>:
1574 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
1575 (thread_db_init): Call thread_db_err_str.
1576 * configure.ac: Check for TD_VERSION.
1577 * config.in, configure: Regenerated.
1578
bee0189a
DJ
15792005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1580
1581 * server.h (error, fatal, warning): Add ATTR_FORMAT.
1582
e9d25b98
DJ
15832005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1584
1585 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
1586 is not available. Define HAVE_PTRACE_GETREGS if it is.
1587 * config.in, configure: Regenerated.
1588 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
1589 * linux-i386-low.c, linux-m68k-low.c: Update to use
1590 HAVE_PTRACE_GETREGS.
1591 * linux-low.c (regsets_fetch_inferior_registers)
1592 (regsets_store_inferior_registers): Only return 0 if we processed
1593 GENERAL_REGS.
1594 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
1595 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
1596
a06660f7
DJ
15972005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1598
1599 * inferiors.c (struct thread_info): Add gdb_id.
1600 (add_thread): Add gdb_id argument.
1601 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
1602 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
1603 calls to add_thread.
1604 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
1605 * server.c (handle_query): Use thread_to_gdb_id.
1606 (handle_v_cont, main): Use gdb_id_to_thread_id.
1607 * server.h (add_thread): Update prototype.
1608 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
1609 prototypes.
1610
5a1f5858
DJ
16112005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
1612
1613 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
1614 left-padded registers.
1615 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
1616 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
1617
e122f1f5
SE
16182005-07-01 Steve Ellcey <sje@cup.hp.com>
1619
1620 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
1621 * configure: Regenerate.
1622 * config.in: Regenerate.
1623 * server.h (NEED_DECLARATION_STRERROR):
1624 Replace with !HAVE_DECL_STRERROR.
1625
d592fa2f
DJ
16262005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
1627
1628 * linux-low.c (linux_wait, linux_send_signal): Don't test
1629 an unsigned long variable for > 0 if it could be MAX_ULONG.
1630 * server.c (myresume): Likewise.
1631 * target.c (set_desired_inferior): Likewise.
1632
ccbd4912
MK
16332005-06-13 Mark Kettenis <kettenis@gnu.org>
1634
1635 * configure.ac: Simplify and improve check for socklen_t.
1636 * configure, config.in: Regenerate.
1637
f450004a
DJ
16382005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
1639
1640 * acconfig.h: Remove.
1641 * configure.ac: Add a test for socklen_t. Use three-argument
1642 AC_DEFINE throughout.
1643 * config.in: Regenerated using autoheader 2.59.
1644 * configure: Regenerated.
1645
1646 * gdbreplay.c (socklen_t): Provide a default.
1647 (remote_open): Use socklen_t.
1648 * remote-utils.c (socklen_t): Provide a default.
1649 (remote_open): Use socklen_t.
1650 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
1651 unsigned char.
1652
1653 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
1654 char for buffers.
1655 * linux-low.c (linux_read_memory, linux_write_memory)
1656 (linux_read_auxv): Likewise.
1657 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
1658 (check_mem_write): Likewise.
1659 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
1660 Likewise.
1661 * regcache.c (struct inferior_rgcache_data, registers_to_string)
1662 (registers_from_string, register_data): Likewise.
1663 * server.c (handle_query, main): Likewise.
1664 * server.h (convert_ascii_to_int, convert_int_to_ascii)
1665 (decode_M_packet): Likewise.
1666 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
1667 * target.h (struct target_ops): Update read_memory, write_memory,
1668 and read_auxv.
1669 (read_inferior_memory, write_inferior_memory): Update.
1670 * linux-low.h (struct linux_target_ops): Change type of breakpoint
1671 to unsigned char *.
1672 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
1673 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
1674 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
1675 linux-s390-low.c, linux-sh-low.c: Update for changes in
1676 read_inferior_memory and the_low_target->breakpoint.
1677
eee84df1
DJ
16782005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
1679
1680 * Makefile.in (SFILES): Add linux-ppc64-low.c.
1681 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
1682 * configure.srv: Add powerpc64-*-linux*.
1683 * linux-ppc64-low.c: New file.
1684
45b134e5
OF
16852005-05-23 Orjan Friberg <orjanf@axis.com>
1686
1687 * linux-cris-low.c: New file with support for CRIS.
1688 * linux-crisv32-low.c: Ditto for CRISv32.
1689 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
1690 (clean): Add reg-cris.c and reg-crisv32.c.
1691 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
1692 reg-crisv32.o, and reg-crisv32.c to make rules.
1693 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
1694 recognized targets.
1695
48d93c75
UW
16962005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
1697
1698 * linux-low.c (fetch_register): Ensure buffer size is a multiple
1699 of sizeof (PTRACE_XFER_TYPE).
1700 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
1701
e013ee27
OF
17022005-05-12 Orjan Friberg <orjanf@axis.com>
1703
1704 * target.h (struct target_ops): Add insert_watchpoint,
1705 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
1706 pointers for hardware watchpoint support.
1707 * linux-low.h (struct linux_target_ops): Ditto.
1708 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
1709 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
1710 to linux_target_ops.
1711 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
1712 reply packet.
1713 * server.c (main): Recognize 'Z' and 'z' packets.
1714
b0ded00b
UW
17152005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
1716
1717 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
1718 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
1719 (the_low_target): Add new members.
1720
8643e2ad
DJ
17212005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
1722
1723 * proc-service.c (ps_lgetregs): Search all_processes instead of
1724 all_threads.
1725
fc620387
DJ
17262005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
1727
1728 * server.c (start_inferior): Change return type to int.
1729 (attach_inferior): Change sigptr to int *.
1730 (handle_v_cont, handle_v_requests): Change signal to int *.
1731 (main): Change signal to int.
1732
17332005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
1734
1735 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
1736 * configure.srv: Add m32r*-*-linux*.
1737 * linux-m32r-low.c: New file.
1738
e0e76420
DJ
17392005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
1740
1741 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
1742
a1928bad
DJ
17432005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
1744
1745 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
1746 Take unsigned long arguments for PIDs.
1747 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
1748 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
1749 (wait_for_sigstop, linux_resume_one_process)
1750 (regsets_fetch_inferior_registers, linux_send_signal)
1751 (linux_read_auxv): Likewise. Update the types of variables holding
1752 PIDs. Update format string specifiers.
1753 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
1754 * remote-utils.c (prepare_resume_reply): Likewise.
1755 * server.c (cont_thread, general_thread, step_thread)
1756 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
1757 unsigned long.
1758 (handle_query): Update format specifiers.
1759 (handle_v_cont, main): Use strtoul for thread IDs.
1760 * server.h (struct inferior_list_entry): Use unsigned long for ID.
1761 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
1762 (general_thread, step_thread, thread_from_wait)
1763 (old_thread_from_wait): Update.
1764 * target.h (struct thread_resume): Use unsigned long for THREAD.
1765 (struct target_ops): Use unsigned long for arguments to attach and
1766 thread_alive.
1767
dcdb98d2
DJ
17682005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
1769
1770 * acinclude.m4: Include bfd/bfd.m4 directly.
1771 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
1772 <agriffis@toolchain.org>.
1773 * aclocal.m4, configure: Regenerated.
1774
bec39cab
AC
17752005-01-07 Andrew Cagney <cagney@gnu.org>
1776
1777 * configure.ac: Rename configure.in, require autoconf 2.59.
1778 * configure: Re-generate.
1779
434c4c77
DJ
17802004-12-08 Daniel Jacobowitz <dan@debian.org>
1781
1782 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
1783 LIBS when finished.
1784 * aclocal.m4: Regenerated.
1785 * configure: Regenerated.
1786
db1d3e1b
AS
17872004-11-21 Andreas Schwab <schwab@suse.de>
1788
1789 * linux-m68k-low.c (m68k_num_gregs): Define.
1790 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
1791 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
1792 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
1793 (m68k_breakpoint_at): New. Add to the_low_target.
1794
1795 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
1796 srv_linux_thread_db to yes.
1797
43360365
JB
17982004-10-20 Joel Brobecker <brobecker@gnat.com>
1799
1800 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
1801 (ARCH_SET_FS): Likewise.
1802 (ARCH_GET_FS): Likewise.
1803 (ARCH_GET_GS): Likewise.
1804
fd500816
DJ
18052004-10-16 Daniel Jacobowitz <dan@debian.org>
1806
1807 * linux-i386-low.c (ps_get_thread_area): New.
1808 * linux-x86-64-low.c (ps_get_thread_area): New.
1809 * linux-low.c: Include <sys/syscall.h>.
1810 (linux_kill_one_process): Don't kill the first thread here.
1811 (linux_kill): Kill the first thread here.
1812 (kill_lwp): New function.
1813 (send_sigstop, linux_send_signal): Use it.
1814 * proc-service.c: Clean up #ifdefs.
1815 (fpregset_info): Delete.
1816 (ps_lgetregs): Update and enable implementation.
1817 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
1818 implementations.
1819 * remote-utils.c (struct sym_cache, symbol_cache): New.
1820 (input_interrupt): Print a clearer message.
1821 (async_io_enabled): New variable.
1822 (enable_async_io, disable_async_io): Use it. Update comments.
1823 (look_up_one_symbol): Use the symbol cache.
1824 * thread-db.c (thread_db_look_up_symbols): New function.
1825 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
1826
f6de3c42
DJ
18272004-10-16 Daniel Jacobowitz <dan@debian.org>
1828
1829 * configure.in: Test for -rdynamic.
1830 * configure: Regenerated.
1831 * Makefile (INTERNAL_LDFLAGS): New.
1832 (gdbserver, gdbreplay): Use it.
1833
2c0fc042
AC
18342004-09-02 Andrew Cagney <cagney@gnu.org>
1835
1836 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
1837
075b3282
DJ
18382004-03-23 Daniel Jacobowitz <drow@mvista.com>
1839
1840 * linux-low.c (linux_wait): Clear all_processes list also.
1841
fa6a77dc
DJ
18422004-03-12 Daniel Jacobowitz <drow@mvista.com>
1843
1844 * linux-low.c: Include <errno.h>. Remove extern declaration of
1845 errno.
1846
6d782a97
DJ
18472004-03-12 Daniel Jacobowitz <drow@mvista.com>
1848
1849 * gdbreplay.c, server.h, utils.c: Update copyright years.
1850
3a7fb99b
DJ
18512004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1852
1853 * server.c (main): Print child status or termination signal from
1854 variable 'signal', not 'sig'.
1855
c3e735a6
DJ
18562004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
1857
1858 * linux-low.c (linux_read_memory): Change return type to
1859 int. Check for and return error from ptrace().
1860 * target.c (read_inferior_memory): Change return type to int. Pass
1861 back return status from the_target->read_memory().
1862 * target.h (struct target_ops): Adapt *read_memory() prototype.
1863 Update comment.
1864 (read_inferior_memory): Adapt prototype.
1865 * server.c (main): Return an error packet if
1866 read_inferior_memory() returns an error.
1867
a59d1c82
DJ
18682004-03-04 Daniel Jacobowitz <drow@mvista.com>
1869
1870 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
1871 Unify with other clean targets.
1872
dc3f8883
DJ
18732004-02-29 Daniel Jacobowitz <drow@mvista.com>
1874
1875 * server.c (handle_v_cont): Call set_desired_inferior.
1876
89a208da
DJ
18772004-02-29 Daniel Jacobowitz <drow@mvista.com>
1878
1879 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
1880
62ea82f5
DJ
18812004-02-29 Daniel Jacobowitz <drow@mvista.com>
1882
1883 * linux-low.c (linux_wait): Unblock async I/O.
1884 (linux_resume): Block and enable async I/O.
1885 * remote-utils.c (block_async_io, unblock_async_io): New functions.
1886 * server.h (block_async_io, unblock_async_io): Add prototypes.
1887
6910d122
DJ
18882004-02-29 Daniel Jacobowitz <drow@mvista.com>
1889
1890 * remote-utils.c (remote_open): Print a status notice after
1891 opening a TCP port.
1892 * server.c (attach_inferior): Print a status notice after
1893 attaching.
1894
18952004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
1896
1897 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
1898
c89dc5d4
DJ
18992004-02-26 Daniel Jacobowitz <drow@mvista.com>
1900
1901 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
1902 error packet.
1903 * server.c, target.h: Update copyright years.
1904
4b8dad4a
RM
19052004-02-25 Roland McGrath <roland@redhat.com>
1906
1907 * target.h (struct target_ops): New member `read_auxv'.
1908 * server.c (handle_query): Handle qPart:auxv:read: query using that.
1909 * linux-low.c (linux_read_auxv): New function.
1910 (linux_target_ops): Initialize `read_auxv' member to that.
1911
d7446758
JB
19122004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1913
1914 Committed by Jim Blandy <jimb@redhat.com>.
1915
1916 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 1917 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
1918 instead of GPR_SIZE to distiguish s390 and s390x targets.
1919
5544ad89
DJ
19202004-01-31 Daniel Jacobowitz <drow@mvista.com>
1921
1922 * linux-low.c: Update copyright year.
1923 (check_removed_breakpoint): Clear pending_is_breakpoint.
1924 (linux_set_resume_request, linux_queue_one_thread)
1925 (resume_status_pending_p): New functions.
1926 (linux_continue_one_thread): Use process->resume.
1927 (linux_resume): Only resume threads if there are no pending events.
1928 * linux-low.h (struct process_info): Add resume request
1929 pointer.
1930
2a68b70e
DJ
19312004-01-30 Daniel Jacobowitz <drow@mvista.com>
1932
1933 * regcache.c (new_register_cache): Clear the allocated register
1934 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
1935
64386c31
DJ
19362003-10-13 Daniel Jacobowitz <drow@mvista.com>
1937
1938 * linux-low.c (linux_resume): Take a struct thread_resume *
1939 argument.
1940 (linux_wait): Update call.
1941 (resume_ptr): New static variable.
1942 (linux_continue_one_thread): Renamed from
1943 linux_continue_one_process. Use resume_ptr.
1944 (linux_resume): Use linux_continue_one_thread.
1945 * server.c (handle_v_cont, handle_v_requests): New functions.
1946 (myresume): New function.
1947 (main): Handle 'v' case.
1948 * target.h (struct thread_resume): New type.
1949 (struct target_ops): Change argument of "resume" to struct
1950 thread_resume *.
1951 (myresume): Delete macro.
1952
c938e9b0
L
19532003-08-08 H.J. Lu <hongjiu.lu@intel.com>
1954
1955 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
1956 (uninstall): Support DESTDIR.
1957
7f313d07
BC
1958Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
1959
1960 * configure.srv: Add xscale*linux copy of arm*linux entry.
1961
3b2fc2ea
DJ
19622003-07-24 Daniel Jacobowitz <drow@mvista.com>
1963
1964 * linux-arm-low.c (arm_reinsert_addr): New function.
1965 (the_low_target): Add arm_reinsert_addr.
1966
1c0a559e
MK
19672003-07-08 Mark Kettenis <kettenis@gnu.org>
1968
1969 * mem-break.c: Remove whitespace at end of file.
1970
43d5792c
DJ
19712003-06-28 Daniel Jacobowitz <drow@mvista.com>
1972
1973 * configure.in: Check whether we need to prototype strerror.
1974 * server.h: Optionally prototype strerror.
1975 * gdbreplay.c (perror_with_name): Use strerror.
1976 * linux-low.c (linux_attach_lwp): Use strerror.
1977 * utils.c (perror_with_name): Use strerror.
1978 * config.in, configure: Regenerated.
1979
c8a86edf
DJ
19802003-06-28 Daniel Jacobowitz <drow@mvista.com>
1981
1982 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
1983 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
1984
73d37363
DJ
19852003-06-20 Daniel Jacobowitz <drow@mvista.com>
1986
1987 * Makefile.in (SFILES): Update.
1988 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
1989 low-sun3.c: Remove files.
1990
6ad8ae5c
DJ
19912003-06-17 Daniel Jacobowitz <drow@mvista.com>
1992
1993 * linux-low.c: Move comment to linux_thread_alive where it belonged.
1994 (linux_detach_one_process, linux_detach): New functions.
1995 (linux_target_ops): Add linux_detach.
1996 * server.c (main): Handle 'D' packet.
1997 * target.h (struct target_ops): Add "detach" member.
1998 (detach_inferior): Define.
1999
1581182a
MK
20002003-06-13 Mark Kettenis <kettenis@gnu.org>
2001
2002 From Kelley Cook <kelleycook@wideopenwest.com>:
2003 * configure.srv: Accept i[34567]86 variants.
2004
e5379b03
DJ
20052003-06-05 Daniel Jacobowitz <drow@mvista.com>
2006
2007 * linux-low.c (linux_wait_for_event): Correct comment typos.
2008 (linux_resume_one_process): Call check_removed_breakpoint.
2009 (linux_send_signal): New function.
2010 (linux_target_ops): Add linux_send_signal.
2011 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
2012 of kill.
2013 * target.h (struct target_ops): Add send_signal.
2014
2ff29de4
JB
20152003-05-29 Jim Blandy <jimb@redhat.com>
2016
2017 * linux-low.c (usr_store_inferior_registers): Transfer buf in
2018 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
2019 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
2020 away part of the register's value.
2021
254787d4
DJ
20222003-03-26 Daniel Jacobowitz <drow@mvista.com>
2023
2024 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
2025 (linux_wait_for_event, linux_init_signals): Likewise.
2026
94e10508
DJ
20272003-03-17 Daniel Jacobowitz <drow@mvista.com>
2028
2029 * configure.in: Check for stdlib.h.
2030 * configure: Regenerated.
2031 * config.in: Regenerated.
2032
4c0711e0
DJ
20332003-01-04 Andreas Schwab <schwab@suse.de>
2034
2035 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
2036
ef66e766
AC
20372003-01-02 Andrew Cagney <ac131313@redhat.com>
2038
2039 * Makefile.in: Remove obsolete code.
2040
a1358604
DJ
20412002-11-20 Daniel Jacobowitz <drow@mvista.com>
2042
2043 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
2044 defined(PT_FPR0_HI).
2045
23ce3b1c
DJ
20462002-11-17 Stuart Hughes <seh@zee2.com>
2047
2048 * linux-arm-low.c (arm_num_regs): Increase.
2049 (arm_regmap): Include status register.
2050
20512002-11-17 Daniel Jacobowitz <drow@mvista.com>
2052
2053 * linux-low.c (register_addr): Remove incorrect -1 check.
2054
a9fa9f7d
DJ
20552002-08-29 Daniel Jacobowitz <drow@mvista.com>
2056
2057 * linux-low.c (linux_create_inferior): Call setpgid. Return
2058 the new PID.
2059 (unstopped_p, linux_signal_pid): Remove.
2060 (linux_target_ops): Remove linux_signal_pid.
2061 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
2062 global instead of target method.
2063 * target.h (struct target_ops): Remove signal_pid. Update comment
2064 for create_inferior.
2065 * server.c (signal_pid): New variable.
2066 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 2067 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
2068 (attach_inferior): Set signal_pid.
2069
17574093
DJ
20702002-08-23 Daniel Jacobowitz <drow@mvista.com>
2071
2072 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
2073
20742002-08-20 Jim Blandy <jimb@redhat.com>
2075
2076 * Makefile.in (LDFLAGS): Allow the configure script to establish a
2077 default for this.
2078
20792002-08-01 Andrew Cagney <cagney@redhat.com>
2080
2081 * Makefile.in: Make chill references obsolete.
2082
20832002-07-24 Kevin Buettner <kevinb@redhat.com>
2084
2085 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
2086 * configure: Regenerate.
2087 * config.in: Regenerate.
2088
20892002-07-09 David O'Brien <obrien@FreeBSD.org>
2090
2091 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
2092 (perror_with_name, remote_close, remote_open, expect, play): Static.
2093
20942002-07-04 Michal Ludvig <mludvig@suse.cz>
2095
4b8dad4a 2096 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
2097 byte offsets instead of an array of indexes.
2098 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
2099
21002002-06-13 Daniel Jacobowitz <drow@mvista.com>
2101
2102 * regcache.c: Add comment.
2103
21042002-06-11 Daniel Jacobowitz <drow@mvista.com>
2105
2106 * thread-db.c: New file.
2107 * proc-service.c: New file.
2108 * acinclude.m4: New file.
2109 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
2110 proc-service.o, and thread-db.o.
2111 (linux-low.o): Add USE_THREAD_DB.
2112 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
2113 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
2114 * aclocal.m4: Regenerated.
2115 * config.in: Regenerated.
2116 * configure: Regenerated.
2117 * configure.in: Check for proc_service.h, sys/procfs.h,
2118 thread_db.h, and linux/elf.h headrs.
2119 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
2120 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
2121 Check for -lthread_db and thread support.
2122 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
2123 PowerPC, and SuperH.
2124 * i387-fp.c: Constify arguments.
2125 * i387-fp.h: Likewise.
2126 * inferiors.c: (struct thread_info): Renamed from
2127 `struct inferior_info'. Remove PID member. Use generic inferior
2128 list header. All uses updated.
2129 (inferiors, signal_pid): Removed.
2130 (all_threads): New variable.
2131 (get_thread): Define.
2132 (add_inferior_to_list): New function.
2133 (for_each_inferior): New function.
2134 (change_inferior_id): New function.
2135 (add_inferior): Removed.
2136 (remove_inferior): New function.
2137 (add_thread): New function.
2138 (free_one_thread): New function.
2139 (remove_thread): New function.
2140 (clear_inferiors): Use for_each_inferior and free_one_thread.
2141 (find_inferior): New function.
2142 (find_inferior_id): New function.
2143 (inferior_target_data): Update argument type.
2144 (set_inferior_target_data): Likewise.
2145 (inferior_regcache_data): Likewise.
2146 (set_inferior_regcache_data): Likewise.
2147 * linux-low.c (linux_bp_reinsert): Remove.
2148 (all_processes, stopping_threads, using_thrads)
2149 (struct pending_signals, debug_threads, pid_of): New.
2150 (inferior_pid): Replace with macro.
2151 (struct inferior_linux_data): Remove.
2152 (get_stop_pc, add_process): New functions.
2153 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
2154 Use add_process and add_thread.
2155 (linux_attach_lwp): New function, based on old linux_attach. Use
2156 add_process and add_thread. Set stop_expected for new threads.
2157 (linux_attach): New function.
2158 (linux_kill_one_process): New function.
2159 (linux_kill): Kill all LWPs.
2160 (linux_thread_alive): Use find_inferior_id.
2161 (check_removed_breakpoints, status_pending_p): New functions.
2162 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
2163 Update. Use WNOHANG. Wait for cloned processes also. Update process
2164 struct for the found process.
2165 (linux_wait_for_event): New function.
2166 (linux_wait): Use it. Support LWPs.
2167 (send_sigstop, wait_for_sigstop, stop_all_processes)
2168 (linux_resume_one_process, linux_continue_one_process): New functions.
2169 (linux_resume): Support LWPs.
2170 (REGISTER_RAW_SIZE): Remove.
2171 (fetch_register): Use register_size instead. Call supply_register.
2172 (usr_store_inferior_registers): Likewise. Call collect_register.
2173 Fix recursive case.
2174 (regsets_fetch_inferior_registers): Improve error message.
2175 (regsets_store_inferior_registers): Add debugging.
2176 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
2177 (unstopped_p, linux_signal_pid): New functions.
2178 (linux_target_ops): Add linux_signal_pid.
2179 (linux_init_signals): New function.
2180 (initialize_low): Call it. Initialize using_threads.
2181 * regcache.c (inferior_regcache_data): Add valid
2182 flag.
2183 (get_regcache): Fetch registers lazily. Add fetch argument
2184 and update all callers.
2185 (regcache_invalidate_one, regcache_invalidate): New
2186 functions.
2187 (new_register_cache): Renamed from create_register_cache.
2188 Return the new regcache.
2189 (free_register_cache): Change argument to a void *.
2190 (registers_to_string, registers_from_string): Call get_regcache
2191 with fetch flag set.
2192 (register_data): Make static. Pass fetch flag to get_regcache.
2193 (supply_register): Call get_regcache with fetch flag clear.
2194 (collect_register): Call get_regcache with fetch flag set.
2195 (collect_register_as_string): New function.
2196 * regcache.h: Update.
2197 * remote-utils.c (putpkt): Flush after debug output and use
2198 stderr.
2199 Handle input interrupts while waiting for an ACK.
2200 (input_interrupt): Use signal_pid method.
2201 (getpkt): Flush after debug output and use stderr.
2202 (outreg): Use collect_register_as_string.
2203 (new_thread_notify, dead_thread_notify): New functions.
2204 (prepare_resume_reply): Check using_threads. Set thread_from_wait
2205 and general_thread.
2206 (look_up_one_symbol): Flush after debug output.
2207 * server.c (step_thread, server_waiting): New variables.
2208 (start_inferior): Don't use signal_pid. Update call to mywait.
2209 (attach_inferior): Update call to mywait.
2210 (handle_query): Handle qfThreadInfo and qsThreadInfo.
2211 (main): Don't fetch/store registers explicitly. Use
2212 set_desired_inferior. Support proposed ``Hs'' packet. Update
2213 calls to mywait.
2214 * server.h: Update.
2215 (struct inferior_list, struct_inferior_list_entry): New.
2216 * target.c (set_desired_inferior): New.
2217 (write_inferior_memory): Constify.
2218 (mywait): New function.
2219 * target.h: Update.
2220 (struct target_ops): New signal_pid method.
2221 (mywait): Removed macro, added prototype.
2222
2223 * linux-low.h (regset_func): Removed.
2224 (regset_fill_func, regset_store_func): New.
2225 (enum regset_type): New.
2226 (struct regset_info): Add type field. Use new operation types.
2227 (struct linux_target_ops): stop_pc renamed to get_pc.
2228 Add decr_pc_after_break and breakpoint_at.
2229 (get_process, get_thread_proess, get_process_thread)
2230 (strut process_info, all_processes, linux_attach_lwp)
2231 (thread_db_init): New.
2232
2233 * linux-arm-low.c (arm_get_pc, arm_set_pc,
2234 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
2235 (the_low_target): Add new members.
2236 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
2237 (i386_store_fpxregset): Constify.
2238 (target_regsets): Add new kind identifier.
2239 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
2240 (i386_set_pc): Add debugging.
2241 (i386_breakpoint_at): New function.
2242 (the_low_target): Add new members.
2243 * linux-mips-low.c (mips_get_pc, mips_set_pc)
2244 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
2245 (mips_breakpoint_at): New.
2246 (the_low_target): Add new members.
2247 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
2248 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
2249 (the_low_target): Add new members.
2250 * linux-sh-low.c (sh_get_pc, sh_set_pc)
2251 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
2252 (the_low_target): Add new members.
2253 * linux-x86-64-low.c (target_regsets): Add new kind
2254 identifier.
2255
22562002-05-15 Daniel Jacobowitz <drow@mvista.com>
2257
2258 From Martin Pool <mbp@samba.org>:
2259 * server.c (gdbserver_usage): New function.
2260 (main): Call it.
2261
22622002-05-14 Daniel Jacobowitz <drow@mvista.com>
2263
2264 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
2265 stop_at -> stop_pc.
2266
22672002-05-04 Andrew Cagney <ac131313@redhat.com>
2268
2269 * Makefile.in: Remove obsolete code.
2270
22712002-04-24 Michal Ludvig <mludvig@suse.cz>
2272
2273 * linux-low.c (regsets_fetch_inferior_registers),
2274 (regsets_store_inferior_registers): Removed cast to int from
2275 ptrace() calls.
2276 * regcache.h: Added declaration of struct inferior_info.
2277
22782002-04-20 Daniel Jacobowitz <drow@mvista.com>
2279
2280 * inferiors.c (struct inferior_info): Add regcache_data.
2281 (add_inferior): Call create_register_cache.
2282 (clear_inferiors): Call free_register_cache.
2283 (inferior_regcache_data, set_inferior_regcache_data): New functions.
2284 * regcache.c (struct inferior_regcache_data): New.
2285 (registers): Remove.
2286 (get_regcache): New function.
2287 (create_register_cache, free_register_cache): New functions.
2288 (set_register_cache): Don't initialize the register cache here.
2289 (registers_to_string, registers_from_string, register_data): Call
2290 get_regcache.
2291 * regcache.h: Add prototypes.
2292 * server.h: Likewise.
2293
22942002-04-20 Daniel Jacobowitz <drow@mvista.com>
2295
2296 * mem-break.c: New file.
2297 * mem-break.h: New file.
2298 * Makefile.in: Add mem-break.o rule; update server.h
2299 dependencies.
2300 * inferiors.c (struct inferior_info): Add target_data
2301 member.
2302 (clear_inferiors): Free target_data member if set.
2303 (inferior_target_data, set_inferior_target_data): New functions.
2304 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
2305 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
2306 * linux-low.c (linux_bp_reinsert): New variable.
2307 (struct inferior_linux_data): New.
2308 (linux_create_inferior): Use set_inferior_target_data.
2309 (linux_attach): Likewise. Call add_inferior.
2310 (linux_wait_for_one_inferior): New function.
2311 (linux_wait): Call it.
2312 (linux_write_memory): Add const.
2313 (initialize_low): Call set_breakpoint_data.
2314 * linux-low.h (struct linux_target_ops): Add breakpoint
2315 handling members.
2316 * server.c (attach_inferior): Remove extra add_inferior
2317 call.
2318 * server.h: Include mem-break.h. Update inferior.c
2319 prototypes.
2320 * target.c (read_inferior_memory)
2321 (write_inferior_memory): New functions.
2322 * target.h (read_inferior_memory)
2323 (write_inferior_memory): Change macros to prototypes.
2324 (struct target_ops): Update comments. Add const to write_memory
2325 definition.
2326
23272002-04-11 Daniel Jacobowitz <drow@mvista.com>
2328
2329 * linux-low.c (usr_store_inferior_registers): Support
2330 registers which are allowed to fail to store.
2331 * linux-low.h (linux_target_ops): Likewise.
2332 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
2333 (ppc_cannot_store_register): FPSCR may not be storable.
2334
23352002-04-09 Daniel Jacobowitz <drow@mvista.com>
2336
2337 * server.h: Include <string.h> if HAVE_STRING_H.
2338 * ChangeLog: Correct paths in last ChangeLog entry.
2339
23402002-04-09 Daniel Jacobowitz <drow@mvista.com>
2341
2342 * linux-low.h: Remove obsolete prototypes.
2343 (struct linux_target_ops): New.
2344 (extern the_low_target): New.
2345 * linux-low.c (num_regs, regmap): Remove declarations.
2346 (register_addr): Use the_low_target explicitly.
2347 (fetch_register): Likewise.
2348 (usr_fetch_inferior_registers): Likewise.
2349 (usr_store_inferior_registers): Likewise.
2350 * linux-arm-low.c (num_regs): Remove.
2351 (arm_num_regs): Define.
2352 (arm_regmap): Renamed from regmap, made static.
2353 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
2354 made static.
2355 (arm_cannot_store_register): Renamed from cannot_store_register,
2356 made static.
2357 (the_low_target): New.
2358 * linux-i386-low.c (num_regs): Remove.
2359 (i386_num_regs): Define.
2360 (i386_regmap): Renamed from regmap, made static.
2361 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
2362 made static.
2363 (i386_cannot_store_register): Renamed from cannot_store_register,
2364 made static.
2365 (the_low_target): New.
2366 * linux-ia64-low.c (num_regs): Remove.
2367 (ia64_num_regs): Define.
2368 (ia64_regmap): Renamed from regmap, made static.
2369 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
2370 made static.
2371 (ia64_cannot_store_register): Renamed from cannot_store_register,
2372 made static.
2373 (the_low_target): New.
2374 * linux-m68k-low.c (num_regs): Remove.
2375 (m68k_num_regs): Define.
2376 (m68k_regmap): Renamed from regmap, made static.
2377 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
2378 made static.
2379 (m68k_cannot_store_register): Renamed from cannot_store_register,
2380 made static.
2381 (the_low_target): New.
2382 * linux-mips-low.c (num_regs): Remove.
2383 (mips_num_regs): Define.
2384 (mips_regmap): Renamed from regmap, made static.
2385 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
2386 made static.
2387 (mips_cannot_store_register): Renamed from cannot_store_register,
2388 made static.
2389 (the_low_target): New.
2390 * linux-ppc-low.c (num_regs): Remove.
2391 (ppc_num_regs): Define.
2392 (ppc_regmap): Renamed from regmap, made static.
2393 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
2394 made static.
2395 (ppc_cannot_store_register): Renamed from cannot_store_register,
2396 made static.
2397 (the_low_target): New.
2398 * linux-s390-low.c (num_regs): Remove.
2399 (s390_num_regs): Define.
2400 (s390_regmap): Renamed from regmap, made static.
2401 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
2402 made static.
2403 (s390_cannot_store_register): Renamed from cannot_store_register,
2404 made static.
2405 (the_low_target): New.
2406 * linux-sh-low.c (num_regs): Remove.
2407 (sh_num_regs): Define.
2408 (sh_regmap): Renamed from regmap, made static.
2409 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
2410 made static.
2411 (sh_cannot_store_register): Renamed from cannot_store_register,
2412 made static.
2413 (the_low_target): New.
2414 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
2415 (the_low_target): New.
2416
24172002-04-09 Daniel Jacobowitz <drow@mvista.com>
2418
2419 * Makefile.in: Add stamp-h target.
2420 * configure.in: Create stamp-h.
2421 * configure: Regenerated.
2422
24232002-04-09 Daniel Jacobowitz <drow@mvista.com>
2424
2425 * inferiors.c: New file.
2426 * target.c: New file.
2427 * target.h: New file.
2428 * Makefile.in: Add target.o and inferiors.o. Update
2429 dependencies.
2430 * linux-low.c (inferior_pid): New static variable,
2431 moved from server.c.
2432 (linux_create_inferior): Renamed from create_inferior.
2433 Call add_inferior. Return 0 on success instead of a PID.
2434 (linux_attach): Renamed from myattach.
2435 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
2436 (linux_thread_alive): Renamed from mythread_alive.
2437 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
2438 child dies.
2439 (linux_resume): Renamed from myresume. Add missing ``return 0''.
2440 (regsets_store_inferior_registers): Correct error message.
2441 Add missing ``return 0''.
2442 (linux_fetch_registers): Renamed from fetch_inferior_registers.
2443 (linux_store_registers): Renamed from store_inferior_registers.
2444 (linux_read_memory): Renamed from read_inferior_memory.
2445 (linux_write_memory): Renamed from write_inferior_memory.
2446 (linux_target_ops): New structure.
2447 (initialize_low): Call set_target_ops ().
2448 * remote-utils.c (unhexify): New function.
2449 (hexify): New function.
2450 (input_interrupt): Send signals to ``signal_pid''.
2451 * server.c (inferior_pid): Remove.
2452 (start_inferior): Update create_inferior call.
2453 (attach_inferior): Call add_inferior.
2454 (handle_query): New function.
2455 (main): Call handle_query for `q' packets.
2456 * server.h: Include "target.h". Remove obsolete prototypes.
2457 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
2458
24592002-04-09 Daniel Jacobowitz <drow@mvista.com>
2460
2461 * Makefile.in: Add WARN_CFLAGS. Update configury
2462 dependencies.
2463 * configure.in: Check for <string.h>
2464 * configure: Regenerate.
2465 * config.in: Regenerate.
2466 * gdbreplay.c: Include needed system headers.
2467 (remote_open): Remove strchr prototype.
2468 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
2469 * regcache.c (supply_register): Change buf argument to const void *.
2470 (supply_register_by_name): Likewise.
2471 (collect_register): Change buf argument to void *.
2472 (collect_register_by_name): Likewise.
2473 * regcache.h: Add missing prototypes.
2474 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
2475 * server.c (handle_query): New function.
2476 (attached): New static variable, moved out of main.
2477 (main): Quiet longjmp clobber warnings.
2478 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
2479 * utils.c (error): Remove NORETURN.
2480 (fatal): Likewise.