From patchwork Fri Mar 21 14:03:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Seungwon Jeon X-Patchwork-Id: 3874531 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id C3216BF540 for ; Fri, 21 Mar 2014 14:03:08 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F22EE2027D for ; Fri, 21 Mar 2014 14:03:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E5AAD20279 for ; Fri, 21 Mar 2014 14:03:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753930AbaCUODE (ORCPT ); Fri, 21 Mar 2014 10:03:04 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:45425 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752867AbaCUODC (ORCPT ); Fri, 21 Mar 2014 10:03:02 -0400 Received: from epcpsbgr1.samsung.com (u141.gpu120.samsung.co.kr [203.254.230.141]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N2S0030JHP19460@mailout1.samsung.com>; Fri, 21 Mar 2014 23:03:01 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [203.254.230.51]) by epcpsbgr1.samsung.com (EPCPMTA) with SMTP id AA.15.12635.4964C235; Fri, 21 Mar 2014 23:03:00 +0900 (KST) X-AuditID: cbfee68d-b7fcd6d00000315b-6e-532c46947332 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id A3.04.29263.4964C235; Fri, 21 Mar 2014 23:03:00 +0900 (KST) Received: from DOTGIHJUN01 ([12.36.185.168]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0N2S00EHVHP0O070@mmp2.samsung.com>; Fri, 21 Mar 2014 23:03:00 +0900 (KST) From: Seungwon Jeon To: linux-mmc@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: 'Chris Ball' , 'Kukjin Kim' , 'Jaehoon Chung' , 'Ulf Hansson' , 'Alim Akhtar' Subject: [PATCH 1/7] mmc: dw_mmc: fix the max_blk_count in IDMAC Date: Fri, 21 Mar 2014 23:03:01 +0900 Message-id: <001b01cf450e$458f9490$d0aebdb0$%jun@samsung.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-transfer-encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-index: Ac9FDkVofNMbKg8JRWexaNdhJLS4XQ== Content-language: ko X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrAIsWRmVeSWpSXmKPExsVy+t8zY90pbjrBBqvO21g8mLeNzWLC5e2M Fjd+tbFa9C64ymZx5H8/o8WM8/uYLI6vDXdg97hzbQ+bx41XC5k8+rasYvT4vEkugCWKyyYl NSezLLVI3y6BK+P/b7aC/ZwV0/acYG5gfMfexcjJISFgInF4xy0WCFtM4sK99WxdjFwcQgLL GCWWz+9jgSn6/OYjO0RiOqPEhhsNUM4fRonVcyaBVbEJaEn8ffOGuYuRg0NEwEHixXknkDCz wAlGiXmLjUFsYaDwncvnGEFsFgFVidmrVzKD2LwCthIHzy1ng7AFJX5MvscCMoZZQF1iypRc iDHyEpvXvAWbLgEUfvRXFyQsIqAncXLtTjaIEhGJfS/eMYJcJiFwil3i1ZOJLBCrBCS+TT7E AtErK7HpADPEW5ISB1fcYJnAKDYLyeJZCItnIVk8C8mGBYwsqxhFUwuSC4qT0osM9YoTc4tL 89L1kvNzNzFCYq93B+PtA9aHGJOBtk9klhJN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Pq4pe4hj 1nUxj4Cps9M7L59gVuhvjt2s8rPr0u4jv5vKN+0oU32wZdMhFmaWw3Ftp4I3iC5+/KjwBc97 ea4tT+Ulf/c+NvSQ8TyrxFKckWioxVxUnAgArWdO7TADAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@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=unavailable 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 Even though 1MB is reserved for descriptor table in IDMAC, the dw_mmc host driver is allowed to receive only maximum 128KB block length in one request. This is caused by setting improper max_blk_count. It needs to be e adjusted so that descriptor table is used fully. It is found that the performance is improved with the increased the max_blk_count. Signed-off-by: Seungwon Jeon --- drivers/mmc/host/dw_mmc.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c index 3a6721e..aeb38f9 100644 --- a/drivers/mmc/host/dw_mmc.c +++ b/drivers/mmc/host/dw_mmc.c @@ -2101,9 +2101,9 @@ static int dw_mci_init_slot(struct dw_mci *host, unsigned int id) #ifdef CONFIG_MMC_DW_IDMAC mmc->max_segs = host->ring_size; mmc->max_blk_size = 65536; - mmc->max_blk_count = host->ring_size; mmc->max_seg_size = 0x1000; - mmc->max_req_size = mmc->max_seg_size * mmc->max_blk_count; + mmc->max_req_size = mmc->max_seg_size * host->ring_size; + mmc->max_blk_count = mmc->max_req_size / 512; #else mmc->max_segs = 64; mmc->max_blk_size = 65536; /* BLKSIZ is 16 bits */