From patchwork Mon Dec 5 08:55:20 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xiaobo Xie X-Patchwork-Id: 129257 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id A0E28100AC0 for ; Mon, 5 Dec 2011 21:12:49 +1100 (EST) Received: from TX2EHSOBE007.bigfish.com (tx2ehsobe004.messaging.microsoft.com [65.55.88.14]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (Client CN "mail.global.frontbridge.com", Issuer "Microsoft Secure Server Authority" (verified OK)) by ozlabs.org (Postfix) with ESMTPS id 0E45B1007D4 for ; Mon, 5 Dec 2011 21:12:40 +1100 (EST) Received: from mail80-tx2-R.bigfish.com (10.9.14.242) by TX2EHSOBE007.bigfish.com (10.9.40.27) with Microsoft SMTP Server id 14.1.225.23; Mon, 5 Dec 2011 10:12:36 +0000 Received: from mail80-tx2 (localhost [127.0.0.1]) by mail80-tx2-R.bigfish.com (Postfix) with ESMTP id 5DFAA30030F; Mon, 5 Dec 2011 10:12:35 +0000 (UTC) X-SpamScore: 12 X-BigFish: VS12(zzzz1202hzz8275bhz2dh2a8h668h839hb79i4a8s62h) X-Spam-TCS-SCL: 1:0 X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPV:NLI; H:mail.freescale.net; RD:none; EFVD:NLI Received: from mail80-tx2 (localhost.localdomain [127.0.0.1]) by mail80-tx2 (MessageSwitch) id 132307995555976_15194; Mon, 5 Dec 2011 10:12:35 +0000 (UTC) Received: from TX2EHSMHS028.bigfish.com (unknown [10.9.14.249]) by mail80-tx2.bigfish.com (Postfix) with ESMTP id 078CE280042; Mon, 5 Dec 2011 10:12:35 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by TX2EHSMHS028.bigfish.com (10.9.99.128) with Microsoft SMTP Server (TLS) id 14.1.225.23; Mon, 5 Dec 2011 10:12:35 +0000 Received: from az33smr01.freescale.net (10.64.34.199) by 039-SN1MMR1-001.039d.mgd.msft.net (10.84.1.13) with Microsoft SMTP Server id 14.1.339.2; Mon, 5 Dec 2011 04:12:34 -0600 Received: from localhost.localdomain (rock.ap.freescale.net [10.193.20.106]) by az33smr01.freescale.net (8.13.1/8.13.0) with ESMTP id pB5ACT2w023209; Mon, 5 Dec 2011 04:12:31 -0600 (CST) From: Xie Xiaobo To: Subject: [PATCH] mmc: sdhci-pltfm: Added sdhci-adjust-timeout quirk Date: Mon, 5 Dec 2011 16:55:20 +0800 Message-ID: <1323075320-9138-1-git-send-email-X.Xie@freescale.com> X-Mailer: git-send-email 1.6.4 In-Reply-To: References: MIME-Version: 1.0 X-OriginatorOrg: freescale.com Cc: avorontsov@ru.mvista.com, linux-mmc@vger.kernel.org, Xie Xiaobo X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Some controller provides an incorrect timeout value for transfers, So it need the quirk to adjust timeout value to 0xE. E.g. eSDHC of MPC8536, P1010, and P2020. Signed-off-by: Xie Xiaobo --- drivers/mmc/host/sdhci-pltfm.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c index a9e12ea..b5d6b3f 100644 --- a/drivers/mmc/host/sdhci-pltfm.c +++ b/drivers/mmc/host/sdhci-pltfm.c @@ -2,7 +2,7 @@ * sdhci-pltfm.c Support for SDHCI platform devices * Copyright (c) 2009 Intel Corporation * - * Copyright (c) 2007 Freescale Semiconductor, Inc. + * Copyright (c) 2007, 2011 Freescale Semiconductor, Inc. * Copyright (c) 2009 MontaVista Software, Inc. * * Authors: Xiaobo Xie @@ -68,6 +68,9 @@ void sdhci_get_of_property(struct platform_device *pdev) if (of_get_property(np, "sdhci,1-bit-only", NULL)) host->quirks |= SDHCI_QUIRK_FORCE_1_BIT_DATA; + if (of_get_property(np, "sdhci,sdhci-adjust-timeout", NULL)) + host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL; + if (sdhci_of_wp_inverted(np)) host->quirks |= SDHCI_QUIRK_INVERTED_WRITE_PROTECT;