From patchwork Tue Nov 21 21:43:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Denis V. Lunev\" via" X-Patchwork-Id: 10068967 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 249126038F for ; Tue, 21 Nov 2017 21:51:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 11BB129A70 for ; Tue, 21 Nov 2017 21:51:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0627D29A71; Tue, 21 Nov 2017 21:51:12 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8745229A6E for ; Tue, 21 Nov 2017 21:51:11 +0000 (UTC) Received: from localhost ([::1]:36713 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eHGRi-00082L-DU for patchwork-qemu-devel@patchwork.kernel.org; Tue, 21 Nov 2017 16:51:10 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60544) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eHGKy-0002hn-NI for qemu-devel@nongnu.org; Tue, 21 Nov 2017 16:44:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eHGKx-0006ub-O7 for qemu-devel@nongnu.org; Tue, 21 Nov 2017 16:44:12 -0500 Received: from mail-io0-x241.google.com ([2607:f8b0:4001:c06::241]:35106) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eHGKx-0006uL-J2 for qemu-devel@nongnu.org; Tue, 21 Nov 2017 16:44:11 -0500 Received: by mail-io0-x241.google.com with SMTP id i38so21053045iod.2 for ; Tue, 21 Nov 2017 13:44:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=le4+jM6/mopFmnfzSnwG4DAj9Y84KJ1wW3nZ2PQjd+g=; b=tXkqBjdNwiainBE68mzcyw3/NtZ6zFUeoUyZv6B9tfnDsGpQ91u8pQGIpW93sitNHy lWxc/i+yDypG+2Lb/Iysv374jBLwgWdQzygZCUKAQB02UcYJ2yO8QIHwlvbC1LcxdksA bdyxX5qKsM5i5QVwaHfJKLxgQN/8DVuR0lSoZkFZEI9hqIYQGXJ8aVjY7aPWaNyECgac Qwy9TXFDmrxUiy6fV9d0zfxNDG2u96ellDpGtOlOKvKfCE8SnDuU3qIhkl+84DuMmS9+ AqcTwotZQxidtJAZFArG9eIqrYN3vYpCQmSIbbAAWDorQ7F759H5lyUNjbVM8rVSCshC 2WGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=le4+jM6/mopFmnfzSnwG4DAj9Y84KJ1wW3nZ2PQjd+g=; b=CyB0p1vfpCDC9Ide9zN8n2FdKnHGrInXh0eS+ptaDlEhi0Xl2yHl3MYgo5vkZQVByB /+NlprREUBdOM/olNAD9iWAAnkXQx2pqGyUwiOKw2lMpWiA/Rh2vFKss42xqGeUtjSgc /7Bwt+AkotMbEvSVm6vKP6ZECQda/6gxox2X/epsQolvJ4HlKtyivyHXNctqR47LADbf BgEVLWBIZgkMMR5ABdr2VGD51KSZm3dWpj7pYeHQise8IkgASsORRxVFEtx/oIAnn4b8 aANZmY/PrV66sxYhE9bKnvSV68VJx40wo457OiBq1GCFJmweql9pz4PGRNJhuIMbx3FR 60DQ== X-Gm-Message-State: AJaThX7xtrigpIuCxoYIoRfY/BllHUcFd3TuAQc4Dg5KxyINGyQKrJ4v Lx4JPe6PqhNNZqti8SadVcQR+w== X-Google-Smtp-Source: AGs4zMbFekcXO8jDBv8wTV4NgK11J162V5Lb+l1RZzdN4c3UvQ/Yb9DjFc9Ggc4ZlF++Fk/30dTViw== X-Received: by 10.107.56.4 with SMTP id f4mr10472875ioa.71.1511300649924; Tue, 21 Nov 2017 13:44:09 -0800 (PST) Received: from paxos.mtv.corp.google.com ([2620:0:1000:1611:3165:c184:e312:3dd5]) by smtp.gmail.com with ESMTPSA id l88sm1705387iod.20.2017.11.21.13.44.08 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 21 Nov 2017 13:44:08 -0800 (PST) To: qemu-devel@nongnu.org Date: Tue, 21 Nov 2017 13:43:50 -0800 Message-Id: <20171121214350.55138-1-lepton@google.com> X-Mailer: git-send-email 2.15.0.448.gf294e3d99a-goog X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c06::241 Subject: [Qemu-devel] [PATCH] hw/input/hid: Fix some wrong hid usage mappings. X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Tao Wu via Qemu-devel From: "Denis V. Lunev\" via" Reply-To: Tao Wu Cc: kraxel@redhat.com, Tao Wu Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP There are some wrong hid usage mapping in hid_usage_keys table. It can be confirmed with "sendkey" command in monitor and verify the behavior in guest OS. This CL fixed some wrong hid usage mapping for these keys: kp_equals kp_comma audiomute volumedown volumeup power There still are some wrong mapping left in hid_usage_keys table, but they are not as important as above keys. The list of left buggy keys: open paste ro hiragana henkan yen again props undo front audioprev audionext calculator audioplay audiostop cut find sleep ac_refresh stop ac_forward ac_back help copy Signed-off-by: Tao Wu --- hw/input/hid.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/input/hid.c b/hw/input/hid.c index 0d049ff61c..08a0f07bbf 100644 --- a/hw/input/hid.c +++ b/hw/input/hid.c @@ -47,24 +47,24 @@ static const uint8_t hid_usage_keys[0x100] = { 0x3f, 0x40, 0x41, 0x42, 0x43, 0x53, 0x47, 0x5f, 0x60, 0x61, 0x56, 0x5c, 0x5d, 0x5e, 0x57, 0x59, 0x5a, 0x5b, 0x62, 0x63, 0x46, 0x00, 0x64, 0x44, - 0x45, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, + 0x45, 0x67, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0xe8, 0xe9, 0x71, 0x72, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0xe3, 0xe7, 0x65, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe3, 0x85, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x58, 0xe4, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x54, 0x00, 0x46, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x54, 0x00, 0x46, 0xe6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x48, 0x48, 0x4a, 0x52, 0x4b, 0x00, 0x50, 0x00, 0x4f, 0x00, 0x4d, 0x51, 0x4e, 0x49, 0x4c, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0xe3, 0xe7, 0x65, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe3, 0xe7, 0x65, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,