net: ethernet: ti: am65-cpts: update ret when ptp_clock is ERROR
authorWang Qing <wangqing@vivo.com>
Thu, 12 Nov 2020 16:45:41 +0000 (18:45 +0200)
committerJakub Kicinski <kuba@kernel.org>
Fri, 13 Nov 2020 23:25:43 +0000 (15:25 -0800)
commit81e329e93b860b31c216b40eb5e1373db0ffe0ba
treec06786f7f344cd0681ca07031e5e40973c64706e
parent8c07205aea36ccebe9fc5f97287a8bc416cea197
net: ethernet: ti: am65-cpts: update ret when ptp_clock is ERROR

We always have to update the value of ret, otherwise the
 error value may be the previous one.

Fixes: f6bd59526ca5 ("net: ethernet: ti: introduce am654 common platform time sync driver")
Signed-off-by: Wang Qing <wangqing@vivo.com>
[grygorii.strashko@ti.com: fix build warn, subj add fixes tag]
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Acked-by: Richard Cochran <richardcochran@gmail.com>
Link: https://lore.kernel.org/r/20201112164541.3223-1-grygorii.strashko@ti.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/ti/am65-cpts.c