]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
misc: sram: enable clock before registering regions
authorJohan Hovold <johan@kernel.org>
Tue, 3 Jul 2018 10:05:48 +0000 (12:05 +0200)
committerJuerg Haefliger <juergh@canonical.com>
Wed, 24 Jul 2019 01:50:34 +0000 (19:50 -0600)
commitcff00e15b5cc9713244c3600695f770f73045b0b
treece05e953a8b3deb368f0e2a121741f4173c5b23b
parenta7ab731fd1bf1e69352483e4e03ece23b8781694
misc: sram: enable clock before registering regions

BugLink: https://bugs.launchpad.net/bugs/1836287
[ Upstream commit d5b9653dd2bb7a2b1c8cc783c5d3b607bbb6b271 ]

Make sure to enable the clock before registering regions and exporting
partitions to user space at which point we must be prepared for I/O.

Fixes: ee895ccdf776 ("misc: sram: fix enabled clock leak on error path")
Signed-off-by: Johan Hovold <johan@kernel.org>
Reviewed-by: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/misc/sram.c