From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2FEAD36C0D5; Wed, 28 Jan 2026 15:28:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769614124; cv=none; b=h2PvyRXbJOfO0RVnzN7qGJW95AlYKPhLZK3ohuDMKLW/jeezeXzqpOim4XKjWqhfHePassj0Q5xuYBK8HpBQAVu74+g6vzKfZJRBBiobvqVaevCmivwtPX+iKlEKAdhow5bKVwC9MWTo1+KFmKIKOG5BdtTOT8wkwf3zLbr1X1w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769614124; c=relaxed/simple; bh=55iESlkvDdy1DAlTHepAP+4HQYZu46rvubKwhQBBIJg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=bB879x3lOu4EYih9BnfFAH3Clu3K6qA41Ugp4FwZxtEg2h/frkxl9nrOwlZkMdiQb5oqa1nUpFABP+QA6YVSd16jRVXTGbo+NUABxE8ztnqm5ACX4KwQrDJhFsU9lhPIsSRMCUhY/HZgsSNu8FYL24fBVDgQrSpkbzn77RW1wso= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=1J8ZbNN2; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="1J8ZbNN2" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 96A65C4CEF1; Wed, 28 Jan 2026 15:28:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1769614124; bh=55iESlkvDdy1DAlTHepAP+4HQYZu46rvubKwhQBBIJg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1J8ZbNN2RrzypmNnrHKZSmDjTyDjw+e/hkA9gaHvGlFUyTm3wN8QmtpfNNrefxgCJ 0OYuZR6zYxp04vIkyBHidoCYrwxzlfRtqV00wBv/3k80tCfmX5OKuj9C2XaqF7uIaK Xk9RoKsbS9+tgMWQGy5+qpFnHuZB0JtB+RkZjV+c= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Leonid Segal , Pierluigi Passaro , Stefano Radaelli , Xu Yang , Frank Li , Fabio Estevam , Ahmad Fatoum , Vinod Koul , Sasha Levin Subject: [PATCH 6.6 035/254] phy: fsl-imx8mq-usb: Clear the PCS_TX_SWING_FULL field before using it Date: Wed, 28 Jan 2026 16:20:11 +0100 Message-ID: <20260128145345.965751746@linuxfoundation.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20260128145344.698118637@linuxfoundation.org> References: <20260128145344.698118637@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Stefano Radaelli [ Upstream commit 8becf9179a4b45104a1701010ed666b55bf4b3a6 ] Clear the PCS_TX_SWING_FULL field mask before setting the new value in PHY_CTRL5 register. Without clearing the mask first, the OR operation could leave previously set bits, resulting in incorrect register configuration. Fixes: 63c85ad0cd81 ("phy: fsl-imx8mp-usb: add support for phy tuning") Suggested-by: Leonid Segal Acked-by: Pierluigi Passaro Signed-off-by: Stefano Radaelli Reviewed-by: Xu Yang Reviewed-by: Frank Li Reviewed-by: Fabio Estevam Reviewed-by: Ahmad Fatoum Link: https://patch.msgid.link/20251219160912.561431-1-stefano.r@variscite.com Signed-off-by: Vinod Koul Signed-off-by: Sasha Levin --- drivers/phy/freescale/phy-fsl-imx8mq-usb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c index f914f016b3d2c..043063699e064 100644 --- a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c +++ b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c @@ -206,6 +206,7 @@ static void imx8m_phy_tune(struct imx8mq_usb_phy *imx_phy) if (imx_phy->pcs_tx_swing_full != PHY_TUNE_DEFAULT) { value = readl(imx_phy->base + PHY_CTRL5); + value &= ~PHY_CTRL5_PCS_TX_SWING_FULL_MASK; value |= FIELD_PREP(PHY_CTRL5_PCS_TX_SWING_FULL_MASK, imx_phy->pcs_tx_swing_full); writel(value, imx_phy->base + PHY_CTRL5); -- 2.51.0