Thread (10 messages) 10 messages, 3 authors, 2024-07-12

Re: [PATCH v1 2/4] ata: ahci_imx: Clean up code by using i.MX8Q HSIO PHY driver

From: Damien Le Moal <dlemoal@kernel.org>
Date: 2024-07-11 10:24:27
Also in: imx, linux-devicetree, linux-ide, lkml

On 7/11/24 17:11, Richard Zhu wrote:
Clean up code by using PHY interface.

Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
---
[...]
 static int imx8_sata_enable(struct ahci_host_priv *hpriv)
 {
-	u32 val, reg;
-	int i, ret;
+	u32 val;
+	int ret;
 	struct imx_ahci_priv *imxpriv = hpriv->plat_data;
 	struct device *dev = &imxpriv->ahci_pdev->dev;
 
-	/* configure the hsio for sata */
-	ret = clk_prepare_enable(imxpriv->phy_pclk0);
-	if (ret < 0) {
-		dev_err(dev, "can't enable phy_pclk0.\n");
+	/*
+	 * Since "REXT" pin is only present for first lane of i.MX8QM
+	 * PHY, it's calibration results will be stored, passed
s/it's/its
+	 * through second lane PHY, and shared with all three lane PHYs.
s/through/through to the
+	 *
+	 * Initialize the first two lane PHYs here, although only the
+	 * third lane PHY is used by SATA.
+	 */
-- 
Damien Le Moal
Western Digital Research

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help