From patchwork Mon Feb 18 10:12:05 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jaehoon Chung X-Patchwork-Id: 2156761 Return-Path: X-Original-To: patchwork-linux-mmc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 142FEDF25A for ; Mon, 18 Feb 2013 10:12:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757808Ab3BRKMD (ORCPT ); Mon, 18 Feb 2013 05:12:03 -0500 Received: from mailout2.samsung.com ([203.254.224.25]:18921 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757573Ab3BRKMB (ORCPT ); Mon, 18 Feb 2013 05:12:01 -0500 Received: from epcpsbgr1.samsung.com (u141.gpu120.samsung.co.kr [203.254.230.141]) by mailout2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MIE00691UYMDXA0@mailout2.samsung.com> for linux-mmc@vger.kernel.org; Mon, 18 Feb 2013 19:12:00 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [203.254.230.45]) by epcpsbgr1.samsung.com (EPCPMTA) with SMTP id BB.F0.16905.F6EF1215; Mon, 18 Feb 2013 19:11:59 +0900 (KST) X-AuditID: cbfee68d-b7f4f6d000004209-9c-5121fe6f61e5 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id 25.1D.03880.F6EF1215; Mon, 18 Feb 2013 19:11:59 +0900 (KST) Received: from [10.90.51.55] by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MIE00GGJUZZIF90@mmp2.samsung.com> for linux-mmc@vger.kernel.org; Mon, 18 Feb 2013 19:11:59 +0900 (KST) Message-id: <5121FE75.8000607@samsung.com> Date: Mon, 18 Feb 2013 19:12:05 +0900 From: Jaehoon Chung User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 MIME-version: 1.0 To: linux-mmc@vger.kernel.org Cc: 'Chris Ball' , Seungwon Jeon , Thomas Abraham , Kyungmin Park Subject: [PATCH 2/2] mmc: dw-mmc: fix the return value for exynos's setup_clock() Content-type: text/plain; charset=ISO-8859-1 Content-transfer-encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrGLMWRmVeSWpSXmKPExsVy+t8zXd38f4qBBpfuW1sc+d/P6MDo8XmT XABjFJdNSmpOZllqkb5dAlfGrElf2Qp2sVdMmLqdsYFxEVsXIyeHhICJxPQ935ggbDGJC/fW A8W5OIQEljFKXNy5GK6o5WkjO0RiOqNEX9N1qKp2Jom/P18zg1TxCmhJfO6ZxQpiswioSrQc Xgw2lk1AR2L7t+NgtqhAmMTK6VdYIOoFJX5MvgdmiwjISvz8cwFsKLPAIkaJtm+b2EESwgLB Em/2rwEbygw0aH/rNDYIW15i85q3zCANEgLP2SQeX+yC2iwg8W3yIaCpHEAJWYlNB5ghXpCU OLjiBssERpFZSHbPQjJ2FpKxCxiZVzGKphYkFxQnpRcZ6hUn5haX5qXrJefnbmKEhHnvDsbb B6wPMSYDrZzILCWanA+Mk7ySeENjA2NDQ0tDM1NLUwPShJXEeeUuyQQKCaQnlqRmp6YWpBbF F5XmpBYfYmTi4JRqYAzI/tFsWegan7m/aemN2HWXdz404riSeNFJwv2u7/aDT779mFdqX3XJ u2Dn4cJDa1f1n/BOtOLPK0zRsd9SGXac49zx9YlJO6I0fu68ezr35afDzZc6TlWo7G3Vs77K U7ff+eFhWZYZmsskZsgU5KZMPXnotfieBy+bt7yeKu/SUDyxoMV3mrESS3FGoqEWc1FxIgBf 285qiQIAAA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrMIsWRmVeSWpSXmKPExsVy+t9jQd38f4qBBr3N5hZH/vczOjB6fN4k F8AY1cBok5GamJJapJCal5yfkpmXbqvkHRzvHG9qZmCoa2hpYa6kkJeYm2qr5OIToOuWmQM0 VUmhLDGnFCgUkFhcrKRvh2lCaIibrgVMY4Sub0gQXI+RARpIWMeYMWvSV7aCXewVE6ZuZ2xg XMTWxcjJISFgItHytJEdwhaTuHBvPVCci0NIYDqjRF/TdSinnUni78/XzCBVvAJaEp97ZrGC 2CwCqhIthxczgdhsAjoS278dB7NFBcIkVk6/wgJRLyjxY/I9MFtEQFbi558LYEOZBRYxSrR9 2wS2WlggWOLN/jVgQ5mBBu1vncYGYctLbF7zlnkCI98sJLNmISmbhaRsASPzKkbR1ILkguKk 9FwjveLE3OLSvHS95PzcTYzgKHomvYNxVYPFIUYBDkYlHl6GfMVAIdbEsuLK3EOMEhzMSiK8 7XeAQrwpiZVVqUX58UWlOanFhxiTgV6dyCwlmpwPjPC8knhDYxMzI0sjM2MTc2Nj0oSVxHkZ Tz0JEBJITyxJzU5NLUgtgtnCxMEp1cDY8D3oy5WbV0/x2jbaxzz59EVE6FysjlbLzn3+kZ7N hSW82xR5o2Y8DqvceaxsmdiPM6cMp0s+2/O/vTZvNsP6XDVbwwlhlY5BksuWMDHx+B+9bGTV nM3GUhz/YZNRhKHe43lWRxzee3Tesg7czvn6RNDrVpctHuy8are641/+k3sw8dOrya1KLMUZ iYZazEXFiQC7spBK5gIAAA== 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 Before adjusting this patch, always return 0. Then clock-setup would be always succeed. In dw-mmc.c, it's checked like below ret = drv_data->setup_clock(host); if (ret) { ... Never entered at here.. } Signed-off-by: Jaehoon Chung Signed-off-by: Kyungmin Park --- drivers/mmc/host/dw_mmc-exynos.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/dw_mmc-exynos.c b/drivers/mmc/host/dw_mmc-exynos.c index 72fd0f2..764ff29 100644 --- a/drivers/mmc/host/dw_mmc-exynos.c +++ b/drivers/mmc/host/dw_mmc-exynos.c @@ -99,7 +99,7 @@ static int dw_mci_exynos_setup_clock(struct dw_mci *host) else if (priv->ctrl_type == DW_MCI_TYPE_EXYNOS4210) host->bus_hz /= EXYNOS4210_FIXED_CIU_CLK_DIV; - return 0; + return host->bus_hz ? 0 : -EINVAL; } static void dw_mci_exynos_prepare_command(struct dw_mci *host, u32 *cmdr)