All of lore.kernel.org
 help / color / mirror / Atom feed
* mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-28  4:44 ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:44 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, Kuninori Morimoto, linux-mmc


Hi Chris

These patches updates code for R-Car.
Basically, these clarifies chip dependent settings
inside driver, and, removed unneeded settings from dtsi file.
These are based on latest linus/master branch
(ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)

Kuninori Morimoto (4):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790

 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
 arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
 arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
 arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
 drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
 5 files changed, 31 insertions(+), 32 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-28  4:44 ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:44 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, Kuninori Morimoto, linux-mmc


Hi Chris

These patches updates code for R-Car.
Basically, these clarifies chip dependent settings
inside driver, and, removed unneeded settings from dtsi file.
These are based on latest linus/master branch
(ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)

Kuninori Morimoto (4):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790

 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
 arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
 arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
 arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
 drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
 5 files changed, 31 insertions(+), 32 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-28  4:45   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 2d6ce25..8901acd 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id -- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
@ 2014-01-28  4:45   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 2d6ce25..8901acd 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id =
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-28  4:45   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
 arch/arm/boot/dts/r8a7778.dtsi                |    6 ------
 drivers/mmc/host/sh_mobile_sdhi.c             |    9 ++++++++-
 3 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
index bb62c7a..06cda19 100644
--- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
+++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
@@ -17,6 +17,7 @@
 /dts-v1/;
 #include "r8a7778.dtsi"
 #include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "bockw";
@@ -84,7 +85,7 @@
 
 	sdhi0_pins: sd0 {
 		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
-				  "sdhi0_cd", "sdhi0_wp";
+				  "sdhi0_cd";
 		renesas,function = "sdhi0";
 	};
 
@@ -101,6 +102,7 @@
 	vmmc-supply = <&fixedregulator3v3>;
 	bus-width = <4>;
 	status = "okay";
+	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
 };
 
 &hspi0 {
diff --git a/arch/arm/boot/dts/r8a7778.dtsi b/arch/arm/boot/dts/r8a7778.dtsi
index ddb3bd7..c309430 100644
--- a/arch/arm/boot/dts/r8a7778.dtsi
+++ b/arch/arm/boot/dts/r8a7778.dtsi
@@ -178,8 +178,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 87 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -188,8 +186,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 88 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -198,8 +194,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 86 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 8901acd..6442286 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
@ 2014-01-28  4:45   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
 arch/arm/boot/dts/r8a7778.dtsi                |    6 ------
 drivers/mmc/host/sh_mobile_sdhi.c             |    9 ++++++++-
 3 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
index bb62c7a..06cda19 100644
--- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
+++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
@@ -17,6 +17,7 @@
 /dts-v1/;
 #include "r8a7778.dtsi"
 #include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "bockw";
@@ -84,7 +85,7 @@
 
 	sdhi0_pins: sd0 {
 		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
-				  "sdhi0_cd", "sdhi0_wp";
+				  "sdhi0_cd";
 		renesas,function = "sdhi0";
 	};
 
@@ -101,6 +102,7 @@
 	vmmc-supply = <&fixedregulator3v3>;
 	bus-width = <4>;
 	status = "okay";
+	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
 };
 
 &hspi0 {
diff --git a/arch/arm/boot/dts/r8a7778.dtsi b/arch/arm/boot/dts/r8a7778.dtsi
index ddb3bd7..c309430 100644
--- a/arch/arm/boot/dts/r8a7778.dtsi
+++ b/arch/arm/boot/dts/r8a7778.dtsi
@@ -178,8 +178,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 87 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -188,8 +186,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 88 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -198,8 +194,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 86 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 8901acd..6442286 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-28  4:45   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7779.dtsi    |    8 --------
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 2 files changed, 1 insertion(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7779.dtsi b/arch/arm/boot/dts/r8a7779.dtsi
index d0561d4..2105059 100644
--- a/arch/arm/boot/dts/r8a7779.dtsi
+++ b/arch/arm/boot/dts/r8a7779.dtsi
@@ -220,8 +220,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 104 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -230,8 +228,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 105 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -240,8 +236,6 @@
 		reg = <0xffe4e000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -250,8 +244,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 106 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 6442286..322cd35 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
@ 2014-01-28  4:45   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7779.dtsi    |    8 --------
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 2 files changed, 1 insertion(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7779.dtsi b/arch/arm/boot/dts/r8a7779.dtsi
index d0561d4..2105059 100644
--- a/arch/arm/boot/dts/r8a7779.dtsi
+++ b/arch/arm/boot/dts/r8a7779.dtsi
@@ -220,8 +220,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 104 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -230,8 +228,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 105 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -240,8 +236,6 @@
 		reg = <0xffe4e000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -250,8 +244,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 106 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 6442286..322cd35 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-28  4:45   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7790.dtsi    |    4 ----
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index f48487c..df578cd 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -265,7 +265,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 165 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI0>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -275,7 +274,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 166 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI1>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -285,7 +283,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 167 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI2>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -295,7 +292,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 168 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI3>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 322cd35..7498f5b 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
@ 2014-01-28  4:45   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-28  4:45 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.
Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch disables it as default,
but we can use wp-gpios property to enable it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7790.dtsi    |    4 ----
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index f48487c..df578cd 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -265,7 +265,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 165 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI0>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -275,7 +274,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 166 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI1>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -285,7 +283,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 167 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI2>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -295,7 +292,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 168 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI3>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 322cd35..7498f5b 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-28 16:06   ` Sergei Shtylyov
  -1 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-01-28 15:06 UTC (permalink / raw)
  To: Kuninori Morimoto, Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hello.

On 01/28/2014 07:44 AM, Kuninori Morimoto wrote:

> Hi Chris

> These patches updates code for R-Car.
> Basically, these clarifies chip dependent settings
> inside driver, and, removed unneeded settings from dtsi file.
> These are based on latest linus/master branch
> (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)

> Kuninori Morimoto (4):
>        mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790

    s/updata/update/.

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-28 16:06   ` Sergei Shtylyov
  0 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-01-28 16:06 UTC (permalink / raw)
  To: Kuninori Morimoto, Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hello.

On 01/28/2014 07:44 AM, Kuninori Morimoto wrote:

> Hi Chris

> These patches updates code for R-Car.
> Basically, these clarifies chip dependent settings
> inside driver, and, removed unneeded settings from dtsi file.
> These are based on latest linus/master branch
> (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)

> Kuninori Morimoto (4):
>        mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
>        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790

    s/updata/update/.

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28 16:06   ` Sergei Shtylyov
@ 2014-01-29  0:31     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-29  0:31 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Simon, Chris Ball, Magnus, Linux-SH, linux-mmc


Hi Sergei, Chris

Thank you for your review

> > Kuninori Morimoto (4):
> >        mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> 
>     s/updata/update/.

Grr..
I need to buy new English dictionary

>> Chris

I will send v2 patch after your review
Please let me know the result

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-29  0:31     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-29  0:31 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Simon, Chris Ball, Magnus, Linux-SH, linux-mmc


Hi Sergei, Chris

Thank you for your review

> > Kuninori Morimoto (4):
> >        mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
> >        mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> 
>     s/updata/update/.

Grr..
I need to buy new English dictionary

>> Chris

I will send v2 patch after your review
Please let me know the result

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-30  5:38   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-30  5:38 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc


Hi Chris, Simon

> These patches updates code for R-Car.
> Basically, these clarifies chip dependent settings
> inside driver, and, removed unneeded settings from dtsi file.
> These are based on latest linus/master branch
> (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> 
>  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
>  arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
>  arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
>  arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
>  drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
>  5 files changed, 31 insertions(+), 32 deletions(-)

These patches modify both mmc driver and sh-arm.
Should I separate these ?
Or Chris can apply these with Simon's Ack ?

Basically, modify both files are the best way,
but it is possible to separate


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-30  5:38   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-30  5:38 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc


Hi Chris, Simon

> These patches updates code for R-Car.
> Basically, these clarifies chip dependent settings
> inside driver, and, removed unneeded settings from dtsi file.
> These are based on latest linus/master branch
> (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> 
>  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
>  arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
>  arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
>  arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
>  drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
>  5 files changed, 31 insertions(+), 32 deletions(-)

These patches modify both mmc driver and sh-arm.
Should I separate these ?
Or Chris can apply these with Simon's Ack ?

Basically, modify both files are the best way,
but it is possible to separate


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-30  5:38   ` Kuninori Morimoto
@ 2014-01-30  6:43     ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-01-30  6:43 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Jan 29, 2014 at 09:38:02PM -0800, Kuninori Morimoto wrote:
> 
> Hi Chris, Simon
> 
> > These patches updates code for R-Car.
> > Basically, these clarifies chip dependent settings
> > inside driver, and, removed unneeded settings from dtsi file.
> > These are based on latest linus/master branch
> > (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)
> > 
> > Kuninori Morimoto (4):
> >       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> > 
> >  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
> >  arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
> >  arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
> >  arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
> >  drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
> >  5 files changed, 31 insertions(+), 32 deletions(-)
> 
> These patches modify both mmc driver and sh-arm.
> Should I separate these ?
> Or Chris can apply these with Simon's Ack ?
> 
> Basically, modify both files are the best way,
> but it is possible to separate

Hi Morimoto-san,

Previously I was somewhat ambivalent to this but experience has shown me
that taking shmobile patches through my tree is best. The reason is that it
reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
third parties, such as Linus. And we want to make the lives of those people
as easy as possible.

So please make sure that the patches are split up such that there are
patches for the driver and patches for shmobile.  Ideally post them in
separate series but if you prefer they can go in a single series. But
regardless please note that the driver patches are for the driver
maintainer to pick up and the shmobile patches are for me.

I hope this clarifies things for you.

Thanks

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-30  6:43     ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-01-30  6:43 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Jan 29, 2014 at 09:38:02PM -0800, Kuninori Morimoto wrote:
> 
> Hi Chris, Simon
> 
> > These patches updates code for R-Car.
> > Basically, these clarifies chip dependent settings
> > inside driver, and, removed unneeded settings from dtsi file.
> > These are based on latest linus/master branch
> > (ba635f8cd20ebc7bddf1eb8e1f4eae28a034e916)
> > 
> > Kuninori Morimoto (4):
> >       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779
> >       mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790
> > 
> >  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 ++-
> >  arch/arm/boot/dts/r8a7778.dtsi                |    6 ----
> >  arch/arm/boot/dts/r8a7779.dtsi                |    8 -----
> >  arch/arm/boot/dts/r8a7790.dtsi                |    4 ---
> >  drivers/mmc/host/sh_mobile_sdhi.c             |   41 +++++++++++++++++--------
> >  5 files changed, 31 insertions(+), 32 deletions(-)
> 
> These patches modify both mmc driver and sh-arm.
> Should I separate these ?
> Or Chris can apply these with Simon's Ack ?
> 
> Basically, modify both files are the best way,
> but it is possible to separate

Hi Morimoto-san,

Previously I was somewhat ambivalent to this but experience has shown me
that taking shmobile patches through my tree is best. The reason is that it
reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
third parties, such as Linus. And we want to make the lives of those people
as easy as possible.

So please make sure that the patches are split up such that there are
patches for the driver and patches for shmobile.  Ideally post them in
separate series but if you prefer they can go in a single series. But
regardless please note that the driver patches are for the driver
maintainer to pick up and the shmobile patches are for me.

I hope this clarifies things for you.

Thanks

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-30  6:43     ` Simon Horman
@ 2014-01-30  7:08       ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-30  7:08 UTC (permalink / raw)
  To: Simon Horman; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc


Hi Simon, Chris

> Previously I was somewhat ambivalent to this but experience has shown me
> that taking shmobile patches through my tree is best. The reason is that it
> reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
> third parties, such as Linus. And we want to make the lives of those people
> as easy as possible.
> 
> So please make sure that the patches are split up such that there are
> patches for the driver and patches for shmobile.  Ideally post them in
> separate series but if you prefer they can go in a single series. But
> regardless please note that the driver patches are for the driver
> maintainer to pick up and the shmobile patches are for me.

Thank you !
OK, I will do my best

I would like to get Chris's review
before sending v2 patch if possible.

Best regards
---
Kuninori Morimoto

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-30  7:08       ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-30  7:08 UTC (permalink / raw)
  To: Simon Horman; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc


Hi Simon, Chris

> Previously I was somewhat ambivalent to this but experience has shown me
> that taking shmobile patches through my tree is best. The reason is that it
> reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
> third parties, such as Linus. And we want to make the lives of those people
> as easy as possible.
> 
> So please make sure that the patches are split up such that there are
> patches for the driver and patches for shmobile.  Ideally post them in
> separate series but if you prefer they can go in a single series. But
> regardless please note that the driver patches are for the driver
> maintainer to pick up and the shmobile patches are for me.

Thank you !
OK, I will do my best

I would like to get Chris's review
before sending v2 patch if possible.

Best regards
---
Kuninori Morimoto

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-30  7:08       ` Kuninori Morimoto
@ 2014-01-31  0:16         ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-01-31  0:16 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Jan 29, 2014 at 11:08:00PM -0800, Kuninori Morimoto wrote:
> 
> Hi Simon, Chris
> 
> > Previously I was somewhat ambivalent to this but experience has shown me
> > that taking shmobile patches through my tree is best. The reason is that it
> > reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
> > third parties, such as Linus. And we want to make the lives of those people
> > as easy as possible.
> > 
> > So please make sure that the patches are split up such that there are
> > patches for the driver and patches for shmobile.  Ideally post them in
> > separate series but if you prefer they can go in a single series. But
> > regardless please note that the driver patches are for the driver
> > maintainer to pick up and the shmobile patches are for me.
> 
> Thank you !
> OK, I will do my best
> 
> I would like to get Chris's review
> before sending v2 patch if possible.

That is fine by me :)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-31  0:16         ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-01-31  0:16 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Jan 29, 2014 at 11:08:00PM -0800, Kuninori Morimoto wrote:
> 
> Hi Simon, Chris
> 
> > Previously I was somewhat ambivalent to this but experience has shown me
> > that taking shmobile patches through my tree is best. The reason is that it
> > reduces (eliminates?) merge conflicts. Conflicts that have to be resolved by
> > third parties, such as Linus. And we want to make the lives of those people
> > as easy as possible.
> > 
> > So please make sure that the patches are split up such that there are
> > patches for the driver and patches for shmobile.  Ideally post them in
> > separate series but if you prefer they can go in a single series. But
> > regardless please note that the driver patches are for the driver
> > maintainer to pick up and the shmobile patches are for me.
> 
> Thank you !
> OK, I will do my best
> 
> I would like to get Chris's review
> before sending v2 patch if possible.

That is fine by me :)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-31  5:30   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:30 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hi Chris, Simon

These are v2 of updates code for R-Car.
I separated v1 patches into for mmc, and for SH-ARM.
This is "mmc" part patches.

Kuninori Morimoto (4):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790

 drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
 1 file changed, 28 insertions(+), 13 deletions(-)
)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-31  5:30   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:30 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hi Chris, Simon

These are v2 of updates code for R-Car.
I separated v1 patches into for mmc, and for SH-ARM.
This is "mmc" part patches.

Kuninori Morimoto (4):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790

 drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
 1 file changed, 28 insertions(+), 13 deletions(-)
)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-01-31  5:31     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:31 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 2d6ce25..8901acd 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id -- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
@ 2014-01-31  5:31     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:31 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 2d6ce25..8901acd 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id =
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-01-31  5:31     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:31 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 8901acd..6442286 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
@ 2014-01-31  5:31     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:31 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 8901acd..6442286 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-01-31  5:32     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:32 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 6442286..322cd35 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
@ 2014-01-31  5:32     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:32 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 6442286..322cd35 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-01-31  5:32     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:32 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 322cd35..7498f5b 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-01-31  5:32     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:32 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 322cd35..7498f5b 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-31  5:36   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hi Simon

These are v2 of updates code for R-Car.
I separated v1 patches into for mmc, and for SH-ARM.
This is "SH-ARM" part patches.

These need my previous mmc part patches.

Kuninori Morimoto (3):
      ARM: shmobile: r8a7778: removed unnecessary mmc option
      ARM: shmobile: r8a7779: removed unnecessary mmc option
      ARM: shmobile: r8a7790: removed unnecessary mmc option

 arch/arm/boot/dts/r8a7778.dtsi |    6 ------
 arch/arm/boot/dts/r8a7779.dtsi |    8 --------
 arch/arm/boot/dts/r8a7790.dtsi |    4 ----
 3 files changed, 18 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-01-31  5:36   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hi Simon

These are v2 of updates code for R-Car.
I separated v1 patches into for mmc, and for SH-ARM.
This is "SH-ARM" part patches.

These need my previous mmc part patches.

Kuninori Morimoto (3):
      ARM: shmobile: r8a7778: removed unnecessary mmc option
      ARM: shmobile: r8a7779: removed unnecessary mmc option
      ARM: shmobile: r8a7790: removed unnecessary mmc option

 arch/arm/boot/dts/r8a7778.dtsi |    6 ------
 arch/arm/boot/dts/r8a7779.dtsi |    8 --------
 arch/arm/boot/dts/r8a7790.dtsi |    4 ----
 3 files changed, 18 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 1/3] ARM: shmobile: r8a7778: removed unnecessary mmc option
  2014-01-31  5:36   ` Kuninori Morimoto
@ 2014-01-31  5:36     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7778 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7778.dtsi |    6 ------
 1 file changed, 6 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7778.dtsi b/arch/arm/boot/dts/r8a7778.dtsi
index ddb3bd7..c309430 100644
--- a/arch/arm/boot/dts/r8a7778.dtsi
+++ b/arch/arm/boot/dts/r8a7778.dtsi
@@ -178,8 +178,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 87 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -188,8 +186,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 88 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -198,8 +194,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 86 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 1/3] ARM: shmobile: r8a7778: removed unnecessary mmc option
@ 2014-01-31  5:36     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7778 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7778.dtsi |    6 ------
 1 file changed, 6 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7778.dtsi b/arch/arm/boot/dts/r8a7778.dtsi
index ddb3bd7..c309430 100644
--- a/arch/arm/boot/dts/r8a7778.dtsi
+++ b/arch/arm/boot/dts/r8a7778.dtsi
@@ -178,8 +178,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 87 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -188,8 +186,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 88 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -198,8 +194,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 86 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/3] ARM: shmobile: r8a7779: removed unnecessary mmc option
  2014-01-31  5:36   ` Kuninori Morimoto
@ 2014-01-31  5:36     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7779 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7779.dtsi |    8 --------
 1 file changed, 8 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7779.dtsi b/arch/arm/boot/dts/r8a7779.dtsi
index d0561d4..2105059 100644
--- a/arch/arm/boot/dts/r8a7779.dtsi
+++ b/arch/arm/boot/dts/r8a7779.dtsi
@@ -220,8 +220,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 104 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -230,8 +228,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 105 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -240,8 +236,6 @@
 		reg = <0xffe4e000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -250,8 +244,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 106 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/3] ARM: shmobile: r8a7779: removed unnecessary mmc option
@ 2014-01-31  5:36     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7779 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7779.dtsi |    8 --------
 1 file changed, 8 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7779.dtsi b/arch/arm/boot/dts/r8a7779.dtsi
index d0561d4..2105059 100644
--- a/arch/arm/boot/dts/r8a7779.dtsi
+++ b/arch/arm/boot/dts/r8a7779.dtsi
@@ -220,8 +220,6 @@
 		reg = <0xffe4c000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 104 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -230,8 +228,6 @@
 		reg = <0xffe4d000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 105 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -240,8 +236,6 @@
 		reg = <0xffe4e000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
@@ -250,8 +244,6 @@
 		reg = <0xffe4f000 0x100>;
 		interrupt-parent = <&gic>;
 		interrupts = <0 106 IRQ_TYPE_LEVEL_HIGH>;
-		cap-sd-highspeed;
-		cap-sdio-irq;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/3] ARM: shmobile: r8a7790: removed unnecessary mmc option
  2014-01-31  5:36   ` Kuninori Morimoto
@ 2014-01-31  5:36     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7790 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7790.dtsi |    4 ----
 1 file changed, 4 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index f48487c..df578cd 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -265,7 +265,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 165 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI0>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -275,7 +274,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 166 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI1>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -285,7 +283,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 167 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI2>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -295,7 +292,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 168 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI3>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/3] ARM: shmobile: r8a7790: removed unnecessary mmc option
@ 2014-01-31  5:36     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:36 UTC (permalink / raw)
  To: Simon; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

r8a7790 specific MMC options are cared by driver.
This driver removes these from DTSI

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/boot/dts/r8a7790.dtsi |    4 ----
 1 file changed, 4 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index f48487c..df578cd 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -265,7 +265,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 165 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI0>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -275,7 +274,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 166 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI1>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -285,7 +283,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 167 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI2>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
@@ -295,7 +292,6 @@
 		interrupt-parent = <&gic>;
 		interrupts = <0 168 IRQ_TYPE_LEVEL_HIGH>;
 		clocks = <&mstp3_clks R8A7790_CLK_SDHI3>;
-		cap-sd-highspeed;
 		status = "disabled";
 	};
 
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-01-31  5:39   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:39 UTC (permalink / raw)
  To: Simon; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch decides new policy whch indicates
WP is disabled as default.
But, we can use wp-gpios property to enable it as
other method.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
Simon

This was included on v1 patch series,
but no relationship with mmc part patches.

 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
index bb62c7a..06cda19 100644
--- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
+++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
@@ -17,6 +17,7 @@
 /dts-v1/;
 #include "r8a7778.dtsi"
 #include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "bockw";
@@ -84,7 +85,7 @@
 
 	sdhi0_pins: sd0 {
 		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
-				  "sdhi0_cd", "sdhi0_wp";
+				  "sdhi0_cd";
 		renesas,function = "sdhi0";
 	};
 
@@ -101,6 +102,7 @@
 	vmmc-supply = <&fixedregulator3v3>;
 	bus-width = <4>;
 	status = "okay";
+	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
 };
 
 &hspi0 {
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
@ 2014-01-31  5:39   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-01-31  5:39 UTC (permalink / raw)
  To: Simon; +Cc: Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Latest Renesas Chip has some SDHI channels and the WP pin
availability depends on its channel or HW implementation.
Thus, this patch decides new policy whch indicates
WP is disabled as default.
But, we can use wp-gpios property to enable it as
other method.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
Simon

This was included on v1 patch series,
but no relationship with mmc part patches.

 arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
index bb62c7a..06cda19 100644
--- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
+++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
@@ -17,6 +17,7 @@
 /dts-v1/;
 #include "r8a7778.dtsi"
 #include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "bockw";
@@ -84,7 +85,7 @@
 
 	sdhi0_pins: sd0 {
 		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
-				  "sdhi0_cd", "sdhi0_wp";
+				  "sdhi0_cd";
 		renesas,function = "sdhi0";
 	};
 
@@ -101,6 +102,7 @@
 	vmmc-supply = <&fixedregulator3v3>;
 	bus-width = <4>;
 	status = "okay";
+	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
 };
 
 &hspi0 {
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* Re: [PATCH 3/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
  2014-01-31  5:32     ` Kuninori Morimoto
@ 2014-01-31 12:46       ` Sergei Shtylyov
  -1 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-01-31 12:46 UTC (permalink / raw)
  To: Kuninori Morimoto, Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hello.

On 31-01-2014 9:32, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7779 DT data to have SoC specific settings.

> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 6442286..322cd35 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>   	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
>   	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
>   	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
> -	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
> +	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },

    I'd merge this to the previous patch.

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 3/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
@ 2014-01-31 12:46       ` Sergei Shtylyov
  0 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-01-31 12:46 UTC (permalink / raw)
  To: Kuninori Morimoto, Simon, Chris Ball; +Cc: Magnus, Linux-SH, linux-mmc

Hello.

On 31-01-2014 9:32, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7779 DT data to have SoC specific settings.

> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 6442286..322cd35 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>   	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
>   	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
>   	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
> -	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
> +	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },

    I'd merge this to the previous patch.

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-31  5:36   ` Kuninori Morimoto
@ 2014-02-03  6:34     ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:34 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:36:06PM -0800, Kuninori Morimoto wrote:
> Hi Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "SH-ARM" part patches.
> 
> These need my previous mmc part patches.

Thanks Morimoto-san,

could you please repost these patches once the driver
patches are present in an rc release?

Thanks

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-02-03  6:34     ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:34 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:36:06PM -0800, Kuninori Morimoto wrote:
> Hi Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "SH-ARM" part patches.
> 
> These need my previous mmc part patches.

Thanks Morimoto-san,

could you please repost these patches once the driver
patches are present in an rc release?

Thanks

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
  2014-01-31  5:39   ` Kuninori Morimoto
@ 2014-02-03  6:35     ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:35 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:39:40PM -0800, Kuninori Morimoto wrote:
> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> 
> Latest Renesas Chip has some SDHI channels and the WP pin
> availability depends on its channel or HW implementation.
> Thus, this patch decides new policy whch indicates
> WP is disabled as default.
> But, we can use wp-gpios property to enable it as
> other method.
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
> Simon
> 
> This was included on v1 patch series,
> but no relationship with mmc part patches.

So I could take this patch into the renesas tree now?

> 
>  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> index bb62c7a..06cda19 100644
> --- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> +++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> @@ -17,6 +17,7 @@
>  /dts-v1/;
>  #include "r8a7778.dtsi"
>  #include <dt-bindings/interrupt-controller/irq.h>
> +#include <dt-bindings/gpio/gpio.h>
>  
>  / {
>  	model = "bockw";
> @@ -84,7 +85,7 @@
>  
>  	sdhi0_pins: sd0 {
>  		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
> -				  "sdhi0_cd", "sdhi0_wp";
> +				  "sdhi0_cd";
>  		renesas,function = "sdhi0";
>  	};
>  
> @@ -101,6 +102,7 @@
>  	vmmc-supply = <&fixedregulator3v3>;
>  	bus-width = <4>;
>  	status = "okay";
> +	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
>  };
>  
>  &hspi0 {
> -- 
> 1.7.9.5
> 

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
@ 2014-02-03  6:35     ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:35 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:39:40PM -0800, Kuninori Morimoto wrote:
> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> 
> Latest Renesas Chip has some SDHI channels and the WP pin
> availability depends on its channel or HW implementation.
> Thus, this patch decides new policy whch indicates
> WP is disabled as default.
> But, we can use wp-gpios property to enable it as
> other method.
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
> Simon
> 
> This was included on v1 patch series,
> but no relationship with mmc part patches.

So I could take this patch into the renesas tree now?

> 
>  arch/arm/boot/dts/r8a7778-bockw-reference.dts |    4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/r8a7778-bockw-reference.dts b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> index bb62c7a..06cda19 100644
> --- a/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> +++ b/arch/arm/boot/dts/r8a7778-bockw-reference.dts
> @@ -17,6 +17,7 @@
>  /dts-v1/;
>  #include "r8a7778.dtsi"
>  #include <dt-bindings/interrupt-controller/irq.h>
> +#include <dt-bindings/gpio/gpio.h>
>  
>  / {
>  	model = "bockw";
> @@ -84,7 +85,7 @@
>  
>  	sdhi0_pins: sd0 {
>  		renesas,groups = "sdhi0_data4", "sdhi0_ctrl",
> -				  "sdhi0_cd", "sdhi0_wp";
> +				  "sdhi0_cd";
>  		renesas,function = "sdhi0";
>  	};
>  
> @@ -101,6 +102,7 @@
>  	vmmc-supply = <&fixedregulator3v3>;
>  	bus-width = <4>;
>  	status = "okay";
> +	wp-gpios = <&gpio3 18 GPIO_ACTIVE_HIGH>;
>  };
>  
>  &hspi0 {
> -- 
> 1.7.9.5
> 

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-02-03  6:41     ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:41 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> Hi Chris, Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "mmc" part patches.
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------

I agree with Sergei that patches 2 and 3 could be consolidated,
but I also don't feel strongly about it, so please use your best judgement
there.

Acked-by: Simon Horman <horms+renesas@verge.net.au>


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-02-03  6:41     ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-03  6:41 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> Hi Chris, Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "mmc" part patches.
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------

I agree with Sergei that patches 2 and 3 could be consolidated,
but I also don't feel strongly about it, so please use your best judgement
there.

Acked-by: Simon Horman <horms+renesas@verge.net.au>


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
  2014-02-03  6:35     ` Simon Horman
@ 2014-02-04  1:32       ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-04  1:32 UTC (permalink / raw)
  To: Simon Horman; +Cc: Magnus, Linux-SH, linux-mmc


Hi Simon

> > Latest Renesas Chip has some SDHI channels and the WP pin
> > availability depends on its channel or HW implementation.
> > Thus, this patch decides new policy whch indicates
> > WP is disabled as default.
> > But, we can use wp-gpios property to enable it as
> > other method.
> > 
> > Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> > ---
> > Simon
> > 
> > This was included on v1 patch series,
> > but no relationship with mmc part patches.
> 
> So I could take this patch into the renesas tree now?

Yes, I guess so

# my PC broken this morning somehow...

Best regards
---
Kuninori Morimoto

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
@ 2014-02-04  1:32       ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-04  1:32 UTC (permalink / raw)
  To: Simon Horman; +Cc: Magnus, Linux-SH, linux-mmc


Hi Simon

> > Latest Renesas Chip has some SDHI channels and the WP pin
> > availability depends on its channel or HW implementation.
> > Thus, this patch decides new policy whch indicates
> > WP is disabled as default.
> > But, we can use wp-gpios property to enable it as
> > other method.
> > 
> > Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> > ---
> > Simon
> > 
> > This was included on v1 patch series,
> > but no relationship with mmc part patches.
> 
> So I could take this patch into the renesas tree now?

Yes, I guess so

# my PC broken this morning somehow...

Best regards
---
Kuninori Morimoto

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
  2014-02-04  1:32       ` Kuninori Morimoto
@ 2014-02-06  6:59         ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-06  6:59 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Magnus, Linux-SH, linux-mmc

On Mon, Feb 03, 2014 at 05:32:08PM -0800, Kuninori Morimoto wrote:
> 
> Hi Simon
> 
> > > Latest Renesas Chip has some SDHI channels and the WP pin
> > > availability depends on its channel or HW implementation.
> > > Thus, this patch decides new policy whch indicates
> > > WP is disabled as default.
> > > But, we can use wp-gpios property to enable it as
> > > other method.
> > > 
> > > Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> > > ---
> > > Simon
> > > 
> > > This was included on v1 patch series,
> > > but no relationship with mmc part patches.
> > 
> > So I could take this patch into the renesas tree now?
> 
> Yes, I guess so

Thanks, I have queued this up.

> 
> # my PC broken this morning somehow...

Ouch

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin
@ 2014-02-06  6:59         ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-06  6:59 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Magnus, Linux-SH, linux-mmc

On Mon, Feb 03, 2014 at 05:32:08PM -0800, Kuninori Morimoto wrote:
> 
> Hi Simon
> 
> > > Latest Renesas Chip has some SDHI channels and the WP pin
> > > availability depends on its channel or HW implementation.
> > > Thus, this patch decides new policy whch indicates
> > > WP is disabled as default.
> > > But, we can use wp-gpios property to enable it as
> > > other method.
> > > 
> > > Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> > > ---
> > > Simon
> > > 
> > > This was included on v1 patch series,
> > > but no relationship with mmc part patches.
> > 
> > So I could take this patch into the renesas tree now?
> 
> Yes, I guess so

Thanks, I have queued this up.

> 
> # my PC broken this morning somehow...

Ouch

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 5/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-02-12  5:35     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-12  5:35 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7791 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
>> Chris

I add this patch to my previous
"Re: mmc: sh_mobile_sdhi: DT update for R-Car" patch-set as [5/4]
Please let me know if you want re-send these patch-set again

 drivers/mmc/host/sh_mobile_sdhi.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 1622b03..d54169f 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -65,6 +65,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
+	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 5/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
@ 2014-02-12  5:35     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-12  5:35 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7791 DT data to have SoC specific settings.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
>> Chris

I add this patch to my previous
"Re: mmc: sh_mobile_sdhi: DT update for R-Car" patch-set as [5/4]
Please let me know if you want re-send these patch-set again

 drivers/mmc/host/sh_mobile_sdhi.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 1622b03..d54169f 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -65,6 +65,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
+	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* Re: [PATCH 5/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
  2014-02-12  5:35     ` Kuninori Morimoto
@ 2014-02-12  8:38       ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  8:38 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Tue, Feb 11, 2014 at 09:35:50PM -0800, Kuninori Morimoto wrote:
> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> 
> This patch updates r8a7791 DT data to have SoC specific settings.
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Acked-by: Simon Horman <horms+renesas@verge.net.au>


> ---
> >> Chris
> 
> I add this patch to my previous
> "Re: mmc: sh_mobile_sdhi: DT update for R-Car" patch-set as [5/4]
> Please let me know if you want re-send these patch-set again
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 1622b03..d54169f 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -65,6 +65,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>  	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
>  	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
>  	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
> +	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
>  	{},
>  };
>  MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
> -- 
> 1.7.9.5
> 

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 5/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
@ 2014-02-12  8:38       ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  8:38 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Tue, Feb 11, 2014 at 09:35:50PM -0800, Kuninori Morimoto wrote:
> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> 
> This patch updates r8a7791 DT data to have SoC specific settings.
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Acked-by: Simon Horman <horms+renesas@verge.net.au>


> ---
> >> Chris
> 
> I add this patch to my previous
> "Re: mmc: sh_mobile_sdhi: DT update for R-Car" patch-set as [5/4]
> Please let me know if you want re-send these patch-set again
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 1622b03..d54169f 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -65,6 +65,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>  	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
>  	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
>  	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
> +	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
>  	{},
>  };
>  MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
> -- 
> 1.7.9.5
> 

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-31  5:30   ` Kuninori Morimoto
@ 2014-02-12  9:47     ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  9:47 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> Hi Chris, Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "mmc" part patches.
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
>  1 file changed, 28 insertions(+), 13 deletions(-)
> )

To aid other developers I have pushed these
in the topic/r-car-sdhi branch of my renesas tree.

To be clear, I am not picking these patches up,
that is Chris's domain.

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-02-12  9:47     ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  9:47 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> Hi Chris, Simon
> 
> These are v2 of updates code for R-Car.
> I separated v1 patches into for mmc, and for SH-ARM.
> This is "mmc" part patches.
> 
> Kuninori Morimoto (4):
>       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
>       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> 
>  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
>  1 file changed, 28 insertions(+), 13 deletions(-)
> )

To aid other developers I have pushed these
in the topic/r-car-sdhi branch of my renesas tree.

To be clear, I am not picking these patches up,
that is Chris's domain.

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
  2014-02-12  9:47     ` Simon Horman
@ 2014-02-12  9:50       ` Simon Horman
  -1 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  9:50 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Feb 12, 2014 at 06:47:35PM +0900, Simon Horman wrote:
> On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> > Hi Chris, Simon
> > 
> > These are v2 of updates code for R-Car.
> > I separated v1 patches into for mmc, and for SH-ARM.
> > This is "mmc" part patches.
> > 
> > Kuninori Morimoto (4):
> >       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> > 
> >  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
> >  1 file changed, 28 insertions(+), 13 deletions(-)
> > )
> 
> To aid other developers I have pushed these
> in the topic/r-car-sdhi branch of my renesas tree.
> 
> To be clear, I am not picking these patches up,
> that is Chris's domain.

Also, for the entire series:

Acked-by: Simon Horman <horms+renesas@verge.net.au>

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-02-12  9:50       ` Simon Horman
  0 siblings, 0 replies; 85+ messages in thread
From: Simon Horman @ 2014-02-12  9:50 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Chris Ball, Magnus, Linux-SH, linux-mmc

On Wed, Feb 12, 2014 at 06:47:35PM +0900, Simon Horman wrote:
> On Thu, Jan 30, 2014 at 09:30:20PM -0800, Kuninori Morimoto wrote:
> > Hi Chris, Simon
> > 
> > These are v2 of updates code for R-Car.
> > I separated v1 patches into for mmc, and for SH-ARM.
> > This is "mmc" part patches.
> > 
> > Kuninori Morimoto (4):
> >       mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
> >       mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
> > 
> >  drivers/mmc/host/sh_mobile_sdhi.c |   41 +++++++++++++++++++++++++------------
> >  1 file changed, 28 insertions(+), 13 deletions(-)
> > )
> 
> To aid other developers I have pushed these
> in the topic/r-car-sdhi branch of my renesas tree.
> 
> To be clear, I am not picking these patches up,
> that is Chris's domain.

Also, for the entire series:

Acked-by: Simon Horman <horms+renesas@verge.net.au>

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 0/5][RESENT]mmc: sh_mobile_sdhi: DT update for R-Car
  2014-01-28  4:44 ` Kuninori Morimoto
@ 2014-02-21  0:54   ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc


Hi Chris

These are re-sent patches for R-Car, since there were no response.
Basically, these clarifies chip dependent settings
inside driver.
These are based on mmc/mmc-next branch
(7536d3f83aa42ba1a3b1c6b30c2b6d94a820cbb2)

Kuninori Morimoto (5):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791

 drivers/mmc/host/sh_mobile_sdhi.c |   42 +++++++++++++++++++++++++------------
 1 file changed, 29 insertions(+), 13 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 0/5][RESENT]mmc: sh_mobile_sdhi: DT update for R-Car
@ 2014-02-21  0:54   ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc


Hi Chris

These are re-sent patches for R-Car, since there were no response.
Basically, these clarifies chip dependent settings
inside driver.
These are based on mmc/mmc-next branch
(7536d3f83aa42ba1a3b1c6b30c2b6d94a820cbb2)

Kuninori Morimoto (5):
      mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
      mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791

 drivers/mmc/host/sh_mobile_sdhi.c |   42 +++++++++++++++++++++++++------------
 1 file changed, 29 insertions(+), 13 deletions(-)

^ permalink raw reply	[flat|nested] 85+ messages in thread

* [PATCH 1/5][RESENT] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
  2014-02-21  0:54   ` Kuninori Morimoto
@ 2014-02-21  0:54     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 03fe751..a7a3f68 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id -- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 1/5][RESENT] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position
@ 2014-02-21  0:54     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

it is easy to read if sh_mobile_sdhi_of_cfg and
sh_mobile_sdhi_of_match are closer

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 03fe751..a7a3f68 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -45,6 +45,19 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct of_device_id sh_mobile_sdhi_of_match[] = {
+	{ .compatible = "renesas,sdhi-shmobile" },
+	{ .compatible = "renesas,sdhi-sh7372" },
+	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{},
+};
+MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
+
 struct sh_mobile_sdhi {
 	struct clk *clk;
 	struct tmio_mmc_data mmc_data;
@@ -114,19 +127,6 @@ static const struct sh_mobile_sdhi_ops sdhi_ops = {
 	.cd_wakeup = sh_mobile_sdhi_cd_wakeup,
 };
 
-static const struct of_device_id sh_mobile_sdhi_of_match[] = {
-	{ .compatible = "renesas,sdhi-shmobile" },
-	{ .compatible = "renesas,sdhi-sh7372" },
-	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{},
-};
-MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-
 static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *of_id =
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
  2014-02-21  0:54   ` Kuninori Morimoto
@ 2014-02-21  0:54     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index a7a3f68..e956bc4 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 2/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778
@ 2014-02-21  0:54     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:54 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7778 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index a7a3f68..e956bc4 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -37,6 +37,7 @@
 
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
+	unsigned long capabilities;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -45,13 +46,18 @@ static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
 	},
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
 	{ .compatible = "renesas,sdhi-sh73a0", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
-	{ .compatible = "renesas,sdhi-r8a7778", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
@@ -212,6 +218,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 	if (of_id && of_id->data) {
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
+		mmc_data->capabilities |= of_data->capabilities;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
  2014-02-21  0:54   ` Kuninori Morimoto
@ 2014-02-21  0:55     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index e956bc4..38acf26 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 3/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779
@ 2014-02-21  0:55     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7779 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index e956bc4..38acf26 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -58,7 +58,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a73a4", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7779", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{},
 };
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-02-21  0:54   ` Kuninori Morimoto
@ 2014-02-21  0:55     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 38acf26..cfc37ec 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-02-21  0:55     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7790 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 38acf26..cfc37ec 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -38,6 +38,7 @@
 struct sh_mobile_sdhi_of_data {
 	unsigned long tmio_flags;
 	unsigned long capabilities;
+	unsigned long capabilities2;
 };
 
 static const struct sh_mobile_sdhi_of_data sh_mobile_sdhi_of_cfg[] = {
@@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
 	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
 };
 
+static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
+	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,
+	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
+	.capabilities2	= MMC_CAP2_NO_MULTI_READ,
+};
+
 static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-shmobile" },
 	{ .compatible = "renesas,sdhi-sh7372" },
@@ -59,7 +66,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7740", .data = &sh_mobile_sdhi_of_cfg[0], },
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
-	{ .compatible = "renesas,sdhi-r8a7790", .data = &sh_mobile_sdhi_of_cfg[0], },
+	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
@@ -219,6 +226,7 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
 		const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
 		mmc_data->flags |= of_data->tmio_flags;
 		mmc_data->capabilities |= of_data->capabilities;
+		mmc_data->capabilities2 |= of_data->capabilities2;
 	}
 
 	/* SD control register space size is 0x100, 0x200 for bus_shift=1 */
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 5/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
  2014-02-21  0:54   ` Kuninori Morimoto
@ 2014-02-21  0:55     ` Kuninori Morimoto
  -1 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7791 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index cfc37ec..91058da 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -67,6 +67,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
+	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* [PATCH 5/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
@ 2014-02-21  0:55     ` Kuninori Morimoto
  0 siblings, 0 replies; 85+ messages in thread
From: Kuninori Morimoto @ 2014-02-21  0:55 UTC (permalink / raw)
  To: Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

This patch updates r8a7791 DT data to have SoC specific settings.

Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/mmc/host/sh_mobile_sdhi.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index cfc37ec..91058da 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -67,6 +67,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
 	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
 	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
+	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
 	{},
 };
 MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 85+ messages in thread

* Re: [PATCH 5/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
  2014-02-21  0:55     ` Kuninori Morimoto
@ 2014-02-21 12:36       ` Sergei Shtylyov
  -1 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-02-21 12:36 UTC (permalink / raw)
  To: Kuninori Morimoto, Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

Hello.

On 21-02-2014 4:55, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7791 DT data to have SoC specific settings.

    It doesn't update R8A7791 DT data, it adds the DT support for R8A7791. 
Please fix the changelog.

> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |    1 +
>   1 file changed, 1 insertion(+)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index cfc37ec..91058da 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -67,6 +67,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>   	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
>   	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
>   	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
> +	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
>   	{},
>   };
>   MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 5/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791
@ 2014-02-21 12:36       ` Sergei Shtylyov
  0 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-02-21 12:36 UTC (permalink / raw)
  To: Kuninori Morimoto, Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

Hello.

On 21-02-2014 4:55, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7791 DT data to have SoC specific settings.

    It doesn't update R8A7791 DT data, it adds the DT support for R8A7791. 
Please fix the changelog.

> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |    1 +
>   1 file changed, 1 insertion(+)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index cfc37ec..91058da 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
> @@ -67,6 +67,7 @@ static const struct of_device_id sh_mobile_sdhi_of_match[] = {
>   	{ .compatible = "renesas,sdhi-r8a7778", .data = &of_rcar_gen1_compatible, },
>   	{ .compatible = "renesas,sdhi-r8a7779", .data = &of_rcar_gen1_compatible, },
>   	{ .compatible = "renesas,sdhi-r8a7790", .data = &of_rcar_gen2_compatible, },
> +	{ .compatible = "renesas,sdhi-r8a7791", .data = &of_rcar_gen2_compatible, },
>   	{},
>   };
>   MODULE_DEVICE_TABLE(of, sh_mobile_sdhi_of_match);

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 0/5][RESENT]mmc: sh_mobile_sdhi: DT update for R-Car
  2014-02-21  0:54   ` Kuninori Morimoto
                     ` (5 preceding siblings ...)
  (?)
@ 2014-02-22 18:08   ` Chris Ball
  -1 siblings, 0 replies; 85+ messages in thread
From: Chris Ball @ 2014-02-22 18:08 UTC (permalink / raw)
  To: Kuninori Morimoto; +Cc: Simon, Magnus, Linux-SH, linux-mmc, Sergei Shtylyov

Hi Morimoto-san,

On Fri, Feb 21 2014, Kuninori Morimoto wrote:
> These are re-sent patches for R-Car, since there were no response.
> Basically, these clarifies chip dependent settings
> inside driver.
> These are based on mmc/mmc-next branch
> (7536d3f83aa42ba1a3b1c6b30c2b6d94a820cbb2)

Thanks, I've pushed all five patches to mmc-next for 3.15, after
making Sergei's suggested changelog edit to 5/5 of "This patch
adds DT support for r8a7791."

- Chris.
-- 
Chris Ball   <chris@printf.net>   <http://printf.net/>

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-02-21  0:55     ` Kuninori Morimoto
@ 2014-05-02 23:55       ` Sergei Shtylyov
  -1 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-05-02 23:55 UTC (permalink / raw)
  To: Kuninori Morimoto, Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

Hello.

On 02/21/2014 03:55 AM, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7790 DT data to have SoC specific settings.

> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>   1 file changed, 9 insertions(+), 1 deletion(-)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 38acf26..cfc37ec 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
[...]
> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
>   	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>   };
>
> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
> +	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,

    Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks 
it due to using micro-SD slot?..

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-05-02 23:55       ` Sergei Shtylyov
  0 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-05-02 23:55 UTC (permalink / raw)
  To: Kuninori Morimoto, Chris Ball; +Cc: Simon, Magnus, Linux-SH, linux-mmc

Hello.

On 02/21/2014 03:55 AM, Kuninori Morimoto wrote:

> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

> This patch updates r8a7790 DT data to have SoC specific settings.

> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> ---
>   drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>   1 file changed, 9 insertions(+), 1 deletion(-)

> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
> index 38acf26..cfc37ec 100644
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
[...]
> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data of_rcar_gen1_compatible = {
>   	.capabilities	= MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>   };
>
> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
> +	.tmio_flags	= TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_WRPROTECT_DISABLE,

    Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks 
it due to using micro-SD slot?..

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-05-02 23:55       ` Sergei Shtylyov
@ 2014-05-03 19:23         ` Magnus Damm
  -1 siblings, 0 replies; 85+ messages in thread
From: Magnus Damm @ 2014-05-03 19:23 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

Hi Sergei,

On Fri, May 2, 2014 at 11:55 PM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
> Hello.
>
>
> On 02/21/2014 03:55 AM, Kuninori Morimoto wrote:
>
>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>
>
>> This patch updates r8a7790 DT data to have SoC specific settings.
>
>
>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>> ---
>>   drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>   1 file changed, 9 insertions(+), 1 deletion(-)
>
>
>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>> b/drivers/mmc/host/sh_mobile_sdhi.c
>> index 38acf26..cfc37ec 100644
>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
>
> [...]
>
>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>> of_rcar_gen1_compatible = {
>>         .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>   };
>>
>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>> TMIO_MMC_WRPROTECT_DISABLE,
>
>
>    Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks
> it due to using micro-SD slot?..

This has been design this way intentionally. Basically, we don't want
any board specific code in any driver and the WP signal is a very
board specific property. So we default to not using WP, but let the
user hook in GPIO via DT in case it is used on a particular instance
on a particular board. If we do it the other way around and enable by
default then we would have to implement disabling of WP in DT which is
just strange. If done wrong then the micro-SD cards may end up with
incorrect WP signal state (read only?). So letting board code hook in
board specific bits via DT seems like the only sane way forward in my
mind.

Is there anything related to WP and CD that does not work for you?

Thanks,

/ magnus

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-05-03 19:23         ` Magnus Damm
  0 siblings, 0 replies; 85+ messages in thread
From: Magnus Damm @ 2014-05-03 19:23 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

Hi Sergei,

On Fri, May 2, 2014 at 11:55 PM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
> Hello.
>
>
> On 02/21/2014 03:55 AM, Kuninori Morimoto wrote:
>
>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>
>
>> This patch updates r8a7790 DT data to have SoC specific settings.
>
>
>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>> ---
>>   drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>   1 file changed, 9 insertions(+), 1 deletion(-)
>
>
>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>> b/drivers/mmc/host/sh_mobile_sdhi.c
>> index 38acf26..cfc37ec 100644
>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
>
> [...]
>
>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>> of_rcar_gen1_compatible = {
>>         .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>   };
>>
>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>> TMIO_MMC_WRPROTECT_DISABLE,
>
>
>    Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks
> it due to using micro-SD slot?..

This has been design this way intentionally. Basically, we don't want
any board specific code in any driver and the WP signal is a very
board specific property. So we default to not using WP, but let the
user hook in GPIO via DT in case it is used on a particular instance
on a particular board. If we do it the other way around and enable by
default then we would have to implement disabling of WP in DT which is
just strange. If done wrong then the micro-SD cards may end up with
incorrect WP signal state (read only?). So letting board code hook in
board specific bits via DT seems like the only sane way forward in my
mind.

Is there anything related to WP and CD that does not work for you?

Thanks,

/ magnus

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-05-03 19:23         ` Magnus Damm
@ 2014-05-03 21:30           ` Sergei Shtylyov
  -1 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-05-03 21:30 UTC (permalink / raw)
  To: Magnus Damm; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

Hello.

On 05/03/2014 11:23 PM, Magnus Damm wrote:

>>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

>>> This patch updates r8a7790 DT data to have SoC specific settings.

>>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>>> ---
>>>    drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>>    1 file changed, 9 insertions(+), 1 deletion(-)

>>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>>> b/drivers/mmc/host/sh_mobile_sdhi.c
>>> index 38acf26..cfc37ec 100644
>>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c

>> [...]

>>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>>> of_rcar_gen1_compatible = {
>>>          .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>>    };

>>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>>> TMIO_MMC_WRPROTECT_DISABLE,

>>     Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks
>> it due to using micro-SD slot?..

> This has been design this way intentionally. Basically, we don't want
> any board specific code in any driver and the WP signal is a very
> board specific property. So we default to not using WP, but let the
> user hook in GPIO via DT in case it is used on a particular instance
> on a particular board. If we do it the other way around and enable by
> default then we would have to implement disabling of WP in DT which is
> just strange.

    I don't quite understand what's so strange about that. IMO, the device 
node properties are designed to carry the board specific info.

> If done wrong then the micro-SD cards may end up with
> incorrect WP signal state (read only?).

    Hm, isn't WP a read-only signal by design?

> So letting board code hook in
> board specific bits via DT seems like the only sane way forward in my
> mind.

    Yes, I'd agree to that but I can't agree that preferring GPIO to the 
native WP signal is the only sane way.

> Is there anything related to WP and CD that does not work for you?

    I don't think the legacy code handles CD correctly. The driver doesn't 
ever read the native CD signal, it expects CD to be always implemented via 
GPIO while the legacy code doesn't pass the GPIO to the driver.

> Thanks,

> / magnus

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-05-03 21:30           ` Sergei Shtylyov
  0 siblings, 0 replies; 85+ messages in thread
From: Sergei Shtylyov @ 2014-05-03 21:30 UTC (permalink / raw)
  To: Magnus Damm; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

Hello.

On 05/03/2014 11:23 PM, Magnus Damm wrote:

>>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

>>> This patch updates r8a7790 DT data to have SoC specific settings.

>>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>>> ---
>>>    drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>>    1 file changed, 9 insertions(+), 1 deletion(-)

>>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>>> b/drivers/mmc/host/sh_mobile_sdhi.c
>>> index 38acf26..cfc37ec 100644
>>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c

>> [...]

>>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>>> of_rcar_gen1_compatible = {
>>>          .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>>    };

>>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>>> TMIO_MMC_WRPROTECT_DISABLE,

>>     Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch lacks
>> it due to using micro-SD slot?..

> This has been design this way intentionally. Basically, we don't want
> any board specific code in any driver and the WP signal is a very
> board specific property. So we default to not using WP, but let the
> user hook in GPIO via DT in case it is used on a particular instance
> on a particular board. If we do it the other way around and enable by
> default then we would have to implement disabling of WP in DT which is
> just strange.

    I don't quite understand what's so strange about that. IMO, the device 
node properties are designed to carry the board specific info.

> If done wrong then the micro-SD cards may end up with
> incorrect WP signal state (read only?).

    Hm, isn't WP a read-only signal by design?

> So letting board code hook in
> board specific bits via DT seems like the only sane way forward in my
> mind.

    Yes, I'd agree to that but I can't agree that preferring GPIO to the 
native WP signal is the only sane way.

> Is there anything related to WP and CD that does not work for you?

    I don't think the legacy code handles CD correctly. The driver doesn't 
ever read the native CD signal, it expects CD to be always implemented via 
GPIO while the legacy code doesn't pass the GPIO to the driver.

> Thanks,

> / magnus

WBR, Sergei


^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
  2014-05-03 21:30           ` Sergei Shtylyov
@ 2014-05-04  8:01             ` Magnus Damm
  -1 siblings, 0 replies; 85+ messages in thread
From: Magnus Damm @ 2014-05-04  8:01 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

On Sun, May 4, 2014 at 6:30 AM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
> Hello.
>
>
> On 05/03/2014 11:23 PM, Magnus Damm wrote:
>
>>>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>
>
>>>> This patch updates r8a7790 DT data to have SoC specific settings.
>
>
>>>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>>>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>>>> ---
>>>>    drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>>>    1 file changed, 9 insertions(+), 1 deletion(-)
>
>
>>>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>>>> b/drivers/mmc/host/sh_mobile_sdhi.c
>>>> index 38acf26..cfc37ec 100644
>>>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>>>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
>
>
>>> [...]
>
>
>>>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>>>> of_rcar_gen1_compatible = {
>>>>          .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>>>    };
>
>
>>>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>>>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>>>> TMIO_MMC_WRPROTECT_DISABLE,
>
>
>>>     Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch
>>> lacks
>>> it due to using micro-SD slot?..
>
>
>> This has been design this way intentionally. Basically, we don't want
>> any board specific code in any driver and the WP signal is a very
>> board specific property. So we default to not using WP, but let the
>> user hook in GPIO via DT in case it is used on a particular instance
>> on a particular board. If we do it the other way around and enable by
>> default then we would have to implement disabling of WP in DT which is
>> just strange.
>
>
>    I don't quite understand what's so strange about that. IMO, the device
> node properties are designed to carry the board specific info.

This is all about wanting sane defaults and keeping the code simple.
Using GPIOs covers 100% of all use cases on R-Car Gen2 and it allows
us to use generic DT properties in the board DTS to enable WP and CD.
Any other native CD or WP handling is just a corner case.

You may be confused by the difference between the R-Car Gen1 case and
the R-Car Gen2 case when it comes to CD and WP handling in the SDHI
driver. The reason why we don't rely 100% on GPIO for Gen1 is that the
GPIO hardware does not support IRQ trigger with both edges. In R-Car
Gen2 case the GPIO should cover all pins on the system and allows for
both edge trigger.

Using the native CD (and maybe WP) functionality of the SDHI hardware
may conflict with Runtime PM. Ideally we want to be able to disable
the clock and power domain when no card is inserted or the card is
in-use but idle. Using GPIO helps us with that.

>> If done wrong then the micro-SD cards may end up with
>> incorrect WP signal state (read only?).
>
>
>    Hm, isn't WP a read-only signal by design?

The _card_ may end up read-only if WP is used incorrectly.

>> So letting board code hook in
>> board specific bits via DT seems like the only sane way forward in my
>> mind.
>
>
>    Yes, I'd agree to that but I can't agree that preferring GPIO to the
> native WP signal is the only sane way.

So why would we want to have multiple overlapping ways of handling the
WP signal?

>> Is there anything related to WP and CD that does not work for you?
>
>
>    I don't think the legacy code handles CD correctly. The driver doesn't
> ever read the native CD signal, it expects CD to be always implemented via
> GPIO while the legacy code doesn't pass the GPIO to the driver.

Are you sure about this? If you find a bug then please report it,
otherwise I can think of more interesting things to spend time on.

Cheers,

/ magnus

^ permalink raw reply	[flat|nested] 85+ messages in thread

* Re: [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790
@ 2014-05-04  8:01             ` Magnus Damm
  0 siblings, 0 replies; 85+ messages in thread
From: Magnus Damm @ 2014-05-04  8:01 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: Kuninori Morimoto, Chris Ball, Simon, Linux-SH, linux-mmc

On Sun, May 4, 2014 at 6:30 AM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
> Hello.
>
>
> On 05/03/2014 11:23 PM, Magnus Damm wrote:
>
>>>> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>
>
>>>> This patch updates r8a7790 DT data to have SoC specific settings.
>
>
>>>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>>>> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
>>>> ---
>>>>    drivers/mmc/host/sh_mobile_sdhi.c |   10 +++++++++-
>>>>    1 file changed, 9 insertions(+), 1 deletion(-)
>
>
>>>> diff --git a/drivers/mmc/host/sh_mobile_sdhi.c
>>>> b/drivers/mmc/host/sh_mobile_sdhi.c
>>>> index 38acf26..cfc37ec 100644
>>>> --- a/drivers/mmc/host/sh_mobile_sdhi.c
>>>> +++ b/drivers/mmc/host/sh_mobile_sdhi.c
>
>
>>> [...]
>
>
>>>> @@ -51,6 +52,12 @@ static const struct sh_mobile_sdhi_of_data
>>>> of_rcar_gen1_compatible = {
>>>>          .capabilities   = MMC_CAP_SD_HIGHSPEED | MMC_CAP_SDIO_IRQ,
>>>>    };
>
>
>>>> +static const struct sh_mobile_sdhi_of_data of_rcar_gen2_compatible = {
>>>> +       .tmio_flags     = TMIO_MMC_HAS_IDLE_WAIT |
>>>> TMIO_MMC_WRPROTECT_DISABLE,
>
>
>>>     Hm, I think SDHI0/1 still have the WP signal, only SDHI2 on Koelsch
>>> lacks
>>> it due to using micro-SD slot?..
>
>
>> This has been design this way intentionally. Basically, we don't want
>> any board specific code in any driver and the WP signal is a very
>> board specific property. So we default to not using WP, but let the
>> user hook in GPIO via DT in case it is used on a particular instance
>> on a particular board. If we do it the other way around and enable by
>> default then we would have to implement disabling of WP in DT which is
>> just strange.
>
>
>    I don't quite understand what's so strange about that. IMO, the device
> node properties are designed to carry the board specific info.

This is all about wanting sane defaults and keeping the code simple.
Using GPIOs covers 100% of all use cases on R-Car Gen2 and it allows
us to use generic DT properties in the board DTS to enable WP and CD.
Any other native CD or WP handling is just a corner case.

You may be confused by the difference between the R-Car Gen1 case and
the R-Car Gen2 case when it comes to CD and WP handling in the SDHI
driver. The reason why we don't rely 100% on GPIO for Gen1 is that the
GPIO hardware does not support IRQ trigger with both edges. In R-Car
Gen2 case the GPIO should cover all pins on the system and allows for
both edge trigger.

Using the native CD (and maybe WP) functionality of the SDHI hardware
may conflict with Runtime PM. Ideally we want to be able to disable
the clock and power domain when no card is inserted or the card is
in-use but idle. Using GPIO helps us with that.

>> If done wrong then the micro-SD cards may end up with
>> incorrect WP signal state (read only?).
>
>
>    Hm, isn't WP a read-only signal by design?

The _card_ may end up read-only if WP is used incorrectly.

>> So letting board code hook in
>> board specific bits via DT seems like the only sane way forward in my
>> mind.
>
>
>    Yes, I'd agree to that but I can't agree that preferring GPIO to the
> native WP signal is the only sane way.

So why would we want to have multiple overlapping ways of handling the
WP signal?

>> Is there anything related to WP and CD that does not work for you?
>
>
>    I don't think the legacy code handles CD correctly. The driver doesn't
> ever read the native CD signal, it expects CD to be always implemented via
> GPIO while the legacy code doesn't pass the GPIO to the driver.

Are you sure about this? If you find a bug then please report it,
otherwise I can think of more interesting things to spend time on.

Cheers,

/ magnus

^ permalink raw reply	[flat|nested] 85+ messages in thread

end of thread, other threads:[~2014-05-04  8:01 UTC | newest]

Thread overview: 85+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-28  4:44 mmc: sh_mobile_sdhi: DT update for R-Car Kuninori Morimoto
2014-01-28  4:44 ` Kuninori Morimoto
2014-01-28  4:45 ` [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position Kuninori Morimoto
2014-01-28  4:45   ` Kuninori Morimoto
2014-01-28  4:45 ` [PATCH 2/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7778 Kuninori Morimoto
2014-01-28  4:45   ` Kuninori Morimoto
2014-01-28  4:45 ` [PATCH 3/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7779 Kuninori Morimoto
2014-01-28  4:45   ` Kuninori Morimoto
2014-01-28  4:45 ` [PATCH 4/4] mmc: SDHI: updata sh_mobile_sdhi_of_data for r8a7790 Kuninori Morimoto
2014-01-28  4:45   ` Kuninori Morimoto
2014-01-28 15:06 ` mmc: sh_mobile_sdhi: DT update for R-Car Sergei Shtylyov
2014-01-28 16:06   ` Sergei Shtylyov
2014-01-29  0:31   ` Kuninori Morimoto
2014-01-29  0:31     ` Kuninori Morimoto
2014-01-30  5:38 ` Kuninori Morimoto
2014-01-30  5:38   ` Kuninori Morimoto
2014-01-30  6:43   ` Simon Horman
2014-01-30  6:43     ` Simon Horman
2014-01-30  7:08     ` Kuninori Morimoto
2014-01-30  7:08       ` Kuninori Morimoto
2014-01-31  0:16       ` Simon Horman
2014-01-31  0:16         ` Simon Horman
2014-01-31  5:30 ` Kuninori Morimoto
2014-01-31  5:30   ` Kuninori Morimoto
2014-01-31  5:31   ` [PATCH 1/4] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position Kuninori Morimoto
2014-01-31  5:31     ` Kuninori Morimoto
2014-01-31  5:31   ` [PATCH 2/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778 Kuninori Morimoto
2014-01-31  5:31     ` Kuninori Morimoto
2014-01-31  5:32   ` [PATCH 3/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779 Kuninori Morimoto
2014-01-31  5:32     ` Kuninori Morimoto
2014-01-31 12:46     ` Sergei Shtylyov
2014-01-31 12:46       ` Sergei Shtylyov
2014-01-31  5:32   ` [PATCH 4/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790 Kuninori Morimoto
2014-01-31  5:32     ` Kuninori Morimoto
2014-02-03  6:41   ` mmc: sh_mobile_sdhi: DT update for R-Car Simon Horman
2014-02-03  6:41     ` Simon Horman
2014-02-12  5:35   ` [PATCH 5/4] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791 Kuninori Morimoto
2014-02-12  5:35     ` Kuninori Morimoto
2014-02-12  8:38     ` Simon Horman
2014-02-12  8:38       ` Simon Horman
2014-02-12  9:47   ` mmc: sh_mobile_sdhi: DT update for R-Car Simon Horman
2014-02-12  9:47     ` Simon Horman
2014-02-12  9:50     ` Simon Horman
2014-02-12  9:50       ` Simon Horman
2014-01-31  5:36 ` Kuninori Morimoto
2014-01-31  5:36   ` Kuninori Morimoto
2014-01-31  5:36   ` [PATCH 1/3] ARM: shmobile: r8a7778: removed unnecessary mmc option Kuninori Morimoto
2014-01-31  5:36     ` Kuninori Morimoto
2014-01-31  5:36   ` [PATCH 2/3] ARM: shmobile: r8a7779: " Kuninori Morimoto
2014-01-31  5:36     ` Kuninori Morimoto
2014-01-31  5:36   ` [PATCH 3/3] ARM: shmobile: r8a7790: " Kuninori Morimoto
2014-01-31  5:36     ` Kuninori Morimoto
2014-02-03  6:34   ` mmc: sh_mobile_sdhi: DT update for R-Car Simon Horman
2014-02-03  6:34     ` Simon Horman
2014-01-31  5:39 ` [PATCH] ARM: shmobile: bockw: use wp-gpios instead of WP pin Kuninori Morimoto
2014-01-31  5:39   ` Kuninori Morimoto
2014-02-03  6:35   ` Simon Horman
2014-02-03  6:35     ` Simon Horman
2014-02-04  1:32     ` Kuninori Morimoto
2014-02-04  1:32       ` Kuninori Morimoto
2014-02-06  6:59       ` Simon Horman
2014-02-06  6:59         ` Simon Horman
2014-02-21  0:54 ` [PATCH 0/5][RESENT]mmc: sh_mobile_sdhi: DT update for R-Car Kuninori Morimoto
2014-02-21  0:54   ` Kuninori Morimoto
2014-02-21  0:54   ` [PATCH 1/5][RESENT] mmc: SDHI: tidyup sh_mobile_sdhi_of_match position Kuninori Morimoto
2014-02-21  0:54     ` Kuninori Morimoto
2014-02-21  0:54   ` [PATCH 2/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7778 Kuninori Morimoto
2014-02-21  0:54     ` Kuninori Morimoto
2014-02-21  0:55   ` [PATCH 3/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7779 Kuninori Morimoto
2014-02-21  0:55     ` Kuninori Morimoto
2014-02-21  0:55   ` [PATCH 4/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7790 Kuninori Morimoto
2014-02-21  0:55     ` Kuninori Morimoto
2014-05-02 23:55     ` Sergei Shtylyov
2014-05-02 23:55       ` Sergei Shtylyov
2014-05-03 19:23       ` Magnus Damm
2014-05-03 19:23         ` Magnus Damm
2014-05-03 21:30         ` Sergei Shtylyov
2014-05-03 21:30           ` Sergei Shtylyov
2014-05-04  8:01           ` Magnus Damm
2014-05-04  8:01             ` Magnus Damm
2014-02-21  0:55   ` [PATCH 5/5][RESENT] mmc: SDHI: update sh_mobile_sdhi_of_data for r8a7791 Kuninori Morimoto
2014-02-21  0:55     ` Kuninori Morimoto
2014-02-21 12:36     ` Sergei Shtylyov
2014-02-21 12:36       ` Sergei Shtylyov
2014-02-22 18:08   ` [PATCH 0/5][RESENT]mmc: sh_mobile_sdhi: DT update for R-Car Chris Ball

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.