From patchwork Wed Mar 26 11:30:56 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Seungwon Jeon X-Patchwork-Id: 3892811 Return-Path: X-Original-To: patchwork-linux-mmc@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 0BD37BF540 for ; Wed, 26 Mar 2014 11:31:03 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 367D420222 for ; Wed, 26 Mar 2014 11:31:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 440E020172 for ; Wed, 26 Mar 2014 11:31:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751951AbaCZLa7 (ORCPT ); Wed, 26 Mar 2014 07:30:59 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:15226 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751147AbaCZLa6 (ORCPT ); Wed, 26 Mar 2014 07:30:58 -0400 Received: from epcpsbgr5.samsung.com (u145.gpu120.samsung.co.kr [203.254.230.145]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N310045YJZLLH40@mailout1.samsung.com>; Wed, 26 Mar 2014 20:30:57 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [203.254.230.47]) by epcpsbgr5.samsung.com (EPCPMTA) with SMTP id F7.EE.14803.17AB2335; Wed, 26 Mar 2014 20:30:57 +0900 (KST) X-AuditID: cbfee691-b7efc6d0000039d3-3f-5332ba71835a Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id DB.6E.28157.17AB2335; Wed, 26 Mar 2014 20:30:57 +0900 (KST) Received: from DOTGIHJUN01 ([12.36.185.168]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0N310035GJZLJT50@mmp1.samsung.com>; Wed, 26 Mar 2014 20:30:57 +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' References: In-reply-to: Subject: [PATCH v2 1/7] mmc: dw_mmc: fix the max_blk_count in IDMAC Date: Wed, 26 Mar 2014 20:30:56 +0900 Message-id: <000101cf48e6$da954f90$8fbfeeb0$%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: Ac9FDjtZo1aMTMCOStGdx+bxiO4TmwD1P6hw Content-language: ko X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrOIsWRmVeSWpSXmKPExsVy+t8zfd3CXUbBBlt+q1k8mLeNzWLC5e2M Fjd+tbFa9C64ymZx5H8/o8WM8/uYLI6vDXdg97hzbQ+bx41XC5k8+rasYvT4vEkugCWKyyYl NSezLLVI3y6BK+P/b7aC/ZwV0/acYG5gfMfexcjJISFgIvF01z4oW0ziwr31bF2MXBxCAssY JXYvPMIIU7Tk6lEmiMQiRom752eyQDh/GCW2t8xnBaliE9CS+PvmDXMXIweHiICDxIvzTiBh ZoETjBLzFhuDhIUEuCVWNweBhDkFeCTW/elkBrGFBZwlzjy9wwRiswioSizvbAbbyytgK3H6 zBc2CFtQ4sfkeywgY5gF1CWmTMmFmC4vsXnNW7ClEkDhR391QcIiAkYS7Q0TmSFKRCT2vXjH CHKwhMBLdoljl9ezQKwSkPg2+RALRK+sxKYDzBDfSkocXHGDZQKjxCwki2chLJ6FZPEsJBsW MLKsYhRNLUguKE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C 2cLEwSnVwJhdKs8jtmjz9r9nNpdarHnx9q3ChPeXoh+93XTksMGSX//mHdttUdmtcOknw5NJ l/sbj33cVxxSpXv29vMat4BFHq1nfs31WPmvL26b5dzbM7bYCQq/ffB9gQbvjCj1J1qPN3Sa nVqjZ/fXQmfuhqu7V76tFrytEbz5qt6+6gVpT6bV/k9l2DOzQ4mlOCPRUIu5qDgRAGxM7U9H AwAA DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, 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 Acked-by: Jaehoon Chung --- 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 */