From patchwork Fri Sep 25 15:08:51 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shraddha Barke X-Patchwork-Id: 7265831 Return-Path: X-Original-To: patchwork-linux-scsi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id E9C8DBEEC1 for ; Fri, 25 Sep 2015 15:09:18 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 1FDBE20B24 for ; Fri, 25 Sep 2015 15:09:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 39C8420B5F for ; Fri, 25 Sep 2015 15:09:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755041AbbIYPJO (ORCPT ); Fri, 25 Sep 2015 11:09:14 -0400 Received: from mail-pa0-f45.google.com ([209.85.220.45]:34377 "EHLO mail-pa0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753442AbbIYPJN (ORCPT ); Fri, 25 Sep 2015 11:09:13 -0400 Received: by padhy16 with SMTP id hy16so108388259pad.1 for ; Fri, 25 Sep 2015 08:09:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=n8F2ZUDlqu3kJWqh1hyf1UD+urVneJFkAZ6eRja2zaM=; b=idcvJXoeoMBnvwBTBEhMcJQ9Wlvf92FkVZegTmiWxugFe6r4ksje5uLSxPVP3R4Plw Pnu0ldzimm873hUxnutg34gsd6nnWHoNovXTyzWMVL04TL/RW+2jUcgD7/GjgCCg4VQM bp2R0ib1hbfz8e6XxNHRzQja8mN0PBJwXgIzYbi1ylQG4mOrMQPQNET8TcTyS2VpQ6ZP uSeqW8edLQO/N66gCxzT1h2A2sd6EEbR2XjkZeSWIDfloFDYJTDb0BXQBSio47wTvpwy dDX2Q0AiaIIF5hCPswfCE57W/vpx/dZkgSrhERE1aOP5Y3T9f23X9E7IwhMcIgQESP2k RQag== X-Received: by 10.66.236.129 with SMTP id uu1mr7886773pac.34.1443193753352; Fri, 25 Sep 2015 08:09:13 -0700 (PDT) Received: from shraddha-370R4E-370R4V-370R5E-3570RE-370R5V.bits-goa.ac.in ([103.225.100.51]) by smtp.gmail.com with ESMTPSA id gx11sm4446208pbd.82.2015.09.25.08.09.10 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 25 Sep 2015 08:09:12 -0700 (PDT) From: Shraddha Barke To: "James E.J. Bottomley" , Hannes Reinecke , Oliver Neukum Cc: linux-scsi@vger.kernel.org, Shraddha Barke Subject: [PATCH 4/4] Scsi: a100u2w.c: Use module_pci_driver Date: Fri, 25 Sep 2015 20:38:51 +0530 Message-Id: <1443193731-12587-4-git-send-email-shraddha.6596@gmail.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1443193731-12587-1-git-send-email-shraddha.6596@gmail.com> References: <1443193731-12587-1-git-send-email-shraddha.6596@gmail.com> X-Cyberoam-smtpxy-version: 1.0.6.3 X-Cyberoam-AV-Policy: default X-CTCH-PVer: 0000001 X-CTCH-Spam: Unknown X-CTCH-VOD: Unknown X-CTCH-Flags: 0 X-CTCH-RefID: str=0001.0A150209.56056398.0027, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-Score: 0.000 X-CTCH-ScoreCust: 0.000 X-CTCH-Rules: Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham 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 Use module_pci_driver for drivers whose init and exit functions only register and unregister respectively Signed-off-by: Shraddha Barke Reviewed-by: Hannes Reinecke --- drivers/scsi/a100u2w.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/scsi/a100u2w.c b/drivers/scsi/a100u2w.c index 8086bd0..5ef776c 100644 --- a/drivers/scsi/a100u2w.c +++ b/drivers/scsi/a100u2w.c @@ -1222,19 +1222,7 @@ static struct pci_driver inia100_pci_driver = { .remove = inia100_remove_one, }; -static int __init inia100_init(void) -{ - return pci_register_driver(&inia100_pci_driver); -} - -static void __exit inia100_exit(void) -{ - pci_unregister_driver(&inia100_pci_driver); -} - MODULE_DESCRIPTION("Initio A100U2W SCSI driver"); MODULE_AUTHOR("Initio Corporation"); MODULE_LICENSE("Dual BSD/GPL"); - -module_init(inia100_init); -module_exit(inia100_exit); +module_pci_driver(inia100_pci_driver);