summaryrefslogtreecommitdiff
path: root/drivers/mmc/host/sdhci-xenon.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/host/sdhci-xenon.h')
-rw-r--r--drivers/mmc/host/sdhci-xenon.h21
1 files changed, 15 insertions, 6 deletions
diff --git a/drivers/mmc/host/sdhci-xenon.h b/drivers/mmc/host/sdhci-xenon.h
index 73debb42dc2f..0460d97aad26 100644
--- a/drivers/mmc/host/sdhci-xenon.h
+++ b/drivers/mmc/host/sdhci-xenon.h
@@ -1,12 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
/*
* Copyright (C) 2016 Marvell, All Rights Reserved.
*
* Author: Hu Ziji <huziji@marvell.com>
* Date: 2016-8-24
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation version 2.
*/
#ifndef SDHCI_XENON_H_
#define SDHCI_XENON_H_
@@ -33,6 +30,7 @@
#define XENON_TUNING_STEP_DIVIDER BIT(6)
#define XENON_SLOT_EMMC_CTRL 0x0130
+#define XENON_ENABLE_RESP_STROBE BIT(25)
#define XENON_ENABLE_DATA_STROBE BIT(24)
#define XENON_SLOT_RETUNING_REQ_CTRL 0x0144
@@ -55,6 +53,14 @@
#define XENON_CTRL_HS200 0x5
#define XENON_CTRL_HS400 0x6
+enum xenon_variant {
+ XENON_A3700,
+ XENON_AP806,
+ XENON_AP807,
+ XENON_CP110,
+ XENON_AC5
+};
+
struct xenon_priv {
unsigned char tuning_count;
/* idx of SDHC */
@@ -82,6 +88,7 @@ struct xenon_priv {
unsigned char bus_width;
unsigned char timing;
unsigned int clock;
+ struct clk *axi_clk;
int phy_type;
/*
@@ -90,11 +97,13 @@ struct xenon_priv {
*/
void *phy_params;
struct xenon_emmc_phy_regs *emmc_phy_regs;
+ bool restore_needed;
+ enum xenon_variant hw_version;
};
int xenon_phy_adj(struct sdhci_host *host, struct mmc_ios *ios);
-int xenon_phy_parse_dt(struct device_node *np,
- struct sdhci_host *host);
+int xenon_phy_parse_params(struct device *dev,
+ struct sdhci_host *host);
void xenon_soc_pad_ctrl(struct sdhci_host *host,
unsigned char signal_voltage);
#endif