Received: by 2002:a05:7412:bb8d:b0:d7:7d3a:4fe2 with SMTP id js13csp780757rdb; Tue, 15 Aug 2023 11:39:33 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEbnxWj5GTA6qOvFykVo4Fkf/DW4aIHPjZVnmpBQzAPvRQmzRvcgiVzrfGvoqYZTtqBRuDN X-Received: by 2002:a17:902:ce8a:b0:1bc:7837:366a with SMTP id f10-20020a170902ce8a00b001bc7837366amr3901840plg.19.1692124772620; Tue, 15 Aug 2023 11:39:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692124772; cv=none; d=google.com; s=arc-20160816; b=oSbAzhEjewyDkFsOOv6dSsgxRFaVe6Ho5bntqg3RCesdHh/ZmPbDv1VYFCFSP2i4jV IlCAjUwADh1TfjRcJnHH3fBVFF49/A87d5nKmavvOWEW+q1WjzFmeIKvglL8n2wE5n1g PxZpRK0ziv1X+H2suQMkPwxzbKV5a6qW8iOBln+Y9oAUYTb5GRcQ0ZyHQWbsnfZuZTfU 2XE3ikGFeBYvLhhi+WWHuqMSY31o8i42F4ZpBm4wm942mXxQh8XjPMkpwsBYHW0UK9dp w7mp3D7PUO2YZUJeIVLPlaBRkRL9W9iNsESyjmEIcg3qMsz7mziZyO833TX9MiFV0frh XAEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=6pvHTeFloh5oFBR5AjCaF9pfbPOa2Y54Fva/kctH13E=; fh=2lzZHlgfO9Mcr72d4cNmgyvqzZI7zl8dmuVP6X0XXnE=; b=r8oWaLORcf/TzGskCZ2fKapDys/foMuSYyzBmdk8PWy1iZqGhLbMl3mMaSyi0QSCNn IM8MNJlgL91NbXHs1NHfG2ppzDXWc2crClCWnWuNHocg4pfbJGSQAaS1Z5BtomREpCQp GTbPIzlobRWLc9eQZ+ULYA9tuSgjsmQnwI1IxDkAxAL3paWF0yaXwpCdSh6hlxbmTSy+ Sp5IEaQ6SIJkVbNaQDMxBWzt7YaDl8i8ezHQKLNxn3Mk6w4zkjP0wNR8fRM91ZyZmIo6 QJdtAJ80E4DKxcnJW8sgG+BiuMrMYTA5FNbXSWDyOyftCJKxv0JvklMC4Fr0eDeulzO3 9vtw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u11-20020a170903124b00b001bb1504b696si10039700plh.4.2023.08.15.11.39.10; Tue, 15 Aug 2023 11:39:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235464AbjHOHzE (ORCPT + 54 others); Tue, 15 Aug 2023 03:55:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54894 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235457AbjHOHyl (ORCPT ); Tue, 15 Aug 2023 03:54:41 -0400 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6B6FADD for ; Tue, 15 Aug 2023 00:54:39 -0700 (PDT) Received: from kwepemi500012.china.huawei.com (unknown [172.30.72.55]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4RQ3PT0L8KzFqdC; Tue, 15 Aug 2023 15:51:41 +0800 (CST) Received: from huawei.com (10.90.53.73) by kwepemi500012.china.huawei.com (7.221.188.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Tue, 15 Aug 2023 15:54:37 +0800 From: Li Zetao To: CC: , Subject: [PATCH net-next] wlcore: sdio: Use module_sdio_driver macro to simplify the code Date: Tue, 15 Aug 2023 15:54:19 +0800 Message-ID: <20230815075419.1067635-1-lizetao1@huawei.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.90.53.73] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemi500012.china.huawei.com (7.221.188.12) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Use the module_sdio_driver macro to simplify the code, which is the same as declaring with module_init() and module_exit(). Signed-off-by: Li Zetao --- drivers/net/wireless/ti/wlcore/sdio.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/net/wireless/ti/wlcore/sdio.c b/drivers/net/wireless/ti/wlcore/sdio.c index cf8d909fa826..f0686635db46 100644 --- a/drivers/net/wireless/ti/wlcore/sdio.c +++ b/drivers/net/wireless/ti/wlcore/sdio.c @@ -442,18 +442,7 @@ static struct sdio_driver wl1271_sdio_driver = { #endif }; -static int __init wl1271_init(void) -{ - return sdio_register_driver(&wl1271_sdio_driver); -} - -static void __exit wl1271_exit(void) -{ - sdio_unregister_driver(&wl1271_sdio_driver); -} - -module_init(wl1271_init); -module_exit(wl1271_exit); +module_sdio_driver(wl1271_sdio_driver); module_param(dump, bool, 0600); MODULE_PARM_DESC(dump, "Enable sdio read/write dumps."); -- 2.34.1