From patchwork Wed Dec 16 15:08:33 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mattia Dongili X-Patchwork-Id: 68382 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id nBI4ixoe005715 for ; Fri, 18 Dec 2009 04:46:16 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756883AbZLPPIv (ORCPT ); Wed, 16 Dec 2009 10:08:51 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1761088AbZLPPIv (ORCPT ); Wed, 16 Dec 2009 10:08:51 -0500 Received: from static-220-247-10-204.b-man.svips.gol.ne.jp ([220.247.10.204]:38824 "EHLO smtp.kamineko.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756883AbZLPPIt (ORCPT ); Wed, 16 Dec 2009 10:08:49 -0500 Received: by smtp.kamineko.org (Postfix, from userid 1004) id 313E1742A4; Thu, 17 Dec 2009 00:08:49 +0900 (JST) Received: from caligola.kamineko.org (unknown [192.168.1.10]) by smtp.kamineko.org (Postfix) with ESMTP id 4C5B5742B0; Thu, 17 Dec 2009 00:08:48 +0900 (JST) Received: by caligola.kamineko.org (Postfix, from userid 1000) id 2B10F16128; Thu, 17 Dec 2009 00:08:48 +0900 (JST) From: Mattia Dongili To: Len Brown Cc: linux-acpi@vger.kernel.org, Mattia Dongili , "Matthew W. S. Bell" , Dmitry Torokhov Subject: [PATCH 1/4] sony-laptop: add AVMode key mapping Date: Thu, 17 Dec 2009 00:08:33 +0900 Message-Id: <1260976116-6369-2-git-send-email-malattia@linux.it> X-Mailer: git-send-email 1.6.5.4 In-Reply-To: <1260976116-6369-1-git-send-email-malattia@linux.it> References: <1260976116-6369-1-git-send-email-malattia@linux.it> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.0 Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org diff --git a/drivers/platform/x86/sony-laptop.c b/drivers/platform/x86/sony-laptop.c index a2a742c..9710f70 100644 --- a/drivers/platform/x86/sony-laptop.c +++ b/drivers/platform/x86/sony-laptop.c @@ -232,6 +232,7 @@ static int sony_laptop_input_index[] = { 56, /* 69 SONYPI_EVENT_VOLUME_INC_PRESSED */ 57, /* 70 SONYPI_EVENT_VOLUME_DEC_PRESSED */ -1, /* 71 SONYPI_EVENT_BRIGHTNESS_PRESSED */ + 58, /* 72 SONYPI_EVENT_MEDIA_PRESSED */ }; static int sony_laptop_input_keycode_map[] = { @@ -293,6 +294,7 @@ static int sony_laptop_input_keycode_map[] = { KEY_F15, /* 55 SONYPI_EVENT_SETTINGKEY_PRESSED */ KEY_VOLUMEUP, /* 56 SONYPI_EVENT_VOLUME_INC_PRESSED */ KEY_VOLUMEDOWN, /* 57 SONYPI_EVENT_VOLUME_DEC_PRESSED */ + KEY_MEDIA, /* 58 SONYPI_EVENT_MEDIA_PRESSED */ }; /* release buttons after a short delay if pressed */ @@ -890,6 +892,8 @@ static struct sony_nc_event sony_100_events[] = { { 0x0C, SONYPI_EVENT_FNKEY_RELEASED }, { 0x9f, SONYPI_EVENT_CD_EJECT_PRESSED }, { 0x1f, SONYPI_EVENT_ANYBUTTON_RELEASED }, + { 0xa1, SONYPI_EVENT_MEDIA_PRESSED }, + { 0x21, SONYPI_EVENT_ANYBUTTON_RELEASED }, { 0, 0 }, }; diff --git a/include/linux/sonypi.h b/include/linux/sonypi.h index 34c4475..4f95c1a 100644 --- a/include/linux/sonypi.h +++ b/include/linux/sonypi.h @@ -111,6 +111,7 @@ #define SONYPI_EVENT_VOLUME_INC_PRESSED 69 #define SONYPI_EVENT_VOLUME_DEC_PRESSED 70 #define SONYPI_EVENT_BRIGHTNESS_PRESSED 71 +#define SONYPI_EVENT_MEDIA_PRESSED 72 /* get/set brightness */ #define SONYPI_IOCGBRT _IOR('v', 0, __u8)