From patchwork Mon Apr 27 12:27:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Ivan T. Ivanov" X-Patchwork-Id: 47613 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f70.google.com (mail-la0-f70.google.com [209.85.215.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 826B32121F for ; Mon, 27 Apr 2015 12:27:52 +0000 (UTC) Received: by laat2 with SMTP id t2sf25953146laa.2 for ; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=G3XnVcCElusx/7f4tJ54Z4h9obdMke1J+3PoRCuJmTU=; b=DFCkZCVqn4ngqZjhDYvzhVyCOf6ufVF5Jx2qEZ7a+HDGlBkikPzX5GNAtaqVIQhzAa We/55ylqMMh8KYni2A/q+06JgvGt12W8KY9dnW9PLb9sxlVKgkhQKUT6EPzN/U6C6RyW fwjV21gyn6JvRjUlGIpAhHODTpZs1eT7+UMQEE33SJx1TUYLeQfpjqsBDr3IaxdKvqxd yi6ZXoFfknc32SXq5yALdRf6VnI5IqDe0u02UjMcjMOwK3fo4f4SiF82ayI1Cpq404qo zZAgcw3VU0eLLXYnICrW057nhCipobN6K90CXdzMDBomZovFL3XXI+R+3Rl1pPDAQPcX qF7g== X-Gm-Message-State: ALoCoQnZd1SzdGAnfOnHUnaLIeZxecfsXFcFU2x8iACcKiLc6kt7IEQWQarJValMiaSVON+TxuXH X-Received: by 10.112.162.228 with SMTP id yd4mr7199802lbb.8.1430137671460; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.30.74 with SMTP id q10ls776168lah.35.gmail; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) X-Received: by 10.152.36.40 with SMTP id n8mr9899997laj.121.1430137671254; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) Received: from mail-la0-f41.google.com (mail-la0-f41.google.com. [209.85.215.41]) by mx.google.com with ESMTPS id oc2si14679967lbb.1.2015.04.27.05.27.51 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Apr 2015 05:27:51 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) client-ip=209.85.215.41; Received: by layy10 with SMTP id y10so78479355lay.0 for ; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) X-Received: by 10.112.29.36 with SMTP id g4mr10168898lbh.56.1430137671124; Mon, 27 Apr 2015 05:27:51 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.67.65 with SMTP id l1csp1245421lbt; Mon, 27 Apr 2015 05:27:50 -0700 (PDT) X-Received: by 10.68.240.40 with SMTP id vx8mr21554849pbc.27.1430137669241; Mon, 27 Apr 2015 05:27:49 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id fx4si29599568pbb.205.2015.04.27.05.27.47; Mon, 27 Apr 2015 05:27:49 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932648AbbD0M1o (ORCPT + 27 others); Mon, 27 Apr 2015 08:27:44 -0400 Received: from mail-wi0-f176.google.com ([209.85.212.176]:37509 "EHLO mail-wi0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932284AbbD0M1l (ORCPT ); Mon, 27 Apr 2015 08:27:41 -0400 Received: by widdi4 with SMTP id di4so87815262wid.0 for ; Mon, 27 Apr 2015 05:27:40 -0700 (PDT) X-Received: by 10.180.7.133 with SMTP id j5mr20435302wia.84.1430137659961; Mon, 27 Apr 2015 05:27:39 -0700 (PDT) Received: from mms-0439.wifi.mm-sol.com ([37.157.136.206]) by mx.google.com with ESMTPSA id vz8sm8346761wjc.27.2015.04.27.05.27.38 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 27 Apr 2015 05:27:39 -0700 (PDT) From: "Ivan T. Ivanov" To: Alan Stern Cc: Greg Kroah-Hartman , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Vivek Gautam Subject: [PATCH v2] Revert "usb: host: ehci-msm: Use devm_ioremap_resource instead of devm_ioremap" Date: Mon, 27 Apr 2015 15:27:36 +0300 Message-Id: <1430137656-4953-1-git-send-email-ivan.ivanov@linaro.org> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ivan.ivanov@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This reverts commit 70843f623b58 ("usb: host: ehci-msm: Use devm_ioremap_resource instead of devm_ioremap") and commit e507bf577e5a ("host: ehci-msm: remove duplicate check on resource"), because msm_otg and this driver are using same address space to access AHB mode and USB command registers. Cc: Vivek Gautam Signed-off-by: Ivan T. Ivanov --- Changes since v0: * Add note to patch description that also commit e507bf577e5a is reverted. drivers/usb/host/ehci-msm.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ diff --git a/drivers/usb/host/ehci-msm.c b/drivers/usb/host/ehci-msm.c index 9db74ca..275c92e 100644 --- a/drivers/usb/host/ehci-msm.c +++ b/drivers/usb/host/ehci-msm.c @@ -88,13 +88,20 @@ static int ehci_msm_probe(struct platform_device *pdev) } res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - hcd->regs = devm_ioremap_resource(&pdev->dev, res); - if (IS_ERR(hcd->regs)) { - ret = PTR_ERR(hcd->regs); + if (!res) { + dev_err(&pdev->dev, "Unable to get memory resource\n"); + ret = -ENODEV; goto put_hcd; } + hcd->rsrc_start = res->start; hcd->rsrc_len = resource_size(res); + hcd->regs = devm_ioremap(&pdev->dev, hcd->rsrc_start, hcd->rsrc_len); + if (!hcd->regs) { + dev_err(&pdev->dev, "ioremap failed\n"); + ret = -ENOMEM; + goto put_hcd; + } /* * OTG driver takes care of PHY initialization, clock management,