]> git.dujemihanovic.xyz Git - u-boot.git/commit
net: fec: prevent undesired de-assertion of phy-reset on request
authorTim Harvey <tharvey@gateworks.com>
Tue, 1 Mar 2022 20:15:01 +0000 (12:15 -0800)
committerRamon Fried <ramon@neureality.ai>
Sun, 10 Apr 2022 05:44:13 +0000 (08:44 +0300)
commit4223fb0ee18d11462c55ac94198fdc2055f2c27c
tree21cd313ece92ebd9c138685a5eb41f8b558d931e
parente24b58f5ed4f9a0b5b1c80a5f35aa71fcad7f233
net: fec: prevent undesired de-assertion of phy-reset on request

When gpio_request_by_name allocates a gpio output it by default will
de-assert the gpio which for phy-reset will take the PHY out of reset.
As this occurs before fec_gpio_reset is called to assert the reset
line it can cause undesired affects if reset timings are not properly
met.

Configure the gpio with GPIOD_IS_OUT_ACTIVE so that reset is kept active
(reset asserted) to avoid this.

Cc: Sean Anderson <sean.anderson@seco.com>
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Tested-by: Adam Ford <aford173@gmail.com> #imx8mm-beacon
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
drivers/net/fec_mxc.c