From patchwork Sun Sep 29 05:32:05 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 20687 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vb0-f72.google.com (mail-vb0-f72.google.com [209.85.212.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 86E6324687 for ; Sun, 29 Sep 2013 05:41:57 +0000 (UTC) Received: by mail-vb0-f72.google.com with SMTP id f12sf3936679vbg.7 for ; Sat, 28 Sep 2013 22:41:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=Uh8u05Fr3TApMUv1PPMsID874fjKHlgGsMWEzUeXXb0=; b=KHQL+J5oOUlS8IfivzUsHB3N1J9fK89O3xbG7+Vn7Dm/u4eDTYrLRVM7nZPZm6UKyp bspn8RLm7p94Op25n7Oq9JV7GjtjPfhvpgk1Q5LMIf7xbse6j48OFBAkG1qmqGRR3shQ zA877QcZLaC8Vi/9qV6Hwgu0pK0JaHzmfca2dhdxJbwGbGYhZU1+QAigjttJc/sxTIpj QJtKfq2tCnExPVSoxM3a48dWaABj9j9Fm5nnWc0q0GJVxrsFOq3Dz66muNMNXVHBeSq0 3h7fkLKmSJboy0YdkX/1jRVksxv4dhiluTV5rcvO2i1b1hpCsHiMgX7B22eydnw966HT 2CfQ== X-Received: by 10.224.93.19 with SMTP id t19mr4924150qam.3.1380433317377; Sat, 28 Sep 2013 22:41:57 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.39.163 with SMTP id q3ls1763280qek.31.gmail; Sat, 28 Sep 2013 22:41:57 -0700 (PDT) X-Received: by 10.52.65.136 with SMTP id x8mr13140581vds.23.1380433317299; Sat, 28 Sep 2013 22:41:57 -0700 (PDT) Received: from mail-vc0-f177.google.com (mail-vc0-f177.google.com [209.85.220.177]) by mx.google.com with ESMTPS id dp7si4153644ved.149.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 28 Sep 2013 22:41:57 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.177 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.177; Received: by mail-vc0-f177.google.com with SMTP id hv10so2891871vcb.22 for ; Sat, 28 Sep 2013 22:41:27 -0700 (PDT) X-Gm-Message-State: ALoCoQl8U61Fhe7iG7oiiEJQaq3b7xuirriptWQIAzE2b9KFb0ASirXEdNu2AGP7Y8d2FNTYFQwE X-Received: by 10.58.118.130 with SMTP id km2mr15267261veb.0.1380433287191; Sat, 28 Sep 2013 22:41:27 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp39642vcz; Sat, 28 Sep 2013 22:41:26 -0700 (PDT) X-Received: by 10.68.217.196 with SMTP id pa4mr16563770pbc.117.1380433286257; Sat, 28 Sep 2013 22:41:26 -0700 (PDT) Received: from hanjun-Latitude-D630.domain ([218.17.215.175]) by mx.google.com with ESMTPS id it5si13640865pbc.335.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 28 Sep 2013 22:41:26 -0700 (PDT) Received-SPF: neutral (google.com: 218.17.215.175 is neither permitted nor denied by best guess record for domain of hanjun@hanjun-latitude-d630.domain) client-ip=218.17.215.175; Received: from hanjun-Latitude-D630 (localhost [127.0.0.1]) by hanjun-Latitude-D630.domain (8.14.4/8.14.4/Debian-2ubuntu2) with ESMTP id r8T5e5rw007345; Sun, 29 Sep 2013 13:40:05 +0800 Received: (from hanjun@localhost) by hanjun-Latitude-D630 (8.14.4/8.14.4/Submit) id r8T5e5Nv007325; Sun, 29 Sep 2013 13:40:05 +0800 From: Hanjun Guo To: Tomi Valkeinen , Jean-Christophe Plagniol-Villard Cc: linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org, patches@linaro.org, linaro-kernel@lists.linaro.org, linaro-acpi@lists.linaro.org, Hanjun Guo Subject: [PATCH 05/10] Video / da8xx-fb: Use module_platform_driver() to simplify code Date: Sun, 29 Sep 2013 13:32:05 +0800 Message-Id: <1380432730-7263-6-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1380432730-7263-1-git-send-email-hanjun.guo@linaro.org> References: <1380432730-7263-1-git-send-email-hanjun.guo@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: hanjun.guo@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.177 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Convert to module_platform_driver() to simplify code. Signed-off-by: Hanjun Guo --- drivers/video/da8xx-fb.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/video/da8xx-fb.c b/drivers/video/da8xx-fb.c index e030e17..dd41512 100644 --- a/drivers/video/da8xx-fb.c +++ b/drivers/video/da8xx-fb.c @@ -1663,19 +1663,7 @@ static struct platform_driver da8xx_fb_driver = { .owner = THIS_MODULE, }, }; - -static int __init da8xx_fb_init(void) -{ - return platform_driver_register(&da8xx_fb_driver); -} - -static void __exit da8xx_fb_cleanup(void) -{ - platform_driver_unregister(&da8xx_fb_driver); -} - -module_init(da8xx_fb_init); -module_exit(da8xx_fb_cleanup); +module_platform_driver(da8xx_fb_driver); MODULE_DESCRIPTION("Framebuffer driver for TI da8xx/omap-l1xx"); MODULE_AUTHOR("Texas Instruments");