From patchwork Thu Sep 21 13:57:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Limonciello, Mario" X-Patchwork-Id: 9963999 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 0FDC36020C for ; Thu, 21 Sep 2017 13:58:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0C13629017 for ; Thu, 21 Sep 2017 13:58:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 00DBF29031; Thu, 21 Sep 2017 13:58:36 +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.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AC32029017 for ; Thu, 21 Sep 2017 13:58:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751629AbdIUN6W (ORCPT ); Thu, 21 Sep 2017 09:58:22 -0400 Received: from esa7.dell-outbound.iphmx.com ([68.232.153.96]:10728 "EHLO esa7.dell-outbound.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751606AbdIUN5b (ORCPT ); Thu, 21 Sep 2017 09:57:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=dell.com; i=@dell.com; q=dns/txt; s=smtpout; t=1506001785; x=1537537785; h=from:to:cc:subject:date:message-id; bh=MrKP28fideiPXYyA4y2HD+1Bex+rZ/GlUszZNLphT1Y=; b=YyxU/Wk+V9yjwyqSuZftgwGUvshJzt5Be8CuSfmR5vlF5BdSE2qNnWh5 YNBw+Uws2f9KvI9U3zeftwZvDW/vppj+mJM5U/VPc9nxw4ctrIwCK/mS/ fHW1oh4N/K7XW0ob9oRqSzlKKnSJNfKkOPx1Xs9BrpoOM/4qfxHj7ToSl Y=; Received: from esa2.dell-outbound2.iphmx.com ([68.232.153.202]) by esa7.dell-outbound.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Sep 2017 08:49:44 -0500 Received: from ausxipps310.us.dell.com ([143.166.148.211]) by esa2.dell-outbound2.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Sep 2017 19:56:09 +0600 X-LoopCount0: from 10.208.86.39 X-IronPort-AV: E=Sophos;i="5.42,425,1500958800"; d="scan'208";a="64188953" X-DLP: DLP_GlobalPCIDSS From: Mario Limonciello To: dvhart@infradead.org Cc: LKML , platform-driver-x86@vger.kernel.org, quasisec@google.com, pali.rohar@gmail.com, Mario Limonciello Subject: [PATCH 08/12] platform/x86: wmi: Cleanup exit routine in reverse order of init Date: Thu, 21 Sep 2017 08:57:13 -0500 Message-Id: <1181b0a5cebe331e044852f9bc1d385241e56d0e.1505999739.git.mario.limonciello@dell.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: References: In-Reply-To: References: Sender: platform-driver-x86-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: platform-driver-x86@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The initialize routine is: * class -> bus -> platform The exit routine is: * platform -> class -> bus Fix the exit routine to be: * platform -> bus -> class Signed-off-by: Mario Limonciello --- drivers/platform/x86/wmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 0765b1797d4c..077a9b7459ef 100644 --- a/drivers/platform/x86/wmi.c +++ b/drivers/platform/x86/wmi.c @@ -1264,8 +1264,8 @@ static int __init acpi_wmi_init(void) static void __exit acpi_wmi_exit(void) { platform_driver_unregister(&acpi_wmi_driver); - class_unregister(&wmi_bus_class); bus_unregister(&wmi_bus_type); + class_unregister(&wmi_bus_class); } subsys_initcall(acpi_wmi_init);