Lines Matching +full:p1 +full:- +full:cominit +full:- +full:params
1 // SPDX-License-Identifier: GPL-2.0-only
72 #define DRV_NAME "ahci-ceva"
77 MODULE_PARM_DESC(rx_watermark, "RxWaterMark value (0 - 0x80)");
123 void __iomem *mmio = hpriv->mmio; in ahci_ceva_setup()
124 struct ceva_ahci_priv *cevapriv = hpriv->plat_data; in ahci_ceva_setup()
141 * Set Mem Addr Read ID, Write ID for non-data transfers in ahci_ceva_setup()
149 if (cevapriv->is_cci_enabled) { in ahci_ceva_setup()
162 /* Phy Control OOB timing parameters COMINIT */ in ahci_ceva_setup()
163 writel(cevapriv->pp2c[i], mmio + AHCI_VEND_PP2C); in ahci_ceva_setup()
166 writel(cevapriv->pp3c[i], mmio + AHCI_VEND_PP3C); in ahci_ceva_setup()
169 writel(cevapriv->pp4c[i], mmio + AHCI_VEND_PP4C); in ahci_ceva_setup()
172 writel(cevapriv->pp5c[i], mmio + AHCI_VEND_PP5C); in ahci_ceva_setup()
180 if (cevapriv->flags & CEVA_FLAG_BROKEN_GEN2) in ahci_ceva_setup()
192 struct device_node *np = pdev->dev.of_node; in ceva_ahci_probe()
193 struct device *dev = &pdev->dev; in ceva_ahci_probe()
201 return -ENOMEM; in ceva_ahci_probe()
203 cevapriv->ahci_pdev = pdev; in ceva_ahci_probe()
213 if (of_property_read_bool(np, "ceva,broken-gen2")) in ceva_ahci_probe()
214 cevapriv->flags = CEVA_FLAG_BROKEN_GEN2; in ceva_ahci_probe()
216 /* Read OOB timing value for COMINIT from device-tree */ in ceva_ahci_probe()
217 if (of_property_read_u8_array(np, "ceva,p0-cominit-params", in ceva_ahci_probe()
218 (u8 *)&cevapriv->pp2c[0], 4) < 0) { in ceva_ahci_probe()
219 dev_warn(dev, "ceva,p0-cominit-params property not defined\n"); in ceva_ahci_probe()
220 return -EINVAL; in ceva_ahci_probe()
223 if (of_property_read_u8_array(np, "ceva,p1-cominit-params", in ceva_ahci_probe()
224 (u8 *)&cevapriv->pp2c[1], 4) < 0) { in ceva_ahci_probe()
225 dev_warn(dev, "ceva,p1-cominit-params property not defined\n"); in ceva_ahci_probe()
226 return -EINVAL; in ceva_ahci_probe()
229 /* Read OOB timing value for COMWAKE from device-tree*/ in ceva_ahci_probe()
230 if (of_property_read_u8_array(np, "ceva,p0-comwake-params", in ceva_ahci_probe()
231 (u8 *)&cevapriv->pp3c[0], 4) < 0) { in ceva_ahci_probe()
232 dev_warn(dev, "ceva,p0-comwake-params property not defined\n"); in ceva_ahci_probe()
233 return -EINVAL; in ceva_ahci_probe()
236 if (of_property_read_u8_array(np, "ceva,p1-comwake-params", in ceva_ahci_probe()
237 (u8 *)&cevapriv->pp3c[1], 4) < 0) { in ceva_ahci_probe()
238 dev_warn(dev, "ceva,p1-comwake-params property not defined\n"); in ceva_ahci_probe()
239 return -EINVAL; in ceva_ahci_probe()
242 /* Read phy BURST timing value from device-tree */ in ceva_ahci_probe()
243 if (of_property_read_u8_array(np, "ceva,p0-burst-params", in ceva_ahci_probe()
244 (u8 *)&cevapriv->pp4c[0], 4) < 0) { in ceva_ahci_probe()
245 dev_warn(dev, "ceva,p0-burst-params property not defined\n"); in ceva_ahci_probe()
246 return -EINVAL; in ceva_ahci_probe()
249 if (of_property_read_u8_array(np, "ceva,p1-burst-params", in ceva_ahci_probe()
250 (u8 *)&cevapriv->pp4c[1], 4) < 0) { in ceva_ahci_probe()
251 dev_warn(dev, "ceva,p1-burst-params property not defined\n"); in ceva_ahci_probe()
252 return -EINVAL; in ceva_ahci_probe()
255 /* Read phy RETRY interval timing value from device-tree */ in ceva_ahci_probe()
256 if (of_property_read_u16_array(np, "ceva,p0-retry-params", in ceva_ahci_probe()
257 (u16 *)&cevapriv->pp5c[0], 2) < 0) { in ceva_ahci_probe()
258 dev_warn(dev, "ceva,p0-retry-params property not defined\n"); in ceva_ahci_probe()
259 return -EINVAL; in ceva_ahci_probe()
262 if (of_property_read_u16_array(np, "ceva,p1-retry-params", in ceva_ahci_probe()
263 (u16 *)&cevapriv->pp5c[1], 2) < 0) { in ceva_ahci_probe()
264 dev_warn(dev, "ceva,p1-retry-params property not defined\n"); in ceva_ahci_probe()
265 return -EINVAL; in ceva_ahci_probe()
273 cevapriv->is_cci_enabled = (attr == DEV_DMA_COHERENT); in ceva_ahci_probe()
275 hpriv->plat_data = cevapriv; in ceva_ahci_probe()
300 struct ahci_host_priv *hpriv = host->private_data; in ceva_ahci_resume()
330 { .compatible = "ceva,ahci-1v84" },