From patchwork Mon May 6 17:01:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Scott Branden X-Patchwork-Id: 10931623 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id ADF2C14DB for ; Mon, 6 May 2019 17:01:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9BD4828877 for ; Mon, 6 May 2019 17:01:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8FAEE2887B; Mon, 6 May 2019 17:01:47 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 3AB6828877 for ; Mon, 6 May 2019 17:01:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727024AbfEFRBg (ORCPT ); Mon, 6 May 2019 13:01:36 -0400 Received: from mail-pg1-f193.google.com ([209.85.215.193]:38899 "EHLO mail-pg1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726582AbfEFRBg (ORCPT ); Mon, 6 May 2019 13:01:36 -0400 Received: by mail-pg1-f193.google.com with SMTP id j26so6755859pgl.5 for ; Mon, 06 May 2019 10:01:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=zm81FW3KcENXa+XgLOmWMC1Drv2h8huE0OlhIp7SLHw=; b=RdGeecv84dfagcFaBy4oZ8KX4YElvSCjgZ4wewEOn11JljodjvXlkDUiIVZwXtqxJ8 SGycem6z7VwK/vXBklKJf0c5MRxBr4efE+k1J9U3I6eaHpraVQFRuTJFGElKI9V/elBe II6qQdUp0itHcwyvDHxXEp5ZOlY9zDetY/CDk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=zm81FW3KcENXa+XgLOmWMC1Drv2h8huE0OlhIp7SLHw=; b=qN69QOTwM5gNKs9j0bXsyqS25u6zKWKBiOYMlnA9/Lzp/s8uH0J7IYvykiezzEDB3Q MYJlcOC728nmsowMIJ0WlNumnnsxI0a/T8O9H7/ik30U65kCLgivqu38B5KfpyBe0+MJ U+Whq8Qv6WysBnmXSWVzB4QzvojBF3oQVaFKlPwBMpBkZam1C7i0Zo0zmwmfb/RVIE0T M9nzggX9gqPN9gxI+GwN6b86gpayzJs6Y1qJYWSXBPS/vNWGkXAf3S9obG/+gDKAeK/P tZTji6OQ4Xth22G8rNLXoBpyH5P1OWeWwo0CjdK0/LKAjq396HRy94n9W9vgY2fEkb0R zp/Q== X-Gm-Message-State: APjAAAXqRN3hCclH1uiOa9u5oyWOWQtsZBXmFdOaJ/XhdQ7DxqtYMcri 40cORgih2IDoxedCS1LbU8k+NQ== X-Google-Smtp-Source: APXvYqwvaQXC+Zr1EWpDHk8e2qxSkU9qk1E9SvIbRABldfphC9oNl/iAN5jE6MiK12SrGhU7LRMB3A== X-Received: by 2002:a63:a18:: with SMTP id 24mr32875692pgk.332.1557162094885; Mon, 06 May 2019 10:01:34 -0700 (PDT) Received: from lbrmn-lnxub113.broadcom.net ([192.19.228.250]) by smtp.gmail.com with ESMTPSA id l23sm4555644pgh.68.2019.05.06.10.01.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 06 May 2019 10:01:34 -0700 (PDT) From: Scott Branden To: Adrian Hunter , Ulf Hansson , Ray Jui , Scott Branden , Stefan Wahren Cc: BCM Kernel Feedback , linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Trac Hoang , Scott Branden Subject: [PATCH 1/2] mmc: sdhci-iproc: cygnus: Set NO_HISPD bit to fix HS50 data hold time problem Date: Mon, 6 May 2019 10:01:14 -0700 Message-Id: <20190506170115.10840-2-scott.branden@broadcom.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190506170115.10840-1-scott.branden@broadcom.com> References: <20190506170115.10840-1-scott.branden@broadcom.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 From: Trac Hoang The iproc host eMMC/SD controller hold time does not meet the specification in the HS50 mode. This problem can be mitigated by disabling the HISPD bit; thus forcing the controller output data to be driven on the falling clock edges rather than the rising clock edges. This change applies only to the Cygnus platform. Fixes: c833e92bbb60 ("mmc: sdhci-iproc: support standard byte register accesses") Signed-off-by: Trac Hoang Signed-off-by: Scott Branden Acked-by: Adrian Hunter --- drivers/mmc/host/sdhci-iproc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c index 9d12c06c7fd6..9d4071c41c94 100644 --- a/drivers/mmc/host/sdhci-iproc.c +++ b/drivers/mmc/host/sdhci-iproc.c @@ -196,7 +196,8 @@ static const struct sdhci_ops sdhci_iproc_32only_ops = { }; static const struct sdhci_pltfm_data sdhci_iproc_cygnus_pltfm_data = { - .quirks = SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK, + .quirks = SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK | + SDHCI_QUIRK_NO_HISPD_BIT, .quirks2 = SDHCI_QUIRK2_ACMD23_BROKEN | SDHCI_QUIRK2_HOST_OFF_CARD_ON, .ops = &sdhci_iproc_32only_ops, }; From patchwork Mon May 6 17:01:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Scott Branden X-Patchwork-Id: 10931621 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6C71E14DB for ; Mon, 6 May 2019 17:01:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5964228879 for ; Mon, 6 May 2019 17:01:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4B0052887D; Mon, 6 May 2019 17:01:45 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 E187528877 for ; Mon, 6 May 2019 17:01:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727071AbfEFRBk (ORCPT ); Mon, 6 May 2019 13:01:40 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:36241 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727021AbfEFRBi (ORCPT ); Mon, 6 May 2019 13:01:38 -0400 Received: by mail-pf1-f196.google.com with SMTP id v80so7093616pfa.3 for ; Mon, 06 May 2019 10:01:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=8NEZr+lKEciEtlqvodjs9s9WnuQgHUyLTCz6jchZs+U=; b=I8H0Zyd/6abn7dp3fZUDD5BAADvTaLKVYQyECZWLsA+qoSdkJoPxMGWvXMYSmE+/5G HzeDykXqLtteyK90RTj5aDi0qjBFqibsa+GjQowv7CvI4t4HoQ0B+whnCgg6mnRxPAmq rvEHs/YNkC5QnX8Er4iEBGvy+hpKN/5FlJYqk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=8NEZr+lKEciEtlqvodjs9s9WnuQgHUyLTCz6jchZs+U=; b=We+GXl7tDpudIxryhaGxYa9/MQ8efGRH+E6MuLWbV4yQusvDCi9V7nyS10/WwClTop /BRB+PfFeNWmqBKuLAsLG/z7rRNNnUw+8w9Yik461Ay+ad5agDG13i1Y4HKBn5EjiuJj EwX3QLx9bPxbyxq+sJUdsU8rHFfRnOqyNlFQG156dCTYrOEEwQN95CE9ZxICaoBPc1lC D76cA1iJJFUYuEJzAF5b/wv35us15EHXf5i9ksaRaOCfy/YuQv8bbbvI9RW/NQWPWWdU kl6PzdU+saxKmRK5ROpch+dYPZue7HVRWzlCkh3uXA+H9aGN91oTAVA5FFrsYgn1W4oa zGAg== X-Gm-Message-State: APjAAAV2xZlIVxLaKXgvgAQx7yNgOqSlTfGq0Ch8KzpZzek51irPPRO3 dKgQY830SHuCdLl9icFt39WTNw== X-Google-Smtp-Source: APXvYqyWFjkQJYyagZNhe7lr3N8EEii7ANc4xZeB7K2J92cARdpf2QgOrjQVLq3JRa2QaZrvfBcu2Q== X-Received: by 2002:a63:165f:: with SMTP id 31mr33584426pgw.321.1557162098028; Mon, 06 May 2019 10:01:38 -0700 (PDT) Received: from lbrmn-lnxub113.broadcom.net ([192.19.228.250]) by smtp.gmail.com with ESMTPSA id l23sm4555644pgh.68.2019.05.06.10.01.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 06 May 2019 10:01:37 -0700 (PDT) From: Scott Branden To: Adrian Hunter , Ulf Hansson , Ray Jui , Scott Branden , Stefan Wahren Cc: BCM Kernel Feedback , linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Trac Hoang , Scott Branden Subject: [PATCH 2/2] mmc: sdhci-iproc: Set NO_HISPD bit to fix HS50 data hold time problem Date: Mon, 6 May 2019 10:01:15 -0700 Message-Id: <20190506170115.10840-3-scott.branden@broadcom.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190506170115.10840-1-scott.branden@broadcom.com> References: <20190506170115.10840-1-scott.branden@broadcom.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 From: Trac Hoang The iproc host eMMC/SD controller hold time does not meet the specification in the HS50 mode. This problem can be mitigated by disabling the HISPD bit; thus forcing the controller output data to be driven on the falling clock edges rather than the rising clock edges. Fixes: f5f968f2371c ("mmc: sdhci-iproc: suppress spurious interrupt with Multiblock read") Signed-off-by: Trac Hoang Signed-off-by: Scott Branden --- drivers/mmc/host/sdhci-iproc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c index 9d4071c41c94..2feb4ef32035 100644 --- a/drivers/mmc/host/sdhci-iproc.c +++ b/drivers/mmc/host/sdhci-iproc.c @@ -220,7 +220,8 @@ static const struct sdhci_iproc_data iproc_cygnus_data = { static const struct sdhci_pltfm_data sdhci_iproc_pltfm_data = { .quirks = SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK | - SDHCI_QUIRK_MULTIBLOCK_READ_ACMD12, + SDHCI_QUIRK_MULTIBLOCK_READ_ACMD12 | + SDHCI_QUIRK_NO_HISPD_BIT, .quirks2 = SDHCI_QUIRK2_ACMD23_BROKEN, .ops = &sdhci_iproc_ops, };