From patchwork Mon Jun 11 19:35:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brian Norris X-Patchwork-Id: 10458711 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 A2F426020F for ; Mon, 11 Jun 2018 19:36:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9197C2859A for ; Mon, 11 Jun 2018 19:36:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 86377285A0; Mon, 11 Jun 2018 19:36:24 +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=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, MAILING_LIST_MULTI, TVD_SPACE_RATIO autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 327EE2859A for ; Mon, 11 Jun 2018 19:36:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=aOgFnXfDDkTCyYW7oFglgK+LHQgiv629b3uu0Hi2wcE=; b=Iy/ sZN4HXZcMP4ZvwRMdeeN/qJwUfClzBGmgkZaQYbKCc8QF+juqoRSpZCGcB/9kpqmqFlyk4Zzx1b5n bJGjHeOtT8MPwvvPd5qgNuwyD/nhKyn4NGYpawSBiudBoibFO6cp6RIohMPIcaioTGStqKbFUY/kY NaKorrvsBj1mW+jtYiMhMcm6iwMj38uCiJDE6Z3xZAsXmcIFnoxyatoWdfki4ccmbNKM3iLqfn51i gY3ak0zO68c1ZBYsg0KSVMfxewOdSIKRZi1FXJ8vUywWC6Ikit+NYVPkJ9ELt4XGVCGyId+a7gkFF ronHNircsMoUV2HvzUVDCqmJp06fPKA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fSSbu-0004Yz-LT; Mon, 11 Jun 2018 19:36:14 +0000 Received: from mail-pf0-x244.google.com ([2607:f8b0:400e:c00::244]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fSSbi-0004PL-BX for ath10k@lists.infradead.org; Mon, 11 Jun 2018 19:36:04 +0000 Received: by mail-pf0-x244.google.com with SMTP id a12-v6so10775724pfi.3 for ; Mon, 11 Jun 2018 12:35:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id; bh=z82AsbSiTvOBPXaS1jqrM3cx1/5k3cw9Ov4Z74GZlt8=; b=BfJAIUoXAAkckAru1aHcNp43oEEeijV0PPqrr7smJyMNTMl+Sa7c1Ym7PNtVdhWX9b rs+jFvly7n3FGxbjTfqE1PDMJu+uO9UFSzR1OL26sig67DWZZPp10gfA0R4cGnNBgB+q cKNwcc6WrTkUMZeXPABhep6+sZauOpmHkq+uI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=z82AsbSiTvOBPXaS1jqrM3cx1/5k3cw9Ov4Z74GZlt8=; b=os4i9fB+9Qq8bp8W2LR/jviQuSvEAp2+qwlSUAguRmYq0JfYJi6T83l53vLDJ8r36m TwDmpG6hbr0+xl2NvvhnSUPzGmQ70f6ZBp3j4dIPGaqix/7cvyJ8+fqG+M2qViWhRHRD uhgbLZpAg7xkWHpZbe3WLx6gpw/Xm7jcmPSbw7GoY2FQL2+VfZktFMWnEdaVxOPTAE2X Zl7+VcnnIA80PAJJFWH9JdN40DtHAHdek4HPzh52yMM6B/k6UdyjBPIIlmuFWOi4Wdrm c/y2zN+zAm6TvT+UHDyK4lXcnT44qbj5Bn98U60DO02nDRm77qFRQpE/RoApNa4Pr9V0 ra9g== X-Gm-Message-State: APt69E3/rVWB2/Y0S1pQrI69rg1M8j2n9zFG6Go1StZAWbzWntEx/0wX qj1toua4nXTpfsv720rWfEEs7A== X-Google-Smtp-Source: ADUXVKLWm1hd62nr5nF/HNxaGMuvipr7VcMS8FeZFOsaODQSsE+KVYS0wZWbkOezkQsEGJfw1t5lUQ== X-Received: by 2002:a62:4e07:: with SMTP id c7-v6mr484169pfb.149.1528745750389; Mon, 11 Jun 2018 12:35:50 -0700 (PDT) Received: from ban.mtv.corp.google.com ([2620:0:1000:1501:bc2f:3082:9938:5d41]) by smtp.gmail.com with ESMTPSA id y2-v6sm26734221pfk.82.2018.06.11.12.35.48 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 11 Jun 2018 12:35:48 -0700 (PDT) From: Brian Norris To: Kalle Valo Subject: [PATCH] ath10k: snoc: use module_platform_driver() macro Date: Mon, 11 Jun 2018 12:35:40 -0700 Message-Id: <20180611193540.190255-1-briannorris@chromium.org> X-Mailer: git-send-email 2.18.0.rc1.242.g61856ae69a-goog X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180611_123602_419379_1D6EC2CB X-CRM114-Status: UNSURE ( 8.21 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Brian Norris , Govind Singh , linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, ath10k@lists.infradead.org MIME-Version: 1.0 Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP ath10k_snoc_init()/ath10k_snoc_exit() don't add much value; module_platform_driver() can remove the boilerplate. Signed-off-by: Brian Norris --- drivers/net/wireless/ath/ath10k/snoc.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/snoc.c b/drivers/net/wireless/ath/ath10k/snoc.c index a3a7042fe13a..ee74e0060504 100644 --- a/drivers/net/wireless/ath/ath10k/snoc.c +++ b/drivers/net/wireless/ath/ath10k/snoc.c @@ -1388,25 +1388,7 @@ static struct platform_driver ath10k_snoc_driver = { .of_match_table = ath10k_snoc_dt_match, }, }; - -static int __init ath10k_snoc_init(void) -{ - int ret; - - ret = platform_driver_register(&ath10k_snoc_driver); - if (ret) - pr_err("failed to register ath10k snoc driver: %d\n", - ret); - - return ret; -} -module_init(ath10k_snoc_init); - -static void __exit ath10k_snoc_exit(void) -{ - platform_driver_unregister(&ath10k_snoc_driver); -} -module_exit(ath10k_snoc_exit); +module_platform_driver(ath10k_snoc_driver); MODULE_AUTHOR("Qualcomm"); MODULE_LICENSE("Dual BSD/GPL");