From patchwork Fri May 26 20:21:37 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Suman Anna X-Patchwork-Id: 9751119 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0E5BE60246 for ; Fri, 26 May 2017 20:23:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0007027F90 for ; Fri, 26 May 2017 20:23:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E861328347; Fri, 26 May 2017 20:23:18 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 75D4527F90 for ; Fri, 26 May 2017 20:23:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=FCnQ3HEO9+aU6OJ8urVRPhQsr3M0U1PQCd8m6Wy94ck=; b=Cfr7l53kWbG0K4 6StUClEW6oqRZgfGiI8Wf8QmBAzN5mM0NmaDg6/5K2TyIAryHKJtBh2EIkXy/WRZT2zCfm2U3F8J9 ldiZErtZd8U5dJ3VG+TPukcJbTWX+vRy6qcx4o6T6FAsUTwbGUD8acKeg5O/aLtdlKQ++7KE+bSnG 6AtEc5xFRBhS508+6PW2I3RGejXDK++UhoSu/j2MQiaSM0ZBMrhkFrcC1inppYpj24xT3g0QOdlf6 DR3nG9+WTdimDaBrWLgoGTxzBw4dPgfM/7Z2va2md6iV+6C4n7JyMZnibqRG7jObPUuPlEoIjweS4 HYbMAPSxivUffR0dPMZA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dELlV-0004fz-Gb; Fri, 26 May 2017 20:23:17 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dELlS-0004fK-Ed for linux-arm-kernel@bombadil.infradead.org; Fri, 26 May 2017 20:23:14 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Type:MIME-Version:References: In-Reply-To:Message-ID:Date:Subject:CC:To:From:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=Fm28GvWW/KQ7XS9Lnznjvch2hRoeUBL+EMfd42wf9Ug=; b=Xtl6gZYMfi80kjpJKOcL5sEIU jlDO6+yHz+sGCS2Ddh+KyyHGuE95A1TeSunwOYedEVFocboQChmhmvsObE8sXWBmR0W3sQroABlOf BBsoAsZj5QNxoMJySw1so8MZ9fd6NJK0Z6Qdpfc1aFKRSMPWqK3ukKgL5alU0FlQMgLegVcgj82S1 x12KX+ZAl42Lygs8hnysZoGjakG9VzaaPGt14dQuw/KsQrIDS+zsELTFsKw4Fqyvkm+uin3S60UpE 3JUcFDo8sIzxrOkjSkkb+b6GoEF1m+ELg/Nrsw/21dwK5j0LQNlFTmR57+mICutC70rAQ+hPWXcJt 3iEKq2+Ng==; Received: from fllnx209.ext.ti.com ([198.47.19.16]) by merlin.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dELlO-0000b4-Fb for linux-arm-kernel@lists.infradead.org; Fri, 26 May 2017 20:23:13 +0000 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by fllnx209.ext.ti.com (8.15.1/8.15.1) with ESMTP id v4QKLrpP017179; Fri, 26 May 2017 15:21:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1495830113; bh=jkJ5joqNdNXMeWqZPIsK9JQh9dv3hhi+YBwLBbmgXzA=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=Xjw18I+6h6G8WCOZmlf7Jk3TabfRJU6F8pBDJBVxogjoHVBztLrgdSz1UML70tHeA N2+D7fmE18QXsAtqBsRtVNaB+UVCqSuppDbaBogdi9lL+vsrsO9/uohUvAw0LhxoEp wuTS55M5haVZ78ubCvlHui2l3seX8D4sWU8VZrE0= Received: from DLEE71.ent.ti.com (dlee71.ent.ti.com [157.170.170.114]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id v4QKLmpZ003958; Fri, 26 May 2017 15:21:48 -0500 Received: from dflp33.itg.ti.com (10.64.6.16) by DLEE71.ent.ti.com (157.170.170.114) with Microsoft SMTP Server id 14.3.294.0; Fri, 26 May 2017 15:21:47 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id v4QKLlrG027639; Fri, 26 May 2017 15:21:47 -0500 Received: from localhost (irmo.dhcp.ti.com [128.247.58.167]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id v4QKLl327277; Fri, 26 May 2017 15:21:47 -0500 (CDT) From: Suman Anna To: Bjorn Andersson , Ohad Ben-Cohen , Rob Herring Subject: [PATCH 1/4] remoteproc/davinci: Switch to platform_get_resource_byname() Date: Fri, 26 May 2017 15:21:37 -0500 Message-ID: <20170526202140.10472-2-s-anna@ti.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170526202140.10472-1-s-anna@ti.com> References: <20170526202140.10472-1-s-anna@ti.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170526_162310_706244_AA23F0D1 X-CRM114-Status: UNSURE ( 9.04 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , devicetree@vger.kernel.org, Robert Tivy , Sekhar Nori , linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The davinci remoteproc driver currently uses the platform_get_resource() API for retrieving the IOMEM resources. Switch this function to use the platform_get_resource_byname() API instead in preparation for adding the DT support so that the binding can be agnostic of the IOMEM resource order. Signed-off-by: Suman Anna --- drivers/remoteproc/da8xx_remoteproc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/remoteproc/da8xx_remoteproc.c b/drivers/remoteproc/da8xx_remoteproc.c index c7ad818f7a48..0919176b52c1 100644 --- a/drivers/remoteproc/da8xx_remoteproc.c +++ b/drivers/remoteproc/da8xx_remoteproc.c @@ -195,12 +195,14 @@ static int da8xx_rproc_probe(struct platform_device *pdev) return -EINVAL; } - bootreg_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); + bootreg_res = platform_get_resource_byname(pdev, IORESOURCE_MEM, + "host1cfg"); bootreg = devm_ioremap_resource(dev, bootreg_res); if (IS_ERR(bootreg)) return PTR_ERR(bootreg); - chipsig_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); + chipsig_res = platform_get_resource_byname(pdev, IORESOURCE_MEM, + "chipsig"); chipsig = devm_ioremap_resource(dev, chipsig_res); if (IS_ERR(chipsig)) return PTR_ERR(chipsig);