From patchwork Wed Oct 19 13:33:28 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Winkler, Tomas" X-Patchwork-Id: 9384577 X-Patchwork-Delegate: sameo@linux.intel.com 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 6102E60762 for ; Wed, 19 Oct 2016 15:41:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5428527EED for ; Wed, 19 Oct 2016 15:41:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 47B4328C65; Wed, 19 Oct 2016 15:41:50 +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.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI 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 0DA7D27EED for ; Wed, 19 Oct 2016 15:41:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S943768AbcJSPBA (ORCPT ); Wed, 19 Oct 2016 11:01:00 -0400 Received: from mga03.intel.com ([134.134.136.65]:55827 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S943765AbcJSPA6 (ORCPT ); Wed, 19 Oct 2016 11:00:58 -0400 Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga103.jf.intel.com with ESMTP; 19 Oct 2016 06:35:39 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,514,1473145200"; d="scan'208";a="21298685" Received: from twinkler-lnx.jer.intel.com ([10.12.87.167]) by fmsmga005.fm.intel.com with ESMTP; 19 Oct 2016 06:35:36 -0700 From: Tomas Winkler To: Greg Kroah-Hartman , Aloisio Almeida Jr , Samuel Ortiz , Wim Van Sebroeck , Guenter Roeck Cc: Alexander Usyskin , linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org, linux-watchdog@vger.kernel.org, Tomas Winkler Subject: [char-misc-next 2/5] watchdog: mei_wdt: use module_mei_cl_driver macro Date: Wed, 19 Oct 2016 16:33:28 +0300 Message-Id: <1476884011-20645-3-git-send-email-tomas.winkler@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1476884011-20645-1-git-send-email-tomas.winkler@intel.com> References: <1476884011-20645-1-git-send-email-tomas.winkler@intel.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Replace boilerplate driver registration with module_mei_cl_driver macro. Signed-off-by: Tomas Winkler Acked-by: Guenter Roeck --- drivers/watchdog/mei_wdt.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/drivers/watchdog/mei_wdt.c b/drivers/watchdog/mei_wdt.c index 630bd189f167..116be477c8fd 100644 --- a/drivers/watchdog/mei_wdt.c +++ b/drivers/watchdog/mei_wdt.c @@ -699,25 +699,7 @@ static struct mei_cl_driver mei_wdt_driver = { .remove = mei_wdt_remove, }; -static int __init mei_wdt_init(void) -{ - int ret; - - ret = mei_cldev_driver_register(&mei_wdt_driver); - if (ret) { - pr_err(KBUILD_MODNAME ": module registration failed\n"); - return ret; - } - return 0; -} - -static void __exit mei_wdt_exit(void) -{ - mei_cldev_driver_unregister(&mei_wdt_driver); -} - -module_init(mei_wdt_init); -module_exit(mei_wdt_exit); +module_mei_cl_driver(mei_wdt_driver); MODULE_AUTHOR("Intel Corporation"); MODULE_LICENSE("GPL");