[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20191004.180819.285974760905355287.davem@davemloft.net>
Date: Fri, 04 Oct 2019 18:08:19 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: andrea.merello@...il.com
Cc: andrew@...n.ch, f.fainelli@...il.com, hkallweit1@...il.com,
netdev@...r.kernel.org
Subject: Re: [PATCH] net: phy: allow for reset line to be tied to a sleepy
GPIO controller
From: Andrea Merello <andrea.merello@...il.com>
Date: Fri, 4 Oct 2019 15:53:32 +0200
> mdio_device_reset() makes use of the atomic-pretending API flavor for
> handling the PHY reset GPIO line.
>
> I found no hint that mdio_device_reset() is called from atomic context
> and indeed it uses usleep_range() since long time, so I would assume that
> it is OK to sleep there.
>
> This patch switch to gpiod_set_value_cansleep() in mdio_device_reset().
> This is relevant if e.g. the PHY reset line is tied to a I2C GPIO
> controller.
>
> This has been tested on a ZynqMP board running an upstream 4.19 kernel and
> then hand-ported on current kernel tree.
>
> Signed-off-by: Andrea Merello <andrea.merello@...il.com>
Applied.
Powered by blists - more mailing lists