From 6b83588eea77c6fe69c11ba9e5eb2df071b1dadc Mon Sep 17 00:00:00 2001 From: Stephen Warren Date: Tue, 13 Sep 2016 10:45:44 -0600 Subject: mmc: tegra: move pad_init_mmc() into MMC driver pad_init_mmc() is performing an SoC-specific operation, using registers within the MMC controller. There's no reason to implement this code outside the MMC driver, so move it inside the driver. Cc: Jaehoon Chung Signed-off-by: Stephen Warren Signed-off-by: Tom Warren --- arch/arm/include/asm/arch-tegra/tegra_mmc.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'arch/arm/include/asm/arch-tegra/tegra_mmc.h') diff --git a/arch/arm/include/asm/arch-tegra/tegra_mmc.h b/arch/arm/include/asm/arch-tegra/tegra_mmc.h index 07ef4c0..fecb659 100644 --- a/arch/arm/include/asm/arch-tegra/tegra_mmc.h +++ b/arch/arm/include/asm/arch-tegra/tegra_mmc.h @@ -151,7 +151,5 @@ struct mmc_host { struct mmc_config cfg; /* mmc configuration */ }; -void pad_init_mmc(struct mmc_host *host); - #endif /* __ASSEMBLY__ */ #endif /* __TEGRA_MMC_H_ */ -- cgit v1.1 From f53c4e4bbdb8e78a53141a3aec7bc80e7717a475 Mon Sep 17 00:00:00 2001 From: Stephen Warren Date: Tue, 13 Sep 2016 10:45:46 -0600 Subject: mmc: tegra: priv struct and naming cleanup struct mmc_host is a Tegra-specific structure, but the name implies it's something defined by core MMC code, which is confusing. Rename it to struct tegra_mmc_priv to make its purpose more obvious. The new name is also more appropriate for a DM driver private data structure, which will be relevant later in this series. Nothing needs access to this type except the MMC driver itself. Move the definition into the driver C file. Make sure all Tegra MMC functions are named tegra_mmc_*. Even though they're all static, it's useful to have good naming so that symbol tables are easy to interpret. A few functions aren't renamed by this patch since they'll be deleted by a subsequent patch in this series. Cc: Jaehoon Chung Signed-off-by: Stephen Warren Signed-off-by: Tom Warren --- arch/arm/include/asm/arch-tegra/tegra_mmc.h | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'arch/arm/include/asm/arch-tegra/tegra_mmc.h') diff --git a/arch/arm/include/asm/arch-tegra/tegra_mmc.h b/arch/arm/include/asm/arch-tegra/tegra_mmc.h index fecb659..64c848a 100644 --- a/arch/arm/include/asm/arch-tegra/tegra_mmc.h +++ b/arch/arm/include/asm/arch-tegra/tegra_mmc.h @@ -132,24 +132,5 @@ struct tegra_mmc { #define AUTO_CAL_PD_OFFSET (0x70 << 8) #define AUTO_CAL_PU_OFFSET (0x62 << 0) -struct mmc_host { - struct tegra_mmc *reg; - int id; /* device id/number, 0-3 */ - int enabled; /* 1 to enable, 0 to disable */ - int width; /* Bus Width, 1, 4 or 8 */ -#ifdef CONFIG_TEGRA186 - struct reset_ctl reset_ctl; - struct clk clk; -#else - enum periph_id mmc_id; /* Peripheral ID: PERIPH_ID_... */ -#endif - struct gpio_desc cd_gpio; /* Change Detect GPIO */ - struct gpio_desc pwr_gpio; /* Power GPIO */ - struct gpio_desc wp_gpio; /* Write Protect GPIO */ - unsigned int version; /* SDHCI spec. version */ - unsigned int clock; /* Current clock (MHz) */ - struct mmc_config cfg; /* mmc configuration */ -}; - #endif /* __ASSEMBLY__ */ #endif /* __TEGRA_MMC_H_ */ -- cgit v1.1