aboutsummaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorBartosz Golaszewski <[email protected]>2020-11-09 17:34:06 +0100
committerAlexandre Belloni <[email protected]>2020-11-19 12:50:11 +0100
commit3a905c2d9544a418953d6c18668f0f853fbd9be9 (patch)
treec3a6428a3c94fa42176a7e8e7cd6bda5fd6970c1 /include/linux
parent25ece30561d247b2931b0d11d92e9c976a668771 (diff)
rtc: add devm_ prefix to rtc_nvmem_register()
rtc_nvmem_register() is a managed interface. It doesn't require any release function to be called at driver detach. To avoid confusing driver authors, let's rename it to devm_rtc_nvmem_register() and add it to the list of managed interfaces in Documentation/. Signed-off-by: Bartosz Golaszewski <[email protected]> Signed-off-by: Alexandre Belloni <[email protected]> Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/rtc.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/linux/rtc.h b/include/linux/rtc.h
index 0983ab9faffb..cbca651d8ca4 100644
--- a/include/linux/rtc.h
+++ b/include/linux/rtc.h
@@ -244,11 +244,11 @@ extern int rtc_hctosys_ret;
#endif
#ifdef CONFIG_RTC_NVMEM
-int rtc_nvmem_register(struct rtc_device *rtc,
- struct nvmem_config *nvmem_config);
+int devm_rtc_nvmem_register(struct rtc_device *rtc,
+ struct nvmem_config *nvmem_config);
#else
-static inline int rtc_nvmem_register(struct rtc_device *rtc,
- struct nvmem_config *nvmem_config)
+static inline int devm_rtc_nvmem_register(struct rtc_device *rtc,
+ struct nvmem_config *nvmem_config)
{
return 0;
}