From patchwork Wed May 8 13:29:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 16798 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ye0-f198.google.com (mail-ye0-f198.google.com [209.85.213.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C7B07238FB for ; Wed, 8 May 2013 13:30:38 +0000 (UTC) Received: by mail-ye0-f198.google.com with SMTP id m13sf1981352yen.9 for ; Wed, 08 May 2013 06:30:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:x-beenthere:x-received:received-spf :x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe; bh=Qj+kNMgRVRhI+xltTkWGgDaq5xJ/7krLAQpuc0EYQmU=; b=TpIQN/Po0N9iO80xWIXepj/7x6zRs4cBkyJX3+dQW4ZdRdluAHOqJ4H+k02nQV/wia 1S4/hW5JlbeiXodXHjE+nnyOKtWNXDf9sk7R98Mxt3dDG4CjsPFgJ8DB71W1JlM65nlF E7EQO+tSmYpwkJvcJq25Mb1Ei3dtTD8CkxvZA7bDis/NRy1aYXXva4kN4dGWuyGVg42x y8SnHTzrXMgFLNwTMe5Ifwp+UEB65MBzVlCclY6oWA2WJ1h3QIDR9U3Ab5vjZ+Xmstla O3XztGtYcMDQyIf4fzywkskTnOBliQ4uOkc/yCdp80Lkvznuf4k+ZW2tKhF7J0K2zpcD aOTQ== X-Received: by 10.58.246.225 with SMTP id xz1mr4208370vec.28.1368019817664; Wed, 08 May 2013 06:30:17 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.25.18 with SMTP id y18ls871054qef.5.gmail; Wed, 08 May 2013 06:30:17 -0700 (PDT) X-Received: by 10.52.169.231 with SMTP id ah7mr3796940vdc.110.1368019817358; Wed, 08 May 2013 06:30:17 -0700 (PDT) Received: from mail-ve0-x22e.google.com (mail-ve0-x22e.google.com [2607:f8b0:400c:c01::22e]) by mx.google.com with ESMTPS id t8si15050441vcz.74.2013.05.08.06.30.17 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 08 May 2013 06:30:17 -0700 (PDT) Received-SPF: neutral (google.com: 2607:f8b0:400c:c01::22e is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=2607:f8b0:400c:c01::22e; Received: by mail-ve0-f174.google.com with SMTP id pb11so1699623veb.19 for ; Wed, 08 May 2013 06:30:17 -0700 (PDT) X-Received: by 10.52.175.200 with SMTP id cc8mr3839968vdc.94.1368019817214; Wed, 08 May 2013 06:30:17 -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.58.127.98 with SMTP id nf2csp6877veb; Wed, 8 May 2013 06:30:16 -0700 (PDT) X-Received: by 10.194.133.198 with SMTP id pe6mr10968633wjb.9.1368019816272; Wed, 08 May 2013 06:30:16 -0700 (PDT) Received: from mail-wi0-x22d.google.com (mail-wi0-x22d.google.com [2a00:1450:400c:c05::22d]) by mx.google.com with ESMTPS id l7si9429462wjr.163.2013.05.08.06.30.15 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 08 May 2013 06:30:16 -0700 (PDT) Received-SPF: neutral (google.com: 2a00:1450:400c:c05::22d is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=2a00:1450:400c:c05::22d; Received: by mail-wi0-f173.google.com with SMTP id ey16so5047429wid.0 for ; Wed, 08 May 2013 06:30:15 -0700 (PDT) X-Received: by 10.194.10.129 with SMTP id i1mr1904810wjb.21.1368019815557; Wed, 08 May 2013 06:30:15 -0700 (PDT) Received: from localhost.localdomain (cpc34-aztw25-2-0-cust250.18-1.cable.virginmedia.com. [86.16.136.251]) by mx.google.com with ESMTPSA id h8sm7063221wiz.9.2013.05.08.06.30.13 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 08 May 2013 06:30:14 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: arnd@arndb.de, linus.walleij@stericsson.com, srinidhi.kasagar@stericsson.com, Lee Jones Subject: [PATCH 7/9] pinctrl: abx500: Specify failed sub-driver by ID instead of driver_data Date: Wed, 8 May 2013 14:29:07 +0100 Message-Id: <1368019749-19455-8-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1368019749-19455-1-git-send-email-lee.jones@linaro.org> References: <1368019749-19455-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQnlccKPHtAstA81YNVXfhEmwlS3YXdASsC5kW7Ea7zB9DBzS0z+bVC3plfXVocaF5IYrcPd X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 2607:f8b0:400c:c01::22e 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: , If a sub-driver has not been specified correctly, there is a good chance that plat_id is NULL, hence using an attribute of plat_id in the error message is likely to not only fail the driver but Oops the kernel. Use the failed ID instead. Signed-off-by: Lee Jones --- drivers/pinctrl/pinctrl-abx500.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-abx500.c b/drivers/pinctrl/pinctrl-abx500.c index aa17f75..2a2a9df 100644 --- a/drivers/pinctrl/pinctrl-abx500.c +++ b/drivers/pinctrl/pinctrl-abx500.c @@ -900,8 +900,7 @@ static int abx500_gpio_probe(struct platform_device *pdev) abx500_pinctrl_ab8505_init(&pct->soc); break; default: - dev_err(&pdev->dev, "Unsupported pinctrl sub driver (%d)\n", - (int) platid->driver_data); + dev_err(&pdev->dev, "Unsupported pinctrl sub driver (%d)\n", id); mutex_destroy(&pct->lock); return -EINVAL; }