colibri_imx6: fix video stdout in default environment
[oweals/u-boot.git] / drivers / mmc / tmio-common.h
index ef9404409d73f39fd3e00e05585256bd9693ee91..9062300c64f7a7df1da62a54c75628591393aad9 100644 (file)
@@ -1,13 +1,13 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
 /*
  * Copyright (C) 2016 Socionext Inc.
  *   Author: Masahiro Yamada <yamada.masahiro@socionext.com>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #ifndef __TMIO_COMMON_H__
 #define __TMIO_COMMON_H__
 
+#include <linux/bitops.h>
 #define TMIO_SD_CMD                    0x000   /* command */
 #define   TMIO_SD_CMD_NOSTOP           BIT(14) /* No automatic CMD12 issue */
 #define   TMIO_SD_CMD_MULTI            BIT(13) /* multiple block transfer */
@@ -118,9 +118,9 @@ struct tmio_sd_plat {
 
 struct tmio_sd_priv {
        void __iomem                    *regbase;
-       unsigned long                   mclk;
        unsigned int                    version;
        u32                             caps;
+       u32                             read_poll_flag;
 #define TMIO_SD_CAP_NONREMOVABLE       BIT(0)  /* Nonremovable e.g. eMMC */
 #define TMIO_SD_CAP_DMA_INTERNAL       BIT(1)  /* have internal DMA engine */
 #define TMIO_SD_CAP_DIV1024            BIT(2)  /* divisor 1024 is available */
@@ -134,6 +134,23 @@ struct tmio_sd_priv {
 #ifdef CONFIG_DM_REGULATOR
        struct udevice *vqmmc_dev;
 #endif
+#if CONFIG_IS_ENABLED(CLK)
+       struct clk                      clk;
+#endif
+#if CONFIG_IS_ENABLED(RENESAS_SDHI)
+       unsigned int                    smpcmp;
+       u8                              tap_set;
+       u8                              tap_num;
+       u8                              nrtaps;
+       bool                            needs_adjust_hs400;
+       bool                            adjust_hs400_enable;
+       u8                              adjust_hs400_offset;
+       u8                              adjust_hs400_calibrate;
+       u8                              hs400_bad_tap;
+       const u8                        *adjust_hs400_calib_table;
+       u32                     quirks;
+#endif
+       ulong (*clk_get_rate)(struct tmio_sd_priv *);
 };
 
 int tmio_sd_send_cmd(struct udevice *dev, struct mmc_cmd *cmd,