On Mon, May 21, 2018 at 03:11:21PM +0200, Marek Vasut wrote: > The rcar_pcie_get_resources() is another misnomer with a side effect. > The function does not only get resources, but also enables/disables bus > clock. This is forgotten in the probe() function though and if anything > in probe() fails after rcar_pcie_get_resources() is called, the bus > clock are never disabled. > > This patch pulls the clock handling out of the rcar_pcie_get_resources() > and enables clock after all the resources were requested. Moreover, this > patch also always disables the clock in case of failure. > > Signed-off-by: Marek Vasut <marek.vasut+renesas@xxxxxxxxx> > Cc: Geert Uytterhoeven <geert+renesas@xxxxxxxxx> > Cc: Phil Edworthy <phil.edworthy@xxxxxxxxxxx> > Cc: Simon Horman <horms+renesas@xxxxxxxxxxxx> > Cc: Wolfram Sang <wsa@xxxxxxxxxxxxx> > Cc: linux-renesas-soc@xxxxxxxxxxxxxxx Reviewed-by: Simon Horman <horms+renesas@xxxxxxxxxxxx>