Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp2114078ybl; Thu, 29 Aug 2019 03:51:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqwZ3j6ZnEpBfofXd5Xhku6mwymqH0XvpyDFKhoRm3KPXxN1uyIsgbcSDIgthWqIQllDgrc3 X-Received: by 2002:a17:902:bc47:: with SMTP id t7mr9046704plz.329.1567075879493; Thu, 29 Aug 2019 03:51:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567075879; cv=none; d=google.com; s=arc-20160816; b=fipEBXh45g7R3+R///dFkwdi/d/JCgl/UuY+yZOPxSIlEHLF5AvPYVBhqPxzMvtUq7 xWDrrvbVs5W5tL+1Hx3keLNOg7hC3WuUdszfD6rEG2z+SDMLybMHUzHOf484meNV+/ia Vlbggs0F7BXAay7D5FLsbt1bRo1m25kxh5HkB4imiDosdMsH1BZToao+bW8VEDxF8s0/ FoPGTQk3Q7YePmDo+CnSD4WH9oQJM3R9bI6XPmqvOyPsAzbFWMAazgpuL/AwAEs2NzJ7 FLvldhVzxZqnHOuNxLMXMiLdQ+e5Gy3szgpFFVztckcD9RRuEymrE0GLQckXPyUQFRes CG0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=lYozHE89Wu43zYr2OY/wYXUHm6PW8Z5Hu122oF77ydQ=; b=vAzKF3F881Fc5cTz6dYg3u0ulRPJnUJh5xB4o1jbEOrKR8GFIv47igy9jLsPfHhftX +GzpAUJuh8sGTMNhoD+31SE9WvVKXrpYR3XCKbTja/YFGtZiv5DjYMOwFkM8+w290zc8 O1jdqcSqeifSRy93HqEEdeWre5QojroRo2uAw2HFNQaP8Ui5644VnFUJ+IBA5y9QrFIu yEVIdSNsRae0gDgjhQoC+bsNnakSWXTHsCMJXdhmW0psgpsjeaKdgCqpNOC+LR2SJmCa xxY4pQJ6+K1Rc9ea8IwrHispdB7VYWNw0CCN+ZYXdT7DWKs4M2C9SMACdzB8F1e7VVd2 UDyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=DVoeJBCf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e6si1595571plt.276.2019.08.29.03.51.04; Thu, 29 Aug 2019 03:51:19 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=DVoeJBCf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727360AbfH2KuK (ORCPT + 99 others); Thu, 29 Aug 2019 06:50:10 -0400 Received: from conuserg-12.nifty.com ([210.131.2.79]:17272 "EHLO conuserg-12.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726518AbfH2KuJ (ORCPT ); Thu, 29 Aug 2019 06:50:09 -0400 Received: from localhost.localdomain (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-12.nifty.com with ESMTP id x7TAnToh013730; Thu, 29 Aug 2019 19:49:32 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-12.nifty.com x7TAnToh013730 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1567075773; bh=lYozHE89Wu43zYr2OY/wYXUHm6PW8Z5Hu122oF77ydQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DVoeJBCfK1a2SJY98pTQua2p/4ENI6cD/18ReVMUkbiY1fGmE1j20A7KskiM7e887 ZIOs6yhheiTLUdIt2Sm4idniog4XTjm2fGapOO5WtIkFLTxA1npSBXnyEpo2aFIXQK fyYTHLxSIqBjNTAgHoPsrjTCU6YVBeEUbQER5+2nnEhXULrokb8uk8LSE/kPKUBlZK rdBE4rcE35S1QyM9sISGO0SHpngpMeX0mkeOnduXERg5QKKiCr0M5UyOYxZjR9kUFY nwXjo/vlL/myi40n+XsikxPA8E5HRc/O2F3Upuy4/DiMja3fJUiJkr1HBLZFdthiQi GwCM0HYlmUvBg== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: linux-mmc@vger.kernel.org, Adrian Hunter , Ulf Hansson Cc: Piotr Sroka , Masahiro Yamada , linux-kernel@vger.kernel.org Subject: [PATCH 3/3] mmc: sdhci-cadence: override spec version Date: Thu, 29 Aug 2019 19:49:28 +0900 Message-Id: <20190829104928.27404-3-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190829104928.27404-1-yamada.masahiro@socionext.com> References: <20190829104928.27404-1-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The datasheet of the IP (sd4hc) says it is compiatible with SDHCI v4, but the spec version field in the version register is read as 2 (i.e. SDHCI_SPEC_300) based on the RTL provided by Cadence. Socionext did not fix it up when it integrated the IP into the SoCs. So, it is working as SDHCI v3. It is not a real problem because there is no difference in the program flow in sdhci.c between SDHCI_SPEC_300/400, but set the real version just in case. Signed-off-by: Masahiro Yamada --- drivers/mmc/host/sdhci-cadence.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/mmc/host/sdhci-cadence.c b/drivers/mmc/host/sdhci-cadence.c index 44139fceac24..9837214685b6 100644 --- a/drivers/mmc/host/sdhci-cadence.c +++ b/drivers/mmc/host/sdhci-cadence.c @@ -341,6 +341,7 @@ static int sdhci_cdns_probe(struct platform_device *pdev) unsigned int nr_phy_params; int ret; struct device *dev = &pdev->dev; + static const u16 version = SDHCI_SPEC_400 << SDHCI_SPEC_VER_SHIFT; clk = devm_clk_get(dev, NULL); if (IS_ERR(clk)) @@ -370,6 +371,7 @@ static int sdhci_cdns_probe(struct platform_device *pdev) host->mmc_host_ops.hs400_enhanced_strobe = sdhci_cdns_hs400_enhanced_strobe; sdhci_enable_v4_mode(host); + __sdhci_read_caps(host, &version, NULL, NULL); sdhci_get_of_property(pdev); -- 2.17.1