From patchwork Mon Jul 16 10:32:22 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 10000 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 799D324024 for ; Mon, 16 Jul 2012 10:32:57 +0000 (UTC) Received: from mail-yx0-f180.google.com (mail-yx0-f180.google.com [209.85.213.180]) by fiordland.canonical.com (Postfix) with ESMTP id 422F6A18884 for ; Mon, 16 Jul 2012 10:32:57 +0000 (UTC) Received: by yenq6 with SMTP id q6so5189661yen.11 for ; Mon, 16 Jul 2012 03:32:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:x-gm-message-state; bh=I8JQtFYca6kcW2s7kK8Qt6DVNt6lrY771deq3jmFT68=; b=oYtxSEY2vd45Pz8tNTh3/lAHkgrYvC16pLMb0zuEPUL9s0xrruXlET29k2T9k5DdRQ ZXZ0EhXRMBRM6wJLF4Sv4useCfaJJqZkl3BM9KMg1pAUbeLZGc39sK+t1x+VUebP1lq8 qYGGuX4ASKPdrDDx3kJXl+z4HHesz0BDRYnB8mvcHPbh43rvIdqnM8/FssBbJvnt7hCR VwAILaTAp3SJkvCz0HksEu4HlLjauX0SzAOtWHOjQRTx9JcC3AGqAZVv4gTziCyBgva6 NhZIi0cS5A2cvA2VFL/wOdzTNLRBFzuWEMsIASZxeFX8klu4C9Hbesw19NKn7tbAOK4J 0QXA== Received: by 10.50.40.193 with SMTP id z1mr4914891igk.0.1342434776354; Mon, 16 Jul 2012 03:32:56 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.241.2 with SMTP id lc2csp6648ibb; Mon, 16 Jul 2012 03:32:55 -0700 (PDT) Received: by 10.66.9.2 with SMTP id v2mr21630651paa.65.1342434775155; Mon, 16 Jul 2012 03:32:55 -0700 (PDT) Received: from mail-pb0-f50.google.com (mail-pb0-f50.google.com [209.85.160.50]) by mx.google.com with ESMTPS id wf5si4387608pbc.287.2012.07.16.03.32.54 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 16 Jul 2012 03:32:55 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.160.50 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) client-ip=209.85.160.50; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.160.50 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) smtp.mail=sachin.kamat@linaro.org Received: by pbbrr4 with SMTP id rr4so11941114pbb.37 for ; Mon, 16 Jul 2012 03:32:54 -0700 (PDT) Received: by 10.68.221.106 with SMTP id qd10mr25883389pbc.42.1342434774840; Mon, 16 Jul 2012 03:32:54 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id hw6sm11649337pbc.73.2012.07.16.03.32.51 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 16 Jul 2012 03:32:54 -0700 (PDT) From: Sachin Kamat To: linux-mtd@lists.infradead.org Cc: dwmw2@infradead.org, David.Woodhouse@intel.com, ben-linux@fluff.org, sachin.kamat@linaro.org, patches@linaro.org Subject: [PATCH 1/6] mtd: s3c2410: Use module_platform_driver() Date: Mon, 16 Jul 2012 16:02:22 +0530 Message-Id: <1342434747-27622-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 X-Gm-Message-State: ALoCoQngarD7GrSyrMs91L+ZMTWuU36p5yZpBOUjtZCyYQbVGOCbdiJRMbi2wCXgOOk9YbuVw/TP This makes the code simpler by eliminating module_init() and module_exit(). Signed-off-by: Sachin Kamat --- drivers/mtd/nand/s3c2410.c | 15 +-------------- 1 files changed, 1 insertions(+), 14 deletions(-) diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c index 91121f3..8f9267f 100644 --- a/drivers/mtd/nand/s3c2410.c +++ b/drivers/mtd/nand/s3c2410.c @@ -1134,20 +1134,7 @@ static struct platform_driver s3c24xx_nand_driver = { }, }; -static int __init s3c2410_nand_init(void) -{ - printk("S3C24XX NAND Driver, (c) 2004 Simtec Electronics\n"); - - return platform_driver_register(&s3c24xx_nand_driver); -} - -static void __exit s3c2410_nand_exit(void) -{ - platform_driver_unregister(&s3c24xx_nand_driver); -} - -module_init(s3c2410_nand_init); -module_exit(s3c2410_nand_exit); +module_platform_driver(s3c24xx_nand_driver); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Ben Dooks ");