Merge git://git.denx.de/u-boot-fsl-qoriq
[oweals/u-boot.git] / drivers / ata / dwc_ahci.c
index eadd77944c12448300f065c189aa87492099547e..b16304baedbdf3dbc518f34f22b102c458fdab02 100644 (file)
@@ -58,19 +58,19 @@ static int dwc_ahci_probe(struct udevice *dev)
 
        ret = generic_phy_get_by_name(dev, "sata-phy", &phy);
        if (ret) {
-               error("can't get the phy from DT\n");
+               pr_err("can't get the phy from DT\n");
                return ret;
        }
 
        ret = generic_phy_init(&phy);
        if (ret) {
-               error("unable to initialize the sata phy\n");
+               pr_err("unable to initialize the sata phy\n");
                return ret;
        }
 
        ret = generic_phy_power_on(&phy);
        if (ret) {
-               error("unable to power on the sata phy\n");
+               pr_err("unable to power on the sata phy\n");
                return ret;
        }
 
@@ -81,7 +81,7 @@ static int dwc_ahci_probe(struct udevice *dev)
                writel(val, priv->wrapper_base + TI_SATA_SYSCONFIG);
        }
 
-       ret = ahci_init(priv->base);
+       ret = ahci_init_dm(dev, priv->base);
        if (ret)
                return ret;
 
@@ -98,6 +98,7 @@ U_BOOT_DRIVER(dwc_ahci) = {
        .id     = UCLASS_SCSI,
        .of_match = dwc_ahci_ids,
        .ofdata_to_platdata = dwc_ahci_ofdata_to_platdata,
+       .ops    = &scsi_ops,
        .probe  = dwc_ahci_probe,
        .priv_auto_alloc_size = sizeof(struct dwc_ahci_priv),
        .flags = DM_FLAG_ALLOC_PRIV_DMA,