Hello.

On 11-10-2013 3:00, Simon Horman wrote:

[ CCed [email protected] as this involves DT compatibility strings ]

Note that I did CC then-existing devicetree-discuss list when posting the original driver but we got no feedback from there. That's why the binding documentation is missing.

RCAR Gen2 SoC has a different phy which is not compatible with

   Hm, the SoCs family is called R-Car, is it so hard to remember? :-)

the older H1/M1 versions. This adds OF/platform device table
and PHY initialization callbacks for H2/M2 (Gen2) SoC.

[...]

PHY initialization method is chosen based on the device id.
Default PHY settings are applied for Gen2 SoC, which should
suit the available Gen2 boards.

Signed-off-by: Valentine Barshak <[email protected]>
[skip overquoating, grr :-]
@@ -770,8 +823,34 @@ static void sata_rcar_init_controller(struct ata_host 
*host)
        iowrite32(ATAPI_INT_ENABLE_SATAINT, base + ATAPI_INT_ENABLE_REG);
  }

+static struct of_device_id sata_rcar_match[] = {
+       {
+               .compatible = "renesas,rcar-sata",
+               .data = (void *)RCAR_SATA
+       },
+       {
+               .compatible = "renesas,sata-r8a7790",
+               .data = (void *)RCAR_GEN2_SATA
+       },
+       {
+               .compatible = "renesas,sata-r8a7791",
+               .data = (void *)RCAR_GEN2_SATA
+       },
+       {},
+};
+MODULE_DEVICE_TABLE(of, sata_rcar_match);
+
+static const struct platform_device_id sata_rcar_id_table[] = {
+       { "sata_rcar",                RCAR_SATA },
+       { "sata-r8a7790",     RCAR_GEN2_SATA },
+       { "sata-r8a7791",     RCAR_GEN2_SATA },
+       { },
+};
+MODULE_DEVICE_TABLE(platform, sata_rcat_id_table);
+

I think it would be better to add sata-r8a7779 and
sata-r8a7778 to handle the GEN1 hardware and deprecate rcar-sata.

   R8A7778 doesn't have the SATA controller AFAIR.

Less importantly I think it would be better to name RCAR_SATA
as RCAR_GEN1_SATA.

   Now that we have Gen2, yes.

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to