45 lines
1.6 KiB
Diff
45 lines
1.6 KiB
Diff
From git@z Thu Jan 1 00:00:00 1970
|
|
Subject: [PATCH v13 9/35] phy: rockchip: usbdp: Fix LFPS detect threshold
|
|
control
|
|
From: William Wu <william.wu@rock-chips.com>
|
|
Date: Tue, 14 Jul 2026 21:26:10 +0200
|
|
Message-Id: <20260714-rockchip-usbdp-cleanup-v13-9-6cb3e769d4c5@collabora.com>
|
|
MIME-Version: 1.0
|
|
Content-Type: text/plain; charset="utf-8"
|
|
Content-Transfer-Encoding: 7bit
|
|
|
|
According to the LFPS Tx Low Power/LFPS Rx Detect Threshold [1],
|
|
the device under test(DUT) must not respond if LFPS below the
|
|
minimum LFPS Rx Detect Threshold 100mV. Test fail on Rockchip
|
|
platforms, because the default LFPS detect threshold is set to
|
|
65mV.
|
|
|
|
The USBDP PHY LFPS detect threshold voltage could be set to
|
|
30mV ~ 140mV, and since there could be 10-20% PVT variation,
|
|
we set LFPS detect threshold voltage to 110mV.
|
|
|
|
[1] https://compliance.usb.org/resources/LFPS_Rx_Tx_Low_Power_Compliance_Update_Rev5.pdf
|
|
|
|
[Taken over from rockchip's kernel tree; the registers are not described
|
|
in the TRM]
|
|
|
|
Signed-off-by: William Wu <william.wu@rock-chips.com>
|
|
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
|
|
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
|
|
---
|
|
drivers/phy/rockchip/phy-rockchip-usbdp.c | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
--- a/drivers/phy/rockchip/phy-rockchip-usbdp.c
|
|
+++ b/drivers/phy/rockchip/phy-rockchip-usbdp.c
|
|
@@ -413,7 +413,8 @@ static const struct reg_sequence rk_udph
|
|
{0x0070, 0x7d}, {0x0074, 0x68},
|
|
{0x0af4, 0x1a}, {0x1af4, 0x1a},
|
|
{0x0440, 0x3f}, {0x10d4, 0x08},
|
|
- {0x20d4, 0x08}, {0x0024, 0x6e}
|
|
+ {0x20d4, 0x08}, {0x0024, 0x6e},
|
|
+ {0x09c0, 0x0a}, {0x19c0, 0x0a}
|
|
};
|
|
|
|
static inline int rk_udphy_grfreg_write(struct regmap *base,
|