Re: problems with v3 (Was: gdbstub initial code, v3)

2010-08-13 Thread Roland McGrath
 I seem to understand the problem(s). I am a bit surprized. Basically
 I have the questions about almost every utrace_ function. I'll try
 to recheck and summarize my concerns tomorrow with a fresh head, I
 hope I missed something.

Ok.  That stuff about pure kernel implementation issues doesn't need
to go to the archer list and Tom, only to utrace-devel.


Thanks,
Roland



problems with v3 (Was: gdbstub initial code, v3)

2010-08-12 Thread Oleg Nesterov
On 08/11, Tom Tromey wrote:

  Oleg == Oleg Nesterov o...@redhat.com writes:

 Oleg So, the patch below fixes the problem, and gdb + /proc/ugdb seems
 Oleg to work.

 Oleg Indeed, gdb sees that this fd is not pipe/tcp and uses the hardwire
 Oleg serial_ops, but hardwire_readchar() doesn't play well with select().

 Oleg Please teach gdb to use poll/select ?

 I looked at this a little bit.  It seems to me that the hardwire stuff
 is for talking to ttys, and we instead want gdb to be using the pipe code.

I didn't verify this, but I don't think so. Please look at pipe_open().
Perhaps it makes sense to serial_add_interface(ugdb), I dunno.


OK. I was going to add some cleanups and send the new version today.
But after some testing (without gdb) I hit the kernel crashes. This
makes me think that probably something is wrong ;)

As usual, I can't blame my code. I am still investigating, the crash
is not easy to reproduce, but so far I _suspect_ the problems in utrace
code. At least utrace_barrier()-signal_pending() is definitely not
right.

Will continue tomorrow.

Oleg.