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 <bgolaszewski@baylibre.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20201109163409.24301-6-brgl@bgdev.pl
This commit is contained in:
Bartosz Golaszewski 2020-11-09 17:34:06 +01:00 committed by Alexandre Belloni
parent 25ece30561
commit 3a905c2d95
29 changed files with 35 additions and 34 deletions

View file

@ -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;
}