Message ID | 4BE11F54.1030900@web.de |
---|---|
State | New |
Headers | show |
Jan Kiszka wrote: > Alex, does this help as well? > > diff --git a/qemu-char.c b/qemu-char.c > index ac65a1c..2b115a4 100644 > --- a/qemu-char.c > +++ b/qemu-char.c > @@ -404,6 +404,8 @@ static int mux_chr_can_read(void *opaque) > MuxDriver *d = chr->opaque; > int m = d->focus; > > + mux_chr_accept_input(opaque); > + > if ((d->prod[m] - d->cons[m]) < MUX_BUFFER_SIZE) > return 1; > if (d->chr_can_read[m]) > @@ -418,8 +420,6 @@ static void mux_chr_read(void *opaque, const uint8_t *buf, int size) > int m = d->focus; > int i; > > - mux_chr_accept_input (opaque); > - > for(i = 0; i < size; i++) > if (mux_proc_byte(chr, d, buf[i])) { > if (d->prod[m] == d->cons[m] && > > > I'm trying to reproduce in parallel. Works for me. Will post as proper patch later. Jan
Am 05.05.2010 um 10:08 schrieb Jan Kiszka <jan.kiszka@web.de>: > Jan Kiszka wrote: >> Alex, does this help as well? >> >> diff --git a/qemu-char.c b/qemu-char.c >> index ac65a1c..2b115a4 100644 >> --- a/qemu-char.c >> +++ b/qemu-char.c >> @@ -404,6 +404,8 @@ static int mux_chr_can_read(void *opaque) >> MuxDriver *d = chr->opaque; >> int m = d->focus; >> >> + mux_chr_accept_input(opaque); >> + >> if ((d->prod[m] - d->cons[m]) < MUX_BUFFER_SIZE) >> return 1; >> if (d->chr_can_read[m]) >> @@ -418,8 +420,6 @@ static void mux_chr_read(void *opaque, const >> uint8_t *buf, int size) >> int m = d->focus; >> int i; >> >> - mux_chr_accept_input (opaque); >> - >> for(i = 0; i < size; i++) >> if (mux_proc_byte(chr, d, buf[i])) { >> if (d->prod[m] == d->cons[m] && >> >> >> I'm trying to reproduce in parallel. > > Works for me. Will post as proper patch later. I'll try it out next week, after my vacation is over :) Alex >
diff --git a/qemu-char.c b/qemu-char.c index ac65a1c..2b115a4 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -404,6 +404,8 @@ static int mux_chr_can_read(void *opaque) MuxDriver *d = chr->opaque; int m = d->focus; + mux_chr_accept_input(opaque); + if ((d->prod[m] - d->cons[m]) < MUX_BUFFER_SIZE) return 1; if (d->chr_can_read[m]) @@ -418,8 +420,6 @@ static void mux_chr_read(void *opaque, const uint8_t *buf, int size) int m = d->focus; int i; - mux_chr_accept_input (opaque); - for(i = 0; i < size; i++) if (mux_proc_byte(chr, d, buf[i])) { if (d->prod[m] == d->cons[m] &&