Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
[cascardo/linux.git] / drivers / ata / sata_rcar.c
index 8804127..f72d601 100644 (file)
@@ -854,17 +854,14 @@ static struct of_device_id sata_rcar_match[] = {
                .compatible = "renesas,sata-r8a7793",
                .data = (void *)RCAR_GEN2_SATA
        },
+       {
+               .compatible = "renesas,sata-r8a7795",
+               .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_GEN1_SATA }, /* Deprecated by "sata-r8a7779" */
-       { "sata-r8a7779", RCAR_GEN1_SATA },
-       { },
-};
-MODULE_DEVICE_TABLE(platform, sata_rcar_id_table);
-
 static int sata_rcar_probe(struct platform_device *pdev)
 {
        const struct of_device_id *of_id;
@@ -884,11 +881,10 @@ static int sata_rcar_probe(struct platform_device *pdev)
                return -ENOMEM;
 
        of_id = of_match_device(sata_rcar_match, &pdev->dev);
-       if (of_id)
-               priv->type = (enum sata_rcar_type)of_id->data;
-       else
-               priv->type = platform_get_device_id(pdev)->driver_data;
+       if (!of_id)
+               return -ENODEV;
 
+       priv->type = (enum sata_rcar_type)of_id->data;
        priv->clk = devm_clk_get(&pdev->dev, NULL);
        if (IS_ERR(priv->clk)) {
                dev_err(&pdev->dev, "failed to get access to sata clock\n");
@@ -1018,7 +1014,6 @@ static const struct dev_pm_ops sata_rcar_pm_ops = {
 static struct platform_driver sata_rcar_driver = {
        .probe          = sata_rcar_probe,
        .remove         = sata_rcar_remove,
-       .id_table       = sata_rcar_id_table,
        .driver = {
                .name           = DRV_NAME,
                .of_match_table = sata_rcar_match,