public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Pekka Enberg <penberg@kernel.org>
Cc: kvm@vger.kernel.org, Sasha Levin <levinsasha928@gmail.com>
Subject: Re: [PATCH 3/3] kvm tools, i8042: Use kernel command names
Date: Thu, 2 Jun 2011 13:19:30 +0200	[thread overview]
Message-ID: <20110602111930.GC14582@elte.hu> (raw)
In-Reply-To: <1307012202-14875-3-git-send-email-penberg@kernel.org>


ok, with the shared commands it place here's some 
feature-completeness comparison of the kernel driver and the 
emulator:

                                guest driver i8042.h   |   hw/i8042.c emu
/*
 * Status register bits
 */
#define I8042_STR_PARITY        0x80                   |  missing
#define I8042_STR_TIMEOUT       0x40                   |  missing
#define I8042_STR_AUXDATA       0x20                   |  ok
#define I8042_STR_KEYLOCK       0x10                   |  ok
#define I8042_STR_CMDDAT        0x08                   |  ok
#define I8042_STR_MUXERR        0x04                   |  ok
#define I8042_STR_IBF           0x02                   |  missing
#define I8042_STR_OBF           0x01                   |  ok

The missing bits might be uninteresting, but wanted to map them out.

There's more divergence for commands:

                                guest driver i8042.h   |   hw/i8042.c emu

/*
 * Standard commands.
 */

#define I8042_CMD_CTL_RCTR      0x0120                 != 0x20
#define I8042_CMD_CTL_WCTR      0x1060                 != 0x60
#define I8042_CMD_CTL_TEST      0x01aa                 | missing

#define I8042_CMD_KBD_DISABLE   0x00ad                 | missing
#define I8042_CMD_KBD_ENABLE    0x00ae                 | missing
#define I8042_CMD_KBD_TEST      0x01ab                 | missing
#define I8042_CMD_KBD_LOOP      0x11d2                 | missing

#define I8042_CMD_AUX_DISABLE   0x00a7                 | ok
#define I8042_CMD_AUX_ENABLE    0x00a8                 | ok
#define I8042_CMD_AUX_TEST      0x01a9                 | != 0xa9
#define I8042_CMD_AUX_SEND      0x10d4                 | != 0xd4
#define I8042_CMD_AUX_LOOP      0x11d3                 | != 0xd3

#define I8042_CMD_MUX_PFX       0x0090                 | missing
#define I8042_CMD_MUX_SEND      0x1090                 | missing


Now the missing high word might just be some command symbol encoding 
difference, but it might be something more substantial as well.

Thanks,

	Ingo

  parent reply	other threads:[~2011-06-02 11:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-02 10:56 [PATCH 1/3] kvm tools, i8042: Sort status register bits Pekka Enberg
2011-06-02 10:56 ` [PATCH 2/3] kmv tools, i8042: Use kernel status register bit names Pekka Enberg
2011-06-02 10:56 ` [PATCH 3/3] kvm tools, i8042: Use kernel command names Pekka Enberg
2011-06-02 11:04   ` Ingo Molnar
2011-06-02 11:19   ` Ingo Molnar [this message]
2011-06-02 11:22     ` Pekka Enberg
2011-06-02 12:12     ` Ingo Molnar

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=20110602111930.GC14582@elte.hu \
    --to=mingo@elte.hu \
    --cc=kvm@vger.kernel.org \
    --cc=levinsasha928@gmail.com \
    --cc=penberg@kernel.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