From patchwork Mon Dec 15 02:28:15 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 5489871 X-Patchwork-Delegate: geert@linux-m68k.org Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 32BE69F1D4 for ; Mon, 15 Dec 2014 02:28:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 65E6D20A0B for ; Mon, 15 Dec 2014 02:28:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9E6CB20A03 for ; Mon, 15 Dec 2014 02:28:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751132AbaLOC2T (ORCPT ); Sun, 14 Dec 2014 21:28:19 -0500 Received: from relmlor4.renesas.com ([210.160.252.174]:34953 "EHLO relmlie3.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751055AbaLOC2S (ORCPT ); Sun, 14 Dec 2014 21:28:18 -0500 Received: from unknown (HELO relmlir2.idc.renesas.com) ([10.200.68.152]) by relmlie3.idc.renesas.com with ESMTP; 15 Dec 2014 11:28:17 +0900 Received: from relmlac2.idc.renesas.com (relmlac2.idc.renesas.com [10.200.69.22]) by relmlir2.idc.renesas.com (Postfix) with ESMTP id 80F90496DF; Mon, 15 Dec 2014 11:28:17 +0900 (JST) Received: by relmlac2.idc.renesas.com (Postfix, from userid 0) id 75E422806E; Mon, 15 Dec 2014 11:28:17 +0900 (JST) Received: from relmlac2.idc.renesas.com (localhost [127.0.0.1]) by relmlac2.idc.renesas.com (Postfix) with ESMTP id 71ECE2806D; Mon, 15 Dec 2014 11:28:17 +0900 (JST) Received: from relmlii2.idc.renesas.com [10.200.68.66] by relmlac2.idc.renesas.com with ESMTP id MBP11618; Mon, 15 Dec 2014 11:28:17 +0900 X-IronPort-AV: E=Sophos;i="5.07,577,1413212400"; d="scan'208";a="176807994" Received: from mail-sg1lp0092.outbound.protection.outlook.com (HELO APAC01-SG1-obe.outbound.protection.outlook.com) ([207.46.51.92]) by relmlii2.idc.renesas.com with ESMTP/TLS/AES256-SHA; 15 Dec 2014 11:28:16 +0900 Received: from remon.renesas.com (211.11.155.132) by SIXPR06MB173.apcprd06.prod.outlook.com (10.242.151.12) with Microsoft SMTP Server (TLS) id 15.1.31.17; Mon, 15 Dec 2014 02:28:15 +0000 Message-ID: <87a92pve7i.wl%kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH 3/7] mmc: sh_mobile_sdhi: tidyup mmc_data->bus_shift for latest SoC User-Agent: Wanderlust/2.14.0 Emacs/23.3 Mule/6.0 To: Ulf Hansson , Chris Ball CC: Simon , Linux-SH , linux-mmc In-Reply-To: <87egs1ve96.wl%kuninori.morimoto.gx@renesas.com> References: <87egs1ve96.wl%kuninori.morimoto.gx@renesas.com> MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Date: Mon, 15 Dec 2014 02:28:15 +0000 X-Originating-IP: [211.11.155.132] X-ClientProxiedBy: HKXPR03CA0029.apcprd03.prod.outlook.com (10.141.129.19) To SIXPR06MB173.apcprd06.prod.outlook.com (10.242.151.12) X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;SRVR:SIXPR06MB173; X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601003); SRVR:SIXPR06MB173; X-Forefront-PRVS: 04267075BD X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6009001)(189002)(199003)(50986999)(23726002)(69596002)(92566001)(21056001)(31966008)(46102003)(47776003)(19580395003)(97736003)(40100003)(86362001)(64706001)(4396001)(50466002)(106356001)(120916001)(33646002)(99396003)(87976001)(42186005)(105586002)(62966003)(229853001)(20776003)(107046002)(77156002)(83506001)(53416004)(76176999)(122386002)(19580405001)(101416001)(66066001)(68736005)(77096005)(54356999)(46406003)(81156004)(36756003); DIR:OUT; SFP:1102; SCL:1; SRVR:SIXPR06MB173; H:remon.renesas.com; FPR:; SPF:None; MLV:sfv; PTR:InfoNoRecords; MX:1; A:1; LANG:en; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:SIXPR06MB173; X-OriginatorOrg: renesas.com Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Kuninori Morimoto Latest SDHI on Renesas has expand register mapping. update mmc_data->bus_shift for it. Signed-off-by: Kuninori Morimoto --- drivers/mmc/host/sh_mobile_sdhi.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c index 00c8ebd..1c1e919 100644 --- a/drivers/mmc/host/sh_mobile_sdhi.c +++ b/drivers/mmc/host/sh_mobile_sdhi.c @@ -272,7 +272,10 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev) } /* SD control register space size is 0x100, 0x200 for bus_shift=1 */ - mmc_data->bus_shift = resource_size(res) >> 9; + if (resource_size(res) > 0x100) + mmc_data->bus_shift = 1; + else + mmc_data->bus_shift = 0; ret = tmio_mmc_host_probe(&host, pdev, mmc_data); if (ret < 0)