Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932391AbbFWMAF (ORCPT ); Tue, 23 Jun 2015 08:00:05 -0400 Received: from mail-by2on0103.outbound.protection.outlook.com ([207.46.100.103]:6905 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754298AbbFWL76 (ORCPT ); Tue, 23 Jun 2015 07:59:58 -0400 Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=freescale.com; freescale.mail.onmicrosoft.com; dkim=none (message not signed) header.d=none; From: Haibo Chen To: , , , , , CC: , Subject: [PATCH v2 4/4] mmc: sdhci-esdhc-imx: set back the burst_length_enable bit to 1 Date: Tue, 23 Jun 2015 19:48:03 +0800 Message-ID: <1435060083-2606-5-git-send-email-haibo.chen@freescale.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1435060083-2606-1-git-send-email-haibo.chen@freescale.com> References: <1435060083-2606-1-git-send-email-haibo.chen@freescale.com> X-EOPAttributedMessage: 0 X-Microsoft-Exchange-Diagnostics: 1;BN1AFFO11FD043;1:b3Wipj6h8WauAfUPIOenM64gHzwBTivPWQDUkjk4PFLwoRIf+oVxNcztAAps2Bt0QZwmulgbumIrd18Iq0WFcfXGSioV4lAx3UOoysKj2NOG4pSopEXLlCVhlVR2aMPkTdVuwbrZjHZE8KnTWWhYSPaLsLF+Ey75FZr6rKorEDrucl4GbyQ1WIRxdrqkPXnfApkZFt0FslqsfBX7RfsYVwu4XH5QS2TOV9rnw1Jo1GMKVrebMbwu44RldAfpniQk97veyheNYnT/1YEnuMEB0HU/KeYywax4B0NB7X3PbLGEfdNCZ5ra64RtH6Ywsr06Uc9kwqg4aFj7nezavEYaVw== X-Forefront-Antispam-Report: CIP:192.88.158.2;CTRY:US;IPV:NLI;EFV:NLI;SFV:NSPM;SFS:(10019020)(6009001)(2980300002)(339900001)(199003)(189002)(33646002)(105606002)(575784001)(229853001)(230783001)(36756003)(189998001)(5001960100002)(50226001)(107886002)(5001770100001)(47776003)(6806004)(77156002)(62966003)(46102003)(85426001)(76176999)(87936001)(86362001)(50466002)(2201001)(77096005)(2950100001)(48376002)(19580395003)(104016003)(50986999)(19580405001)(106466001)(92566002)(4001430100001);DIR:OUT;SFP:1102;SCL:1;SRVR:CY1PR03MB1389;H:az84smr01.freescale.net;FPR:;SPF:Fail;MLV:sfv;A:1;MX:1;LANG:en; MIME-Version: 1.0 Content-Type: text/plain X-Microsoft-Exchange-Diagnostics: 1;CY1PR03MB1389;2:x+PjjkezFAjW3HFEj2tJp9J8bSn6PEE/ZUBQkN/JydlKBVFcE1LUFACopd8//ir+;3:OTzKXXRQMOmBV6727SwWbuctcxkYLZP7SoruWIWhzstUY1yfcuy27BU5B8t3GohE9IJz5rOJcbiMIzhh+g4BFRx41LIBTycxuzg8clxLQsbS6GB8GFyl5MHR4NRagSD4K7087aFLGp21G+qP7AiKSGp1WrHHCuqYNzeB73innFIu42nrtBsP9wjb6+9Isaqqwn2xDPQWMWUx8wta7lhC7wWgzHcyOFsfgcu6ja50TNA=;20:aQ4ZI/tME1suP/dr5UibhqIAMm6UnQbWHAYyQRXacLVCe8GapHlt6JDOgGO0+YEQUkIf6DwPEuSFOIvB95a5py/ycfDO24/c5GdQ/TfTOfKqWOxcsopq62vv01sZbCOFZSAdAwVxbMoSBMW/4sJHfiw1bR2qZa7nbwYOAbdVU+VkFymUFunchd/kFpHFuOccGgTkcasseEkKLUHEzbL015ExboIdBj/x26h1VEQDnQuq7t6sAb/ePCEIzWbgT91c6dfdvJrh7uv8I/OqDjgiEQ4g8R6pkP3W2D7PijDSWk6jc4wkGHPiJebqD//Ld2sseHYhXTx940EbKRvgBv/mJIi55nL2K6G+ZouwN6Z9ZBM=;4:LsWDbyfUO/SW2PvoiHgofJ1Xww8TskZEMRg4u42SCd9KdxAh15A7qZJnNwLuX97of4YqP1puf3YGyFbAX+ayhEJFr27LU+Vqhn5cKkWLodak5U4AtbHgL+2fzssD9eqtr1jBh+t22coy5PK2YTW8fbJNvOdHiLAfQW6dbecJgJYq14A4n5HCMFvj7BFdMLRuHrocfia4L3KXCjTQ+OaYPFAirKy8KktTLRhTuZZFz51mc4Op6+BqmYKDmFWM5pSpc8qK2Ak59fogH7IE7aMLFsdOXm60hhh5ctSZgGc1lNI= X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:CY1PR03MB1389; 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:CY1PR03MB1389;BCL:0;PCL:0;RULEID:;SRVR:CY1PR03MB1389; X-Forefront-PRVS: 06167FAD59 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CY1PR03MB1389;23:uY3a2n3ABbeayqgK16GP8agtmsQ115VGfZtXB/3mo?= =?us-ascii?Q?GG03nw37r8oQxzvbGuvQliFs/++3f3fFZ3HBF3RgfyKfhLWNMoksC/c/nXzN?= =?us-ascii?Q?pbgFYA7d0mLh66T+Znc2Nb3Z2ibMw4SC91HbPoEWWbG5EWHBS1l7Fuq2BNmf?= =?us-ascii?Q?sscgZV+TLvWYcELVCRDzWNsN49X4kndMUnIGDKGfpbM396DpS4tcMz0OH583?= =?us-ascii?Q?Vx8idlxp91BqgW6cXNeI33fV5dXqUdLrS0H2W1qI5TPnwx2/aYyMcRm9qMhi?= =?us-ascii?Q?s9JAso3K25x1ExjYJfHwSCkDTNbmUwIBP6tsdoNNjVkN01Xxp+dnr1oYRytr?= =?us-ascii?Q?nVRiFsMqJAGRfkCZcRcr7QNfcozAxXj/K4T8SxiPapFJ6CWwP/RAYiPo4kVS?= =?us-ascii?Q?f8nhrZ9hOXlsVvP5/StkMN4kacpAe/xFDvi672znxZ/rDmyQQkW6D9iQwLhM?= =?us-ascii?Q?6fs1TuJ3/pKPQzu9u2AM3fTpJ3V7NQXODWM/DU1PXzR4A3q4Wpdq8fnCRPPm?= =?us-ascii?Q?s8bFt888KiwJpZT9M3JpoIOzEwaUCpDBv1Q0cchmv0TT/AeN3MXzxXYHVjau?= =?us-ascii?Q?aFXrOjYJeYuyH9BE7ITXGy8bWYjK+V4XC6uKDMjR2vc4tJ8IrHRWc/INq8wj?= =?us-ascii?Q?Vk5WUxULfTznJf5NBNqwYC+hgh0Rp8PUaPve69zIAVDjMLBMAwPhWeg4LC3Y?= =?us-ascii?Q?GEwTE58MABap/nwRu4z0URkDWCfCQpP2lNywX8jR6EFbg2DktWHiJszMPV/n?= =?us-ascii?Q?s1Sm+ccTu8zvOcODG4z66mv+J/VZ2Sf27Z1LNdSSpxflijFhCPbfy2eNH83b?= =?us-ascii?Q?ASmQ5iivOtva7YGI1MHccVqHOYi5ER6zdq4kYJVvaeWFhUnDOixqezeyHMke?= =?us-ascii?Q?4hZx4Z8eRjlo3M5UVF7eNgf8T6ShwPHh9uLkazAY6EYuGjagB0xvJrebXADe?= =?us-ascii?Q?mkd9tTcw93bhZDA5AVfLIPyGWLyj6vSsndlHJJgn3m9xQ3ToO+u7LVZKnCNP?= =?us-ascii?Q?Wo=3D?= X-Microsoft-Exchange-Diagnostics: 1;CY1PR03MB1389;5:6EOtNgdd8FBfIYG1oLG9YP+cDu8sYMLxfmwzkMxWoF2A2EnjTPgjhiJqQsWs5HDz2j0P9dqjhyXOcI4727zpoOGb5COjVWLI7zbJfUwJUG7qhiypoyO/s2S0uivEHQydP3VUHsK4lu9Ny9C7tULeXA==;24:qA5eKsdS9L1BxXsw387UrlifDXlb0tisZ36rccLdR8ms6JbYYCn+jw2c7exJQgzkfGs5fGkrxGZv7CrSMWMpZN5jA2iL3BLgiJ9Hc01xc6o=;20:UkP3JuHQLa+HD6D45uF9Xf0sLLrTEI4mCyRBiSZWVNSg3Jp2RDSP84CELi0EtHL7/PeatODLrxJJGWpb1pS29w== X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Jun 2015 11:45:29.0700 (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: CY1PR03MB1389 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1811 Lines: 49 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 1f0e0d9..e6a1995 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) @@ -1088,6 +1089,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. + */ + 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/