qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Jim C. Brown" <jma5@umd.edu>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Keyboard issues, native DOS mode
Date: Tue, 14 Mar 2006 20:01:00 -0500	[thread overview]
Message-ID: <20060315010100.GA17629@jbrown.mylinuxbox.org> (raw)
In-Reply-To: <20060314191027.X71269@starbug.ugh.net.au>

[-- Attachment #1: Type: text/plain, Size: 1162 bytes --]

On Tue, Mar 14, 2006 at 07:40:58PM +1100, David Burrows wrote:
> Hi all,
> 
> This particular application, which is used to tune the aftermarket fuel 
> injection computer in my car, has a problem when running in native
> DOS mode, where two keypresses are received, instead of just the one that
> was actually pressed.  In particular I'm referring to the cursor keys.

Patch attached.

> 
> Interestingly enough, this behaviour is not exhibited when the program is 
> run from within either win98se or win2k.

w2k (don't say win2k or win98 - see RMS on why) emulates its own kbd controller,
Hence this bus would never have manifested.

Not sure how w98 handles this but I'd guess it does emulation as well, so you
don't see the bug for the same reason.

> 
> It might be of note that I'm using a debian sid system, but I've also 
> tried it on Ubuntu Breezy, and several others have reproduced the same 
> result.
> 

Shouldn't matter, as it's a qemu bug so it'd be present on all versions (in fact
it'd be present when running DOS in qemu on a Windows host iiuc).

-- 
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.

[-- Attachment #2: snadge-w.diff --]
[-- Type: text/plain, Size: 611 bytes --]

--- ps2.c.orig	Tue Mar 14 19:46:15 2006
+++ ps2.c	Tue Mar 14 19:43:58 2006
@@ -146,6 +146,7 @@
     PS2State *s = (PS2State *)opaque;
     PS2Queue *q;
     int val, index;
+static int hahaha = 0;
     
     q = &s->queue;
     if (q->count == 0) {
@@ -156,7 +157,16 @@
         if (index < 0)
             index = PS2_QUEUE_SIZE - 1;
         val = q->data[index];
+if (hahaha){
+val = 0;
+hahaha = 0;
+printf("many badness\n");
+} else
+{ hahaha = 1;
+printf("some badness\n");
+}
     } else {
+hahaha = 0;
         val = q->data[q->rptr];
         if (++q->rptr == PS2_QUEUE_SIZE)
             q->rptr = 0;

  reply	other threads:[~2006-03-15  1:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-14  8:40 [Qemu-devel] Keyboard issues, native DOS mode David Burrows
2006-03-15  1:01 ` Jim C. Brown [this message]
2006-03-15  1:25   ` Jim C. Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060315010100.GA17629@jbrown.mylinuxbox.org \
    --to=jma5@umd.edu \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).