From patchwork Tue Feb 7 21:35:02 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 9561257 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E32FF602B1 for ; Tue, 7 Feb 2017 21:45:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D4D0428475 for ; Tue, 7 Feb 2017 21:45:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C7FB92847B; Tue, 7 Feb 2017 21:45:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 16BCA2848B for ; Tue, 7 Feb 2017 21:45:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932566AbdBGVpi (ORCPT ); Tue, 7 Feb 2017 16:45:38 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36404 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932558AbdBGVpg (ORCPT ); Tue, 7 Feb 2017 16:45:36 -0500 Received: by mail-wm0-f67.google.com with SMTP id r18so30815366wmd.3 for ; Tue, 07 Feb 2017 13:45:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:to:references:cc:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=M+95GkxWsngwiFj9NTxlb0v3WiQsL2s7v4R3vvaI1tM=; b=OYf5GAJBNPxYoBrZv840CBkleTPHJCCEaxjB2wnV0symldNxv+pDYvpTdVtodhAHa7 Bd7AHlcZCRwTdy7W1YSocKgOLxKnv9EdBjtCtFqN308DL3NVuThieYxM5gsQnj/5pWEf 8Ft6ojk6C9KBkplpKns8UeShYCtt5DFx6jvqjGkv2MoupdChRbE/K77evZpnFe+Qrbvc YRp2WeajV8v3Oaxt3qktLc58YwCBkVl0MFoKcySAitYr2ZKUEejcW/iQyF/EhVrtxdsE GAJZmb6Kb+bUdiT2ujPHYsKYckVjPdR2CGwKkUCbsmDTFvqGEVllN3X5NrZR/vlBUl7B BKKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:references:cc:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=M+95GkxWsngwiFj9NTxlb0v3WiQsL2s7v4R3vvaI1tM=; b=YoeIRBdoIM5mELZmXW+76uJ4SmQDff1Dqbou77Ssx2WEUf77ANWT2zJP6/gVivrLgj Mz4UUR1mNighXcbhib0Wdqsd9bfh0D4siQcpMlkAdBRn7hNpNTYLYG8jADn50E+jikd5 Z+59JAT5hoB4Iy3RIgmnIECsFJpWh53uFfp/iSCxpbkIBJiz49M9K0s+GUvEz2rQ9V1U HII4bG4vwIwM+uxnHBFOBugNKBOzYCorFqUWRn5+l8FxUQVV+A1ABmIvHtyedQqv0ttD q8Hhnd1acoVYuNInREEv7OQGehG+aY/30F2C+TDnNAuHN0dJpGDtEzOpSTFp69WR5BD4 3dKg== X-Gm-Message-State: AMke39lhreEguECZ1hcXCOHxGoeT1aHjf0+sTjIZabhUixd46VsXRjvwTodlQBLAzzPCHw== X-Received: by 10.28.18.130 with SMTP id 124mr15800816wms.8.1486503380701; Tue, 07 Feb 2017 13:36:20 -0800 (PST) Received: from ?IPv6:2003:c6:ebce:1e00:cd3f:c3c7:98c5:4fec? (p200300C6EBCE1E00CD3FC3C798C54FEC.dip0.t-ipconnect.de. [2003:c6:ebce:1e00:cd3f:c3c7:98c5:4fec]) by smtp.googlemail.com with ESMTPSA id a35sm9403414wra.21.2017.02.07.13.36.19 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 07 Feb 2017 13:36:20 -0800 (PST) From: Heiner Kallweit Subject: [PATCH v3 7/9] mmc: meson-gx: reduce bounce buffer size To: Ulf Hansson , Kevin Hilman References: <0991d40b-e05b-2fcb-9ee4-7b529448de69@gmail.com> Cc: Carlo Caione , "linux-mmc@vger.kernel.org" , linux-amlogic@lists.infradead.org Message-ID: <104a768e-fee3-0643-fed9-b4362b2366a1@gmail.com> Date: Tue, 7 Feb 2017 22:35:02 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <0991d40b-e05b-2fcb-9ee4-7b529448de69@gmail.com> Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP A bounce buffer of 512K isn't needed as the max request size is 511 * 512 byte. Signed-off-by: Heiner Kallweit Reviewed-by: Kevin Hilman Tested-by: Kevin Hilman --- v3: - no changes --- drivers/mmc/host/meson-gx-mmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/meson-gx-mmc.c b/drivers/mmc/host/meson-gx-mmc.c index c9f25171..4feb8971 100644 --- a/drivers/mmc/host/meson-gx-mmc.c +++ b/drivers/mmc/host/meson-gx-mmc.c @@ -782,7 +782,7 @@ static int meson_mmc_probe(struct platform_device *pdev) mmc->max_req_size = mmc->max_blk_count * mmc->max_blk_size; /* data bounce buffer */ - host->bounce_buf_size = SZ_512K; + host->bounce_buf_size = mmc->max_req_size; host->bounce_buf = dma_alloc_coherent(host->dev, host->bounce_buf_size, &host->bounce_dma_addr, GFP_KERNEL);