From patchwork Fri Jun 11 08:03:24 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: dingsenjie@163.com X-Patchwork-Id: 1491972 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ozlabs.org (client-ip=2404:9400:2:0:216:3eff:fee1:b9f1; helo=lists.ozlabs.org; envelope-from=linux-fsi-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=WHROsHUq; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2404:9400:2:0:216:3eff:fee1:b9f1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4G3wVD5vbjz9sTD for ; Tue, 15 Jun 2021 14:35:32 +1000 (AEST) Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4G3wVF32p7z302c for ; Tue, 15 Jun 2021 14:35:33 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=WHROsHUq; dkim-atps=neutral X-Original-To: linux-fsi@lists.ozlabs.org Delivered-To: linux-fsi@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=163.com (client-ip=220.181.12.14; helo=m12-14.163.com; envelope-from=dingsenjie@163.com; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=WHROsHUq; dkim-atps=neutral X-Greylist: delayed 611 seconds by postgrey-1.36 at boromir; Fri, 11 Jun 2021 18:04:36 AEST Received: from m12-14.163.com (m12-14.163.com [220.181.12.14]) by lists.ozlabs.org (Postfix) with ESMTP id 4G1YKJ3HbKz2xg1 for ; Fri, 11 Jun 2021 18:04:34 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version; bh=vGBxM T1PNez76gx44N0IB18IfZDeVXPhMCJ7xA7RwuE=; b=WHROsHUqpy9+9VaGkygWh 0rZ8BLHPfSdDvJxVTYvdfG53LlxunCCyf7hzxnsu+MqpXrPGw8Wu1KyeoxepIGo2 rkLKyzk9CftKwdjvPlXphUl11GKieE46AZdZx75n3NhY0umHI/zVW42RT+E1lKo6 pe7ZwxqAIobIiLChNmkUlY= Received: from COOL-20201222LC.ccdomain.com (unknown [218.94.48.178]) by smtp10 (Coremail) with SMTP id DsCowABXWlL1GMNgulm1OA--.30888S2; Fri, 11 Jun 2021 16:04:06 +0800 (CST) From: dingsenjie@163.com To: jk@ozlabs.org, joel@jms.id.au, alistair@popple.id.au, eajames@linux.ibm.com Subject: [PATCH] fsi: fsi-sbefifo: Use module_fsi_driver to simplify the code Date: Fri, 11 Jun 2021 16:03:24 +0800 Message-Id: <20210611080324.60008-1-dingsenjie@163.com> X-Mailer: git-send-email 2.21.0.windows.1 MIME-Version: 1.0 X-CM-TRANSID: DsCowABXWlL1GMNgulm1OA--.30888S2 X-Coremail-Antispam: 1Uf129KBjvdXoWrZw47Ar1xKw13CF13WF1fCrg_yoWDJrgEka sYv3Z7GrW7WFy7G39Iqw4fZr92qFy8uFs3XF1Sqa98Kw17Zw4rAa4jgrW3tw4UWr4rAa9r ArsxCF1Fyr1xZjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7IU0hmRUUUUUU== X-Originating-IP: [218.94.48.178] X-CM-SenderInfo: 5glqw25hqmxvi6rwjhhfrp/xtbBRRauyFPAMYa0BQAAsg X-Mailman-Approved-At: Tue, 15 Jun 2021 14:35:30 +1000 X-BeenThere: linux-fsi@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: dingsenjie , linux-kernel@vger.kernel.org, linux-fsi@lists.ozlabs.org Errors-To: linux-fsi-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "linux-fsi" From: dingsenjie Simplify the code by using module_fsi_driver macro. Signed-off-by: dingsenjie --- drivers/fsi/fsi-sbefifo.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/fsi/fsi-sbefifo.c b/drivers/fsi/fsi-sbefifo.c index bfd5e5d..4ada65aa 100644 --- a/drivers/fsi/fsi-sbefifo.c +++ b/drivers/fsi/fsi-sbefifo.c @@ -1046,18 +1046,7 @@ static int sbefifo_remove(struct device *dev) } }; -static int sbefifo_init(void) -{ - return fsi_driver_register(&sbefifo_drv); -} - -static void sbefifo_exit(void) -{ - fsi_driver_unregister(&sbefifo_drv); -} - -module_init(sbefifo_init); -module_exit(sbefifo_exit); +module_fsi_driver(sbefifo_drv); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Brad Bishop "); MODULE_AUTHOR("Eddie James ");