summaryrefslogtreecommitdiff
path: root/init
diff options
context:
space:
mode:
authorChen-Yu Tsai <wens@csie.org>2018-12-17 07:04:40 +0300
committerMarcel Holtmann <marcel@holtmann.org>2018-12-19 02:28:38 +0300
commit8c08947b7c4f4496e7c23be970121280fcb6cbf5 (patch)
treeeaec0047012f2b001e05840eda702e5dc91e1c50 /init
parent28ac03b9ac3f784c2f048a910c8d0a7a87483b66 (diff)
downloadlinux-8c08947b7c4f4496e7c23be970121280fcb6cbf5.tar.xz
Bluetooth: hci_bcm: Simplify clk_get error handling
The driver currently checks the clk pointer for an error condition, as returned by clk_get, before every invocation of the clk consumer API. This is redundant if the goal is simply to ignore the errors, thereby making the clk optional. The clk consumer API already checks if the pointer is NULL or not. Simplify the code a bit by assigning NULL to the clk pointer if the error condition is one we want to ignore, which is every error except deferred probing. Tested-by: Ondrej Jirman <megous@megous.com> Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions