Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753361AbbHCMVu (ORCPT ); Mon, 3 Aug 2015 08:21:50 -0400 Received: from mail-bl2on0129.outbound.protection.outlook.com ([65.55.169.129]:58557 "EHLO na01-bl2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752670AbbHCMVr (ORCPT ); Mon, 3 Aug 2015 08:21:47 -0400 Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=freescale.com; vger.kernel.org; dkim=none (message not signed) header.d=none; Date: Mon, 3 Aug 2015 20:12:36 +0800 From: Dong Aisheng To: Chen Haibo-B51421 CC: "robh+dt@kernel.org" , "pawel.moll@arm.com" , "mark.rutland@arm.com" , "ijc+devicetree@hellion.org.uk" , "galak@codeaurora.org" , "shawnguo@kernel.org" , "kernel@pengutronix.de" , "linux@arm.linux.org.uk" , "ulf.hansson@linaro.org" , "johan.derycke@barco.com" , Estevam Fabio-R49496 , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-mmc@vger.kernel.org" Subject: Re: [PATCH v3 6/6] mmc: sdhci-esdhc-imx: set back the burst_length_enable bit to 1 Message-ID: <20150803121235.GC24870@shlinux1.ap.freescale.net> References: <1438160637-28061-1-git-send-email-haibo.chen@freescale.com> <1438160637-28061-7-git-send-email-haibo.chen@freescale.com> <20150731145751.GG27806@shlinux1.ap.freescale.net> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) X-EOPAttributedMessage: 0 X-Microsoft-Exchange-Diagnostics: 1;BY2FFO11FD041;1:qiyRBqj3JGnMNrQ+2CrpUWASjBtPmFyNvbHUlJ+8/11Y3P6RtrD/WRgwVPQe5TkGMwzGS5LP6C5UnnhbT5RddfLgze7JwXCqw1Lmf3do1CDuLQ3L5LGDTqg4XOAVw0GaDQiXXrk+cIcsyQYUxkyqxznNczvnhIPeZQtpBxKa7XSjAb1lhYx0Jy+882IM/klddCc8X1i3rCZu44A3qDRHBPvZ9B3JbbdHB08yU1FpGmXHfOo+oWjQ/cGndF2fj02GBs8FakspJ+3Jr+gYKwBa6MOr/GqeFoMayDzfXDYAwMRqjzz9s52h0cI2p3EgC4JWSNRfJwgip3576J/zw4Iurw== X-Forefront-Antispam-Report: CIP:192.88.158.2;CTRY:US;IPV:NLI;EFV:NLI;SFV:NSPM;SFS:(10019020)(6009001)(2980300002)(339900001)(13464003)(199003)(24454002)(189002)(377454003)(5003600100002)(19580405001)(93886004)(19580395003)(77096005)(6806004)(105606002)(4001450100002)(85426001)(83506001)(87936001)(2950100001)(230783001)(97756001)(106466001)(33656002)(50466002)(46406003)(54356999)(76176999)(46102003)(92566002)(110136002)(47776003)(23726002)(86362001)(104016003)(189998001)(50986999)(4001350100001)(5001960100002)(77156002)(62966003);DIR:OUT;SFP:1102;SCL:1;SRVR:BY1PR03MB1387;H:az84smr01.freescale.net;FPR:;SPF:Fail;MLV:sfv;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: 1;BY1PR03MB1387;2:Giqcz9/H15VrAcK5RvnoyCp8KG/GJ+d6etYSGOyCra+ANouSp3ip90tdyD/D+RpEZDdgfbcKiW6ntis+e51j2OWdILfPc2YccDdIOry0k2SSi41wTkl9zccvsqE8IFqGcex3esnJQEY2uEsiC67XIU4nyB2GbCpG6nYU90rxnqA=;3:DfjwRGCE6IInZQmUD4Q1rFdzi9VRtiKLPwXX7gmTYiJ3oZjqNN8cjJRndS+CBrZaihiuwhZSCQgQdiyigpIKzpLB8Oyl40cfbJRgPdCFcN+KMTOTQYWPV/AbeBzkt0uHt8uxNHI1F+NZK6n6iVLpukL+SgSLWm1PnRUsLENxfu/YPFpR7TXTjAh8AEzG6gVC/Iiv9mxRL+E5g9UzmTXq4ltsHB7n36NDG4eev4errFE=;25:QD7mTXyoeEVUYj2cKLkAJ/tFUTvryxH4IbcBRSlQOHlqZlOj3Sekl/J9/kl5CMdFqYC5pZ8V5ID/Pd1t4it9PG4VEhFVYc9m0M2MKqS77BZj8mltHf8t4E//3OzxR/0MCsE68jaYYP6cLWaHaHVqq4SUCU65U9NpD89611pxl5M4QqUgRhS9Jr2MqILNfKTMmbI0GlCCoCnqCQBW2YeOlm++S+Mihng1564xXkLd9lj/CAcucmDGma72hIKfh54u X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1387; X-Microsoft-Exchange-Diagnostics: 1;BY1PR03MB1387;20:LwitY04v3tlhM3khRFUnRe7QzkFRY8vlxhr8b4oL3fUmky/pLRcpe/qVaNw9O1mLjPomLTG5EdWACNaSMevw74M86pCF17HDDjCroz47dMGHZqIz/03Q+0IKUuHF/Bws2et9+9hmvVCDvmRnJ3J1PzqZIIbyBaBnKXNW1FeoLa8fYPWrO7/l0IvebktHsM4+FfI8+k3sFo/sFsiBw9P4o4krSSoQNmJ+1eDFjvo2sMWhwteU76CKzWBzog5bAYFM8PoBHEFPPED8YGELZBSM39wnq0fUbFNX3552NmhdTOnTNjFRUx0G73/hvhgb6U3BEEXAlA1XoDKCXn5e9NO8GuSGscOoGZ05xJfNn/T2/cU=;4:Il0dk8y0iiH001cZdQzxV7Q4nW04liG7STUaXAS6ludhKgcEHubjVESwTAdgAn9vp8bwwsqWoP2Uk/oWoGlcxt7sKTG59O9zuC8XmUQM6NSyuAZ7ptyYPwKKW46oQixp5dLj1cuWqdtGZszdAgs0q2tpzl1sVY2Cg4WqJ3dmhlM9vgegdEVo5nANwZOl7ORUqISKdGtZJXN4tBiMRAbjt/K1TUxdFztTtJyjH7z+i+AsVDtV8IwwD9Jv54b48nOiJa2I/ksVPY1/XcSBHRBt5NNGSJkMAQ4hE74Qn2dxmJM= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:BY1PR03MB1387;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1387; X-Forefront-PRVS: 0657D528EC X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BY1PR03MB1387;23:gKLL2awJ10U5xRlYgm1OypCbXmeVx37ZLD5G6V1mq?= =?us-ascii?Q?bdVGsURpGNybvp/Bo24DriMDSIFu1PtupQ+QvAWq9I+Hf5orlveQV93JCpxb?= =?us-ascii?Q?blIHQi2CBHSEcoFumuVTOhpOjjHPVbzQXwAxnSTRFh0hEyo2T9ZJsoL/8Slq?= =?us-ascii?Q?A4zxDQEitUmST+ACGG4OU59IgL4C8Jcc+5omy8IGidD+UgktLlscDRtzxNoc?= =?us-ascii?Q?0DEknfNPgvZOyxHkkm74pJZfw/URjvvzHS9IB3By1WYPBVvusHOsjOpxYl0A?= =?us-ascii?Q?uqqswCcT/+x86NdPuxlpWMXbPl2B+NtQOHOT9GJ+BodPAhNeKASBSpRi2SDW?= =?us-ascii?Q?LU2G1hOWj5p1uO++vXurHG+xGDosQBlAgJ39BcZhAStYn+B7HxLbUxzvURxp?= =?us-ascii?Q?JlXQ4p06VLdXtt9+elACY2mY3d2skjfqdkzIcXV307VoiHDV4XWd/caHHMzZ?= =?us-ascii?Q?aGsperUUCtom7ne62R155YRJyk3pHQH67lybNMcjhcir+tNfYGwHTewBpd31?= =?us-ascii?Q?OHOCTZd/yfHI+N6Tv+wMu6ll3EqSuUzvWn/6TlApa3Vp/8+I6RcT3/pzqT7b?= =?us-ascii?Q?NRcvLdG0H6y50cg3QkBgo1x9ff0CCxKFGN7QYPnI+vi+3H13axKJ0YY04BVL?= =?us-ascii?Q?W9QlpOSmOBA1QL3ofo3KuiUM2rtEIhQbpCIIeenLiE6bewk41e5hBhqSR8RY?= =?us-ascii?Q?y8ml7TrOpRIdaCp4DXPncEO6jlGXXBbUpBTzu+YwZvi5cdNbLGhm/wupuOIJ?= =?us-ascii?Q?ZHV7ORShT1aNjqdadHi8VDVL8Sq/MotpGfEWfBTHUvqGi2P/0veBm2cRK/Iy?= =?us-ascii?Q?mIya/ij16XQv9ddb1rgYhl/a6WUK18+HiyXlbEnry0pMVJZih5EasfsubAqk?= =?us-ascii?Q?JnTPK7es3FVDP4gfnriZW328sK3ilQVIKYXTyD9pAbqolRZgb9RCfBbLPqk6?= =?us-ascii?Q?yJqm5S8fA6hsT4mXhEtIv7s9tViCRnmaaI4uHwSQWk6Qv9xNAZlJAkImv/7n?= =?us-ascii?Q?V0pyDdvwPB0Pvdb6fRaGfh7STnDzLJZEUlf50foP/9A2KSRIvlZ5LMRHTh0N?= =?us-ascii?Q?SN7s0uK1xE6hwqLcVhOhNouVzmW?= X-Microsoft-Exchange-Diagnostics: 1;BY1PR03MB1387;5:eLfMwly6/0G398S/tGNNLjTRh/i0I2xz96HD4pkDIJCBuEB5oinI/UdkIcqyjI2XQsWPe6vUGfnLshyQQUM9QCVyNZy03yMMHaxjbX3y3X2rwWQTC5rb4lZT5bfJCl5PT56WuML4qobFtok49r6ITA==;24:BDEEMYM9WCFi9flRcOSyTLwKd9U5umWkyKGF5a7vOSc4EucW+DQ0aMEzmh4T6L308d6JGgzpM7v4Hv3vydL6QrElTuj1QLJEWEDKzzFUMLE=;20:JCyfgnULc34gpq3Zy07H/BRXnrC8ra26NqVFtAso5eJTQSxuL3CK3zDESy/I8HFOOlWiCfQiG5gvM41IXdrREg== X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Aug 2015 12:21:43.4610 (UTC) X-MS-Exchange-CrossTenant-Id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=710a03f5-10f6-4d38-9ff4-a80b81da590d;Ip=[192.88.158.2];Helo=[az84smr01.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR03MB1387 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3918 Lines: 98 On Mon, Aug 03, 2015 at 09:08:28AM +0800, Chen Haibo-B51421 wrote: > > > > -----Original Message----- > > From: Dong Aisheng [mailto:aisheng.dong@freescale.com] > > Sent: Friday, July 31, 2015 10:58 PM > > To: Chen Haibo-B51421 > > Cc: robh+dt@kernel.org; pawel.moll@arm.com; mark.rutland@arm.com; > > ijc+devicetree@hellion.org.uk; galak@codeaurora.org; shawnguo@kernel.org; > > kernel@pengutronix.de; linux@arm.linux.org.uk; ulf.hansson@linaro.org; > > johan.derycke@barco.com; Estevam Fabio-R49496; Dong Aisheng-B29396; > > devicetree@vger.kernel.org; linux-kernel@vger.kernel.org; linux-arm- > > kernel@lists.infradead.org; linux-mmc@vger.kernel.org > > Subject: Re: [PATCH v3 6/6] mmc: sdhci-esdhc-imx: set back the > > burst_length_enable bit to 1 > > > > On Wed, Jul 29, 2015 at 05:03:57PM +0800, Haibo Chen wrote: > > > Currently we find that if a usdhc is choosed to boot system, then ROM > > > code will set the burst length enable bit of this usdhc as 0. > > > > > > This will make performance drop a lot if this usdhc's burst length is > > > 16. So this patch set back the burst_length_enable bit as 1, which is > > > the default value, and means burst length is enabled for INCR. > > > > > > Signed-off-by: Haibo Chen > > > --- > > > drivers/mmc/host/sdhci-esdhc-imx.c | 11 +++++++++++ > > > 1 file changed, 11 insertions(+) > > > > > > diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c > > > b/drivers/mmc/host/sdhci-esdhc-imx.c > > > index 37d0095..dd945e5 100644 > > > --- a/drivers/mmc/host/sdhci-esdhc-imx.c > > > +++ b/drivers/mmc/host/sdhci-esdhc-imx.c > > > @@ -32,6 +32,7 @@ > > > #include "sdhci-esdhc.h" > > > > > > #define ESDHC_CTRL_D3CD 0x08 > > > +#define ESDHC_BURST_LEN_EN_INCR (1 << 27) > > > /* VENDOR SPEC register */ > > > #define ESDHC_VENDOR_SPEC 0xc0 > > > #define ESDHC_VENDOR_SPEC_SDIO_QUIRK (1 << 1) > > > @@ -1158,6 +1159,16 @@ static int sdhci_esdhc_imx_probe(struct > > platform_device *pdev) > > > host->quirks2 |= SDHCI_QUIRK2_PRESET_VALUE_BROKEN; > > > host->mmc->caps |= MMC_CAP_1_8V_DDR; > > > > > > + /* > > > + * ROM code will change the burst_length_enable setting to > > > + * zero if this usdhc is choosed to boot system. Change it > > > + * back here, otherwise it will impact the performance a > > > + * lot if the burst length is 16. > > > > Can you clarify a bit more on why performance drops a lot if burst length > > is 16? > > Caused by the burst length setting did not work due to ROM disabled it? > > > [haibo] this bit is used to enable/disable the burst length for the external AHB2AXI bridge, > It's useful especially for INCR transfer because without burst length indicator, the AHB2AXI > bridge doesn't know the burst length in advance. And without burst length indicator, AHB INCR > transfers can only be converted to singles on the AXI side. > > Seting this bit means burst length enabled for INCR. > If this bit is not set, performance will drop a lot when burst length is 8 or 16. I will add > this in the commit log. > Thanks for clarify. One question: with this patch, can we set the default watermark level to 64 by default for all SoC types? If yes, we may not need patch 5 anymore. [PATCH v3 5/6] mmc: sdhci-esdhc-imx: config watermark level and burst length Regards Dong Aisheng > > > > Regards > > Dong Aisheng > > > > > + */ > > > + writel(readl(host->ioaddr + SDHCI_HOST_CONTROL) > > > + | ESDHC_BURST_LEN_EN_INCR, > > > + host->ioaddr + SDHCI_HOST_CONTROL); > > > + > > > if (!(imx_data->socdata->flags & ESDHC_FLAG_HS200)) > > > host->quirks2 |= SDHCI_QUIRK2_BROKEN_HS200; > > > > > > -- > > > 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/