projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f360668
)
rtc: m41t80: return NULL rather than a plain 0 integer
author
Colin Ian King
<colin.king@canonical.com>
Sat, 25 Sep 2021 22:34:41 +0000
(23:34 +0100)
committer
Alexandre Belloni
<alexandre.belloni@bootlin.com>
Fri, 1 Oct 2021 21:31:29 +0000
(23:31 +0200)
Function m41t80_sqw_register_clk returns a pointer to struct clk,
so returning a plain 0 integer isn't good practice. Fix this by
returning a NULL instead.
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link:
https://lore.kernel.org/r/20210925223441.182673-1-colin.king@canonical.com
drivers/rtc/rtc-m41t80.c
patch
|
blob
|
history
diff --git
a/drivers/rtc/rtc-m41t80.c
b/drivers/rtc/rtc-m41t80.c
index f736f8c22e963b39ab1db911c627dc7bef91a264..6d383b629d20a2e65a977468ca6ca36121ef4ece 100644
(file)
--- a/
drivers/rtc/rtc-m41t80.c
+++ b/
drivers/rtc/rtc-m41t80.c
@@
-557,7
+557,7
@@
static struct clk *m41t80_sqw_register_clk(struct m41t80_data *m41t80)
* registered automatically when being referenced.
*/
of_node_put(fixed_clock);
- return
0
;
+ return
NULL
;
}
/* First disable the clock */