From patchwork Thu Oct 18 09:06:55 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Haojian Zhuang X-Patchwork-Id: 1608671 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id AF728DFB34 for ; Thu, 18 Oct 2012 09:08:30 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TOm3Y-0001NH-LZ; Thu, 18 Oct 2012 09:06:20 +0000 Received: from mail-da0-f49.google.com ([209.85.210.49]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1TOm3V-0001MV-HR for linux-arm-kernel@lists.infradead.org; Thu, 18 Oct 2012 09:06:18 +0000 Received: by mail-da0-f49.google.com with SMTP id q27so3508588daj.36 for ; Thu, 18 Oct 2012 02:06:14 -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:x-mailer; bh=zQyzB/HxYOB5tI8+BAEmV6DvXKris6g6iYok4ZkRclo=; b=RoNqFiAOJttZjFSsM16HWylrghoicODK8a4FqpDgUnbYw2QtFqMOw3cDpwokV+O3tU DLrlzIelBP4qBY5cHMEwXc9nNSi/bmItBlCjDBP9HgcnsU/khNtbvtCuE2zfqJcIxwAw yY1rqxv3PejFHcvdpDy41RyzIrcOqZacMCH+fAHBYzMy+OBHtGRe6ez6myRrawkf96YV su1Frf3B6krGbFN2Q47atj3OCE05el6mxLUbeHMrAi6AjCvGNC2G0a53wHXrqpqXDf6n ndWJqB1u5wH+wx0ZwiI3oWkQnrJKqAjm/C1G02iS1wl5FjDsXwGlDVBWY5OCiqxTozhN bYlA== Received: by 10.68.229.194 with SMTP id ss2mr64619080pbc.17.1350551174339; Thu, 18 Oct 2012 02:06:14 -0700 (PDT) Received: from localhost ([58.39.221.134]) by mx.google.com with ESMTPS id kr4sm13930087pbc.76.2012.10.18.02.06.07 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 18 Oct 2012 02:06:12 -0700 (PDT) From: Haojian Zhuang To: linux-arm-kernel@lists.infradead.org, arnd@arndb.de, linus.walleij@linaro.org, tony@atomide.com, devicetree-discuss@lists.ozlabs.org Subject: [PATCH 01/10] pinctrl: use postcore_initcall Date: Thu, 18 Oct 2012 17:06:55 +0800 Message-Id: <1350551224-12857-1-git-send-email-haojian.zhuang@gmail.com> X-Mailer: git-send-email 1.7.9.5 X-Spam-Note: CRM114 invocation failed X-Spam-Score: -2.7 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (haojian.zhuang[at]gmail.com) -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.210.49 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: Haojian Zhuang X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Since pins are configured in device driver, pinctrl driver should be loaded by those device driver. module_platform_driver() only declares pinctrl driver is in module_initcall privilege. Use postcore_initcall privilege instead. Signed-off-by: Haojian Zhuang --- drivers/pinctrl/pinctrl-single.c | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/drivers/pinctrl/pinctrl-single.c b/drivers/pinctrl/pinctrl-single.c index 76a4260..64d109a 100644 --- a/drivers/pinctrl/pinctrl-single.c +++ b/drivers/pinctrl/pinctrl-single.c @@ -980,7 +980,17 @@ static struct platform_driver pcs_driver = { }, }; -module_platform_driver(pcs_driver); +static int __init pcs_driver_init(void) +{ + return platform_driver_register(&pcs_driver); +} +postcore_initcall(pcs_driver_init); + +static void __exit pcs_driver_exit(void) +{ + platform_driver_unregister(&pcs_driver); +} +module_exit(pcs_driver_exit); MODULE_AUTHOR("Tony Lindgren "); MODULE_DESCRIPTION("One-register-per-pin type device tree based pinctrl driver");