From patchwork Thu Aug 22 14:02:12 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Jason A. Donenfeld" X-Patchwork-Id: 2848265 Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id AFF519F2F6 for ; Thu, 22 Aug 2013 14:10:32 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 292AA20452 for ; Thu, 22 Aug 2013 14:10:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6C70B20397 for ; Thu, 22 Aug 2013 14:10:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753268Ab3HVOJs (ORCPT ); Thu, 22 Aug 2013 10:09:48 -0400 Received: from frisell.zx2c4.com ([192.95.5.64]:38115 "EHLO frisell.zx2c4.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752958Ab3HVOJr (ORCPT ); Thu, 22 Aug 2013 10:09:47 -0400 X-Greylist: delayed 399 seconds by postgrey-1.27 at vger.kernel.org; Thu, 22 Aug 2013 10:09:38 EDT DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=zx2c4.com; h=from:to:cc :subject:date:message-id:in-reply-to:references; s=mail; bh=Gf40 hWi6gCrBxgMmoa3gcjgYcw8=; b=yCpY6Dqs5BbC+H8pCsCW60TznI1P25VF+DLW tYp5OHppb3QLzHnILqODtngZbL+mjyiTgm4DNjxslFKeH1+r78xqof8p00Cn523z 1FLzz/HfpvyhEq1dqxGlxIFsOAjEwyXZkG07us5fOXucExGFVw2Gr9dR9nsl+0tb xhAgL3E= DomainKey-Signature: a=rsa-sha1; c=nofws; d=zx2c4.com; h=from:to:cc :subject:date:message-id:in-reply-to:references; q=dns; s=mail; b= DWAS0IqIFJC44IAIFSRuCsohUiWHbcst/mQijs7AgtkpyPbbd4S3LAHI15I2evCK w/POOKk6NswuwnbeuqQFit9yFhmAVrL5dONTUTO3krOWeEjbaQ9YjVx7vMRip0ok UNnW6yLhVgiHjzS/dPhz4YQ64BbhxHVxXEWXFLzN/DI= Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTPSA id 551c28d1; TLS version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO; Thu, 22 Aug 2013 14:03:02 +0000 (UTC) From: "Jason A. Donenfeld" To: linux-acpi@vger.kernel.org, linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Cc: mjg@redhat.com, rjw@sisk.pl, len.brown@intel.com, dtor@insightbb.com, "Jason A. Donenfeld" Subject: [PATCH 3/3] thinkpad_acpi: Wire unused micmute LED to capslock Date: Thu, 22 Aug 2013 16:02:12 +0200 Message-Id: <1377180132-4933-3-git-send-email-Jason@zx2c4.com> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1377180132-4933-1-git-send-email-Jason@zx2c4.com> References: <1377180132-4933-1-git-send-email-Jason@zx2c4.com> Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Thinkpads with a micmute LED do not have a capslock LED. The micmute LED is currently not used by any piece of Linux kernel land or user land. It seems reasonable to hook it up to caps lock, at least by default, so users can have some degree of functionality. Signed-off-by: Jason A. Donenfeld --- drivers/platform/x86/thinkpad_acpi.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c index 33b23cb..708fdb8 100644 --- a/drivers/platform/x86/thinkpad_acpi.c +++ b/drivers/platform/x86/thinkpad_acpi.c @@ -5235,6 +5235,10 @@ static int __init tpacpi_init_led(unsigned int led) tpacpi_leds[led].led_classdev.name = tpacpi_led_names[led]; + /* Special case wiring micmute to caps-lock by default. */ + if (led == 14) + tpacpi_leds[led].led_classdev.default_trigger = "caps-lock"; + INIT_WORK(&tpacpi_leds[led].work, led_set_status_worker); rc = led_classdev_register(&tpacpi_pdev->dev,