From patchwork Thu Dec 8 12:36:17 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TWljaGHFgiBLxJlwaWXFhA==?= X-Patchwork-Id: 9468017 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 E780C60586 for ; Fri, 9 Dec 2016 11:58:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D9677285DE for ; Fri, 9 Dec 2016 11:58:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CDE80285F7; Fri, 9 Dec 2016 11:58:05 +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=-1.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_NONE,T_DKIM_INVALID autolearn=no version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F237F285DE for ; Fri, 9 Dec 2016 11:58:04 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 8510C267778; Fri, 9 Dec 2016 12:58:03 +0100 (CET) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 672BE266DA6; Fri, 9 Dec 2016 12:55:45 +0100 (CET) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 87E6626745D; Thu, 8 Dec 2016 13:37:17 +0100 (CET) Received: from mail-wj0-f196.google.com (mail-wj0-f196.google.com [209.85.210.196]) by alsa0.perex.cz (Postfix) with ESMTP id 9587026745C for ; Thu, 8 Dec 2016 13:37:13 +0100 (CET) Received: by mail-wj0-f196.google.com with SMTP id xy5so54264193wjc.1 for ; Thu, 08 Dec 2016 04:37:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kempniu.pl; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=sR9PXNkUVxocyXiJ1uD5uX9TsFHEQJuQ7rvIbKCQA+c=; b=r/5J/hKGXAHPrJ04DkVYllMcWtwkkWxBG1aI2HnQ8RlJq3iEcP1gbS/kncA6cPErkh H+0ABrpYCHwiknH7x7Ws9ANx0naKnSljXRpsz+Q4Jx4BNl9fYKABQTWAKln/iOJ3cPBc JpoZ/n2NROS6RKMsRPv8rskApKcmyLBxQEwVc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=sR9PXNkUVxocyXiJ1uD5uX9TsFHEQJuQ7rvIbKCQA+c=; b=cfbBBqwCeef+5K2S+hMJZfZK+XIpX8/LCMOhraNUUABhEDsWMnIDsPgLTWVa4Njqmy DVaQ3ExeilZBPWQxsic/YVhYPhH96e6QergWGMjOPgT96/1EwyByEHmidYlP/zXOAB8v dIEgexWG1NXunUX1HxiegZf7vaHbI6xsD1CtTDzJQLapmPTo8yAQRrXJT+HAo7jg+KyO PyDKcJZZoKlzUc+7RlN7qciHJB9AbJd7kN1bpCy0yFXnOS4/377gMlEzOf5buO9Ch9+Q qrf04JG39KYFKcw8J+VvUe7yPRCeQC6GH/DGmtT1ltQcZTbVZJ+tlHkTEQWs2mSze3BJ vzWA== X-Gm-Message-State: AKaTC01oJ30zfm4lTGNJv0WSkd1YZpZuCggaLG1XGSQNYJ5qvSkVhm5AwayWqQWsq1SskQ== X-Received: by 10.194.121.6 with SMTP id lg6mr74576647wjb.105.1481200632747; Thu, 08 Dec 2016 04:37:12 -0800 (PST) Received: from kmp-mobile.hq.kempniu.pl (kmp-mobile.hq.kempniu.pl. [2001:6a0:200:83b0::2d90]) by smtp.googlemail.com with ESMTPSA id a13sm15095293wma.18.2016.12.08.04.37.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 08 Dec 2016 04:37:12 -0800 (PST) From: =?UTF-8?q?Micha=C5=82=20K=C4=99pie=C5=84?= To: Richard Purdie , Jacek Anaszewski , Matthew Garrett , =?UTF-8?q?Pali=20Roh=C3=A1r?= , Darren Hart , Jaroslav Kysela , Takashi Iwai Date: Thu, 8 Dec 2016 13:36:17 +0100 Message-Id: <20161208123618.28603-7-kernel@kempniu.pl> X-Mailer: git-send-email 2.10.2 In-Reply-To: <20161208123618.28603-1-kernel@kempniu.pl> References: <20161208123618.28603-1-kernel@kempniu.pl> MIME-Version: 1.0 X-Mailman-Approved-At: Fri, 09 Dec 2016 10:19:33 +0100 Cc: alsa-devel@alsa-project.org, Louis Davis , linux-kernel@vger.kernel.org, Bob Rodgers , platform-driver-x86@vger.kernel.org, Hui Wang , Alex Hung , Jim Dailey , linux-leds@vger.kernel.org Subject: [alsa-devel] [PATCH 6/7] dell-led: remove code related to mic mute LED X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP With dell_micmute_led_set() moved to drivers/platform/x86/dell-laptop.c, all remnants of the mic mute LED handling code can be removed from drivers/leds/dell-led.c, restoring it back to the state it was in before db6d8cc ("dell-led: add mic mute led interface"). Signed-off-by: Michał Kępień --- drivers/leds/Kconfig | 1 - drivers/leds/dell-led.c | 25 +++++++------------------ 2 files changed, 7 insertions(+), 19 deletions(-) diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index c621cbb..f29b869 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig @@ -458,7 +458,6 @@ config LEDS_DELL_NETBOOKS tristate "External LED on Dell Business Netbooks" depends on LEDS_CLASS depends on X86 && ACPI_WMI - depends on DELL_SMBIOS help This adds support for the Latitude 2100 and similar notebooks that have an external LED. diff --git a/drivers/leds/dell-led.c b/drivers/leds/dell-led.c index c9cc36a..e5c5738 100644 --- a/drivers/leds/dell-led.c +++ b/drivers/leds/dell-led.c @@ -15,15 +15,12 @@ #include #include #include -#include -#include "../platform/x86/dell-smbios.h" MODULE_AUTHOR("Louis Davis/Jim Dailey"); MODULE_DESCRIPTION("Dell LED Control Driver"); MODULE_LICENSE("GPL"); #define DELL_LED_BIOS_GUID "F6E4FE6E-909D-47cb-8BAB-C9F6F2F8D396" -#define DELL_APP_GUID "A80593CE-A997-11DA-B012-B622A1EF5492" MODULE_ALIAS("wmi:" DELL_LED_BIOS_GUID); /* Error Result Codes: */ @@ -184,29 +181,21 @@ static int __init dell_led_init(void) { int error = 0; - if (!wmi_has_guid(DELL_LED_BIOS_GUID) && !wmi_has_guid(DELL_APP_GUID)) + if (!wmi_has_guid(DELL_LED_BIOS_GUID)) return -ENODEV; - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error != 0) - return -ENODEV; - - error = led_classdev_register(NULL, &dell_led); - } + error = led_off(); + if (error != 0) + return -ENODEV; - return error; + return led_classdev_register(NULL, &dell_led); } static void __exit dell_led_exit(void) { - int error = 0; + led_classdev_unregister(&dell_led); - if (wmi_has_guid(DELL_LED_BIOS_GUID)) { - error = led_off(); - if (error == 0) - led_classdev_unregister(&dell_led); - } + led_off(); } module_init(dell_led_init);