linux-mmc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: Ulf Hansson <ulf.hansson@linaro.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>,
	Chunyan Zhang <zhang.chunyan@linaro.org>,
	Faiz Abbas <faiz_abbas@ti.com>,
	Kishon Vijay Abraham I <kishon@ti.com>,
	Santosh Shilimkar <ssantosh@kernel.org>,
	linux-mmc@vger.kernel.org, linux-omap@vger.kernel.org
Subject: [PATCH 4/5] mmc: sdhci-omap: Parse legacy ti,non-removable property
Date: Tue, 21 Sep 2021 14:00:28 +0300	[thread overview]
Message-ID: <20210921110029.21944-5-tony@atomide.com> (raw)
In-Reply-To: <20210921110029.21944-1-tony@atomide.com>

We need to support the legacy ti,non-removable property too. Let's warn
about the legacy property and mark the device as non-removable.

Naturally all the mainline kernel devicetree files will get updated to use
the standard non-removable property with the sdhci-omap conversion. But we
also have folks updating their kernels with custom devicetree files that
we need to consider.

Signed-off-by: Tony Lindgren <tony@atomide.com>
---
 drivers/mmc/host/sdhci-omap.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/mmc/host/sdhci-omap.c b/drivers/mmc/host/sdhci-omap.c
--- a/drivers/mmc/host/sdhci-omap.c
+++ b/drivers/mmc/host/sdhci-omap.c
@@ -1213,6 +1213,11 @@ static int sdhci_omap_probe(struct platform_device *pdev)
 	if (of_find_property(dev->of_node, "dmas", NULL))
 		sdhci_switch_external_dma(host, true);
 
+	if (device_property_read_bool(dev, "ti,non-removable")) {
+		dev_warn_once(dev, "using old ti,non-removable property\n");
+		mmc->caps |= MMC_CAP_NONREMOVABLE;
+	}
+
 	/* R1B responses is required to properly manage HW busy detection. */
 	mmc->caps |= MMC_CAP_NEED_RSP_BUSY;
 
-- 
2.33.0

  parent reply	other threads:[~2021-09-21 11:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-21 11:00 [PATCH 0/5] Prepare sdhci-omap to support more SoCs Tony Lindgren
2021-09-21 11:00 ` [PATCH 1/5] mmc: sdhci-omap: Fix NULL pointer exception if regulator is not configured Tony Lindgren
2021-09-21 11:00 ` [PATCH 2/5] mmc: sdhci-omap: Fix context restore Tony Lindgren
2021-09-21 11:00 ` [PATCH 3/5] mmc: sdhci-omap: Restore sysconfig after reset Tony Lindgren
2021-09-21 11:00 ` Tony Lindgren [this message]
2021-09-23 18:42   ` [PATCH 4/5] mmc: sdhci-omap: Parse legacy ti,non-removable property Ulf Hansson
2021-09-24  7:04     ` Tony Lindgren
2021-09-21 11:00 ` [PATCH 5/5] mmc: sdhci-omap: Check MMCHS_HL_HWINFO register for ADMA Tony Lindgren
2021-09-23 18:50 ` [PATCH 0/5] Prepare sdhci-omap to support more SoCs Ulf Hansson
2021-09-24  7:06   ` Tony Lindgren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210921110029.21944-5-tony@atomide.com \
    --to=tony@atomide.com \
    --cc=adrian.hunter@intel.com \
    --cc=faiz_abbas@ti.com \
    --cc=kishon@ti.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=ssantosh@kernel.org \
    --cc=ulf.hansson@linaro.org \
    --cc=zhang.chunyan@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).