Skip to content

Commit 6e47497

Browse files
Chih Kai Hsugregkh
authored andcommitted
r8152: fix incorrect register write to USB_UPHY_XTAL
[ Upstream commit 48afd51 ] The old code used ocp_write_byte() to clear the OOBS_POLLING bit (BIT(8)) in the USB_UPHY_XTAL register, but this doesn't correctly clear a bit in the upper byte of the 16-bit register. Fix this by using ocp_write_word() instead. Fixes: 195aae3 ("r8152: support new chips") Signed-off-by: Chih Kai Hsu <hsu.chih.kai@realtek.com> Reviewed-by: Hayes Wang <hayeswang@realtek.com> Link: https://patch.msgid.link/20260326073925.32976-454-nic_swsd@realtek.com Signed-off-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent ea04b98 commit 6e47497

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/net/usb/r8152.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3859,7 +3859,7 @@ static void r8156_ups_en(struct r8152 *tp, bool enable)
38593859
case RTL_VER_15:
38603860
ocp_data = ocp_read_word(tp, MCU_TYPE_USB, USB_UPHY_XTAL);
38613861
ocp_data &= ~OOBS_POLLING;
3862-
ocp_write_byte(tp, MCU_TYPE_USB, USB_UPHY_XTAL, ocp_data);
3862+
ocp_write_word(tp, MCU_TYPE_USB, USB_UPHY_XTAL, ocp_data);
38633863
break;
38643864
default:
38653865
break;

0 commit comments

Comments
 (0)