Stop setting max_user_freq in rtc drivers
Subsystems (3)
Alexandre Belloni
maintainercover Stop setting max_user_freq in rtc drivers
max_user_freq has not been related to the hardware RTC since 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). It is not limited by the hardware capabilities and so it is not necessary to set it from the RTC drivers as a user with sufficient rights will be able to change the value. Also, max_user_freq is always clamped to 5000, there is not point in setting an higher value.
---
Alexandre Belloni (11):
rtc: sa1100: stop setting max_user_freq
rtc: ds1685: stop setting max_user_freq
rtc: pic32: stop setting max_user_freq
rtc: renesas-rtca3: stop setting max_user_freq
rtc: rv3028: stop setting max_user_freq
rtc: rv3032: stop setting max_user_freq
rtc: rv8803: stop setting max_user_freq
rtc: rx6110: stop setting max_user_freq
rtc: rx8010: stop setting max_user_freq
rtc: rx8025: stop setting max_user_freq
rtc: sh: stop setting max_user_freq
drivers/rtc/rtc-ds1685.c | 3 --- drivers/rtc/rtc-pic32.c | 2 -- drivers/rtc/rtc-renesas-rtca3.c | 1 - drivers/rtc/rtc-rv3028.c | 2 -- drivers/rtc/rtc-rv3032.c | 2 -- drivers/rtc/rtc-rv8803.c | 2 -- drivers/rtc/rtc-rx6110.c | 2 -- drivers/rtc/rtc-rx8010.c | 1 - drivers/rtc/rtc-rx8025.c | 2 -- drivers/rtc/rtc-sa1100.c | 3 --- drivers/rtc/rtc-sh.c | 1 - include/linux/rtc/ds1685.h | 1 - 12 files changed, 22 deletions(-)
---
base-commit: 384150d7a5b60c1086790a8ee07b0629f906cca2
change-id: 20251031-max_user_freq-53e362de297e
Best regards,
Signature · 1 line
Alexandre Belloni <[email protected]>
Alexandre Belloni
maintainerPATCH 1/11 rtc: sa1100: stop setting max_user_freq
max_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-sa1100.c | 3 --- 1 file changed, 3 deletions(-)
drivers/rtc/rtc-sa1100.c +0 -3
@@ -40,8 +40,6 @@#define RTC_DEF_DIVIDER (32768 - 1)#define RTC_DEF_TRIM 0 -#define RTC_FREQ 1024 -static irqreturn_t sa1100_rtc_interrupt (int irq,void *dev_id) {
@@ -202,7 +200,6 @@ int sa1100_rtc_init(struct platform_device *pdev, struct sa1100_rtc *info) } info->rtc->ops = &sa1100_rtc_ops; - info->rtc->max_user_freq =RTC_FREQ ; info->rtc->range_max =U32_MAX ; ret =devm_rtc_register_device (info->rtc);
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 2/11 rtc: ds1685: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-ds1685.c | 3 --- include/linux/rtc/ds1685.h | 1 - 2 files changed, 4 deletions(-)
drivers/rtc/rtc-ds1685.c +0 -3
@@ -1268,9 +1268,6 @@ ds1685_rtc_probe(struct platform_device *pdev) rtc_dev->range_min =RTC_TIMESTAMP_BEGIN_2000 ; rtc_dev->range_max =RTC_TIMESTAMP_END_2099 ; -/* Maximum periodic rate is 8192Hz (0.122070ms). */ - rtc_dev->max_user_freq =RTC_MAX_USER_FREQ ; -/* See if the platform doesn't support UIE. */ if (pdata->uie_unsupported)clear_bit (RTC_FEATURE_UPDATE_INTERRUPT , rtc_dev->features);
include/linux/rtc/ds1685.h +0 -1
@@ -324,7 +324,6 @@ struct ds1685_rtc_platform_data {#define RTC_SQW_2HZ 0x0f/* 0 1 1 1 1 */ #define RTC_SQW_0HZ 0x00/* 0 0 0 0 0 */ #define RTC_SQW_32768HZ 32768/* 1 - - - - */ -#define RTC_MAX_USER_FREQ 8192/*
Signature · 1 line
2.51.1
Re: [PATCH 02/11] rtc: ds1685: stop setting max_user_freq
Quoted 30 lines · Alexandre Belloni
max_user_freqhas not been related to the hardware RTC since commit6610e0893b8b("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.Signed-off-by Alexandre Belloni <[email protected]>--- drivers/rtc/rtc-ds1685.c | 3 --- include/linux/rtc/ds1685.h | 1 - 2 files changed, 4 deletions(-)drivers/rtc/rtc-ds1685.c +0
-3@@ -1268,9 +1268,6 @@ ds1685_rtc_probe(struct platform_device *pdev) rtc_dev->range_min =RTC_TIMESTAMP_BEGIN_2000 ; rtc_dev->range_max =RTC_TIMESTAMP_END_2099 ; -/* Maximum periodic rate is 8192Hz (0.122070ms). */ - rtc_dev->max_user_freq =RTC_MAX_USER_FREQ ; -/* See if the platform doesn't support UIE. */ if (pdata->uie_unsupported)clear_bit (RTC_FEATURE_UPDATE_INTERRUPT , rtc_dev->features);include/linux/rtc/ds1685.h +0
-0
include/linux/rtc/ds1685.h struct ds1685_rtc_platform_data { · line 329
Quoted 7 lines
include/linux/rtc/ds1685.h +0
-1@@ -324,7 +324,6 @@ struct ds1685_rtc_platform_data {#define RTC_SQW_2HZ 0x0f/* 0 1 1 1 1 */ #define RTC_SQW_0HZ 0x00/* 0 0 0 0 0 */ #define RTC_SQW_32768HZ 32768/* 1 - - - - */ -#define RTC_MAX_USER_FREQ 8192/*
Alexandre Belloni
maintainerPATCH 3/11 rtc: pic32: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-pic32.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-pic32.c +0 -2
@@ -340,8 +340,6 @@ static int pic32_rtc_probe(struct platform_device *pdev)if (ret) goto err_nortc; - pdata->rtc->max_user_freq =128 ; -pic32_rtc_setfreq (&pdev->dev,1 ); ret = devm_request_irq(&pdev->dev, pdata->alarm_irq, pic32_rtc_alarmirq, 0,
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 4/11 rtc: renesas-rtca3: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-renesas-rtca3.c | 1 - 1 file changed, 1 deletion(-)
drivers/rtc/rtc-renesas-rtca3.c +0 -1
@@ -772,7 +772,6 @@ static int rtca3_probe(struct platform_device *pdev)return PTR_ERR (priv->rtc_dev); priv->rtc_dev->ops = &rtca3_ops; - priv->rtc_dev->max_user_freq =256 ; priv->rtc_dev->range_min =RTC_TIMESTAMP_BEGIN_2000 ; priv->rtc_dev->range_max =RTC_TIMESTAMP_END_2099 ;
Signature · 1 line
2.51.1
Re: [PATCH 04/11] rtc: renesas-rtca3: stop setting max_user_freq
Quoted 5 lines · Alexandre Belloni
max_user_freqhas not been related to the hardware RTC since commit6610e0893b8b("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.Signed-off-by Alexandre Belloni <[email protected]>
Quoted 17 lines
--- drivers/rtc/rtc-renesas-rtca3.c | 1 - 1 file changed, 1 deletion(-)drivers/rtc/rtc-renesas-rtca3.c +0
-1@@ -772,7 +772,6 @@ static int rtca3_probe(struct platform_device *pdev)return PTR_ERR (priv->rtc_dev); priv->rtc_dev->ops = &rtca3_ops; - priv->rtc_dev->max_user_freq =256 ; priv->rtc_dev->range_min =RTC_TIMESTAMP_BEGIN_2000 ; priv->rtc_dev->range_max =RTC_TIMESTAMP_END_2099 ;
Alexandre Belloni
maintainerPATCH 5/11 rtc: rv3028: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rv3028.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-rv3028.c +0 -2
@@ -1023,8 +1023,6 @@ static int rv3028_probe(struct i2c_client *client) eeprom_cfg.priv = rv3028;devm_rtc_nvmem_register (rv3028->rtc, &eeprom_cfg); - rv3028->rtc->max_user_freq =1 ; -#ifdef CONFIG_COMMON_CLK rv3028_clkout_register_clk (rv3028, client);#endif
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 6/11 rtc: rv3032: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rv3032.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-rv3032.c +0 -2
@@ -968,8 +968,6 @@ static int rv3032_probe(struct i2c_client *client) eeprom_cfg.priv = rv3032;devm_rtc_nvmem_register (rv3032->rtc, &eeprom_cfg); - rv3032->rtc->max_user_freq =1 ; -#ifdef CONFIG_COMMON_CLK rv3032_clkout_register_clk (rv3032, client);#endif
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 7/11 rtc: rv8803: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rv8803.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-rv8803.c +0 -2
@@ -738,8 +738,6 @@ static int rv8803_probe(struct i2c_client *client)devm_rtc_nvmem_register (rv8803->rtc, &nvmem_cfg); - rv8803->rtc->max_user_freq =1 ; -return 0 ; }
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 8/11 rtc: rx6110: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rx6110.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-rx6110.c +0 -2
@@ -324,8 +324,6 @@ static int rx6110_probe(struct rx6110_data *rx6110, struct device *dev)if (err)return err; - rx6110->rtc->max_user_freq =1 ; -return 0 ; }
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 9/11 rtc: rx8010: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rx8010.c | 1 - 1 file changed, 1 deletion(-)
drivers/rtc/rtc-rx8010.c +0 -1
@@ -412,7 +412,6 @@ static int rx8010_probe(struct i2c_client *client) } rx8010->rtc->ops = &rx8010_rtc_ops; - rx8010->rtc->max_user_freq =1 ; rx8010->rtc->range_min =RTC_TIMESTAMP_BEGIN_2000 ; rx8010->rtc->range_max =RTC_TIMESTAMP_END_2099 ;
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 10/11 rtc: rx8025: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-rx8025.c | 2 -- 1 file changed, 2 deletions(-)
drivers/rtc/rtc-rx8025.c +0 -2
@@ -565,8 +565,6 @@ static int rx8025_probe(struct i2c_client *client)clear_bit (RTC_FEATURE_ALARM , rx8025->rtc->features); } - rx8025->rtc->max_user_freq =1 ; -set_bit (RTC_FEATURE_ALARM_RES_MINUTE , rx8025->rtc->features);clear_bit (RTC_FEATURE_UPDATE_INTERRUPT , rx8025->rtc->features);
Signature · 1 line
2.51.1
Alexandre Belloni
maintainerPATCH 11/11 rtc: sh: stop setting max_user_freq
In reply to Alexandre Bellonimax_user_freq has not been related to the hardware RTC since commit 6610e0893b8b ("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.
--- drivers/rtc/rtc-sh.c | 1 - 1 file changed, 1 deletion(-)
drivers/rtc/rtc-sh.c +0 -1
@@ -423,7 +423,6 @@ static int __init sh_rtc_probe(struct platform_device *pdev)writeb (tmp, rtc->regbase +RCR1 ); rtc->rtc_dev->ops = &sh_rtc_ops; - rtc->rtc_dev->max_user_freq =256 ;if (rtc->capabilities &RTC_CAP_4_DIGIT_YEAR ) { rtc->rtc_dev->range_min =RTC_TIMESTAMP_BEGIN_1900 ;
Signature · 1 line
2.51.1
Re: [PATCH 11/11] rtc: sh: stop setting max_user_freq
Quoted 5 lines · Alexandre Belloni
max_user_freqhas not been related to the hardware RTC since commit6610e0893b8b("RTC: Rework RTC code to use timerqueue for events"). Stop setting it from individual driver to avoid confusing new contributors.Signed-off-by Alexandre Belloni <[email protected]>