[PATCH 06/11] ARM: OMAP2+: gpmc-onenand: Add helper init function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Ladislav Michl <ladis@xxxxxxxxxxxxxx>
---
 arch/arm/mach-omap2/gpmc-onenand.c | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-omap2/gpmc-onenand.c b/arch/arm/mach-omap2/gpmc-onenand.c
index 10e80bdde5ee..2b28cc95dda4 100644
--- a/arch/arm/mach-omap2/gpmc-onenand.c
+++ b/arch/arm/mach-omap2/gpmc-onenand.c
@@ -306,11 +306,8 @@ static int gpmc_onenand_setup(void __iomem *onenand_base, int *freq_ptr)
 	return ret;
 }
 
-int gpmc_onenand_init(struct omap_onenand_platform_data *_onenand_data)
+int gpmc_omap_onenand_init(struct omap_onenand_platform_data *_onenand_data)
 {
-	int err;
-	struct device *dev = &gpmc_onenand_device.dev;
-
 	gpmc_onenand_data = _onenand_data;
 	gpmc_onenand_data->onenand_setup = gpmc_onenand_setup;
 	gpmc_onenand_device.dev.platform_data = gpmc_onenand_data;
@@ -320,6 +317,17 @@ int gpmc_onenand_init(struct omap_onenand_platform_data *_onenand_data)
 	else
 		gpmc_onenand_data->flags &= ~ONENAND_IN_OMAP34XX;
 
+	return 0;
+
+}
+
+int gpmc_onenand_init(struct omap_onenand_platform_data *_onenand_data)
+{
+	int err;
+	struct device *dev = &gpmc_onenand_device.dev;
+
+	gpmc_omap_onenand_init(_onenand_data);
+
 	err = gpmc_cs_request(gpmc_onenand_data->cs, ONENAND_IO_SIZE,
 				(unsigned long *)&gpmc_onenand_resource.start);
 	if (err < 0) {
-- 
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux