ramips: mtk_eth_soc: allow multiple resets
authorLech Perczak <lech.perczak@gmail.com>
Fri, 15 Dec 2023 16:15:47 +0000 (17:15 +0100)
committerHauke Mehrtens <hauke@hauke-m.de>
Tue, 2 Jan 2024 20:56:52 +0000 (21:56 +0100)
commit3f1be8edee29fe79fc33c88cbd9d647a490410e5
treecbcd5461934ff12ad2d77822dafc770dd39449e1
parentfdb87a91b4202ad1a58fe46f499e4e68bf82de4e
ramips: mtk_eth_soc: allow multiple resets

Use devm_reset_control_array_get_exclusive to register multiple
reset lines in FE driver. This is required to reattach ESW reset to FE
driver again, based on device tree bindings.

While at that, remove unused fe_priv.rst_ppe field, and add error
message if getting the reset fails.

Fixes: 60fadae62b64 ("ramips: ethernet: ralink: move reset of the esw into the esw instead of fe")
Co-developed-by: Maxim Anisimov <maxim.anisimov.ua@gmail.com>
Signed-off-by: Maxim Anisimov <maxim.anisimov.ua@gmail.com>
[Split out of the bigger commit, provide commit mesage, refactor error
handling]
Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
target/linux/ramips/files/drivers/net/ethernet/ralink/mtk_eth_soc.c
target/linux/ramips/files/drivers/net/ethernet/ralink/mtk_eth_soc.h