r8152: replace several functions about phy patch request
authorHayes Wang <hayeswang@realtek.com>
Wed, 3 Feb 2021 09:14:28 +0000 (17:14 +0800)
committerPhil Elwell <8911409+pelwell@users.noreply.github.com>
Mon, 19 Apr 2021 21:43:59 +0000 (22:43 +0100)
commit0acb3cd0993256e9a0379d97d61543d9122bd7fc
treedac423abf1c74758ff4b639b3008fc142b2ea9d7
parent167ddba938321ab21cf409cce5ad9f3aea5820b0
r8152: replace several functions about phy patch request

commit a08c0d309d8c078d22717d815cf9853f6f2c07bd upstream.

Replace r8153_patch_request() with rtl_phy_patch_request().
Replace r8153_pre_ram_code() with rtl_pre_ram_code().
Replace r8153_post_ram_code() with rtl_post_ram_code().
Add rtl_patch_key_set().

The new functions have an additional parameter. It is used to wait
the patch request command finished. When the PHY is resumed from
the state of power cut, the PHY is at a safe mode and the
OCP_PHY_PATCH_STAT wouldn't be updated. For this situation, it is
safe to set patch request command without waiting OCP_PHY_PATCH_STAT.

Signed-off-by: Hayes Wang <hayeswang@realtek.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/usb/r8152.c