diff options
author | Simon Baatz <gmbnomis@gmail.com> | 2017-03-27 18:02:07 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-05-25 13:44:48 (GMT) |
commit | e437af936a49680ac509b9d51f1b51b11c8da605 (patch) | |
tree | 711c2f8e5bf42407c1b0f206e8273f91b407b8c2 /mm | |
parent | db663641619558c9a1b8b77f5bfd351e131b57a7 (diff) | |
download | linux-e437af936a49680ac509b9d51f1b51b11c8da605.tar.xz |
mtd: nand: orion: fix clk handling
commit 675b11d94ce9baa5eb365a51b35d2793f77c8ab8 upstream.
The clk handling in orion_nand.c had two problems:
- In the probe function, clk_put() was called for an enabled clock,
which violates the API (see documentation for clk_put() in
include/linux/clk.h)
- In the error path of the probe function, clk_put() could be called
twice for the same clock.
In order to clean this up, use the managed function devm_clk_get() and
store the pointer to the clk in the driver data.
Fixes: baffab28b13120694fa3ebab08d3e99667a851d2 ('ARM: Orion: fix driver probe error handling with respect to clk')
Signed-off-by: Simon Baatz <gmbnomis@gmail.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'mm')
0 files changed, 0 insertions, 0 deletions