diff options
author | Christophe JAILLET <christophe.jaillet@wanadoo.fr> | 2021-08-20 20:43:33 +0200 |
---|---|---|
committer | Wolfram Sang <wsa@kernel.org> | 2022-02-07 15:52:41 +0100 |
commit | b205f5850263632b6897d8f0bfaeeea4955f8663 (patch) | |
tree | 4c6614acfb4d64f898556ed8f5ecec4563d3b83a /drivers/i2c/busses/i2c-npcm7xx.c | |
parent | 951285e59e8ac1d056780b3b5f024cdbdc9846d8 (diff) |
i2c: bcm2835: Fix the error handling in 'bcm2835_i2c_probe()'
Some resource should be released if an error occurs in
'bcm2835_i2c_probe()'.
Add an error handling path and the needed 'clk_disable_unprepare()' and
'clk_rate_exclusive_put()' calls.
While at it, rework the bottom of the function to use this newly added
error handling path and have an explicit and more standard "return 0;" at
the end of the normal path.
Fixes: bebff81fb8b9 ("i2c: bcm2835: Model Divider in CCF")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
[wsa: rebased]
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/i2c/busses/i2c-npcm7xx.c')
0 files changed, 0 insertions, 0 deletions