Commit 108b4c3638be251d6b42eaa633e8a6b852b960f0

Authored by Mike Frysinger
Committed by Linus Torvalds
1 parent fcbaa088fc

rtc: tweak driver documentation for rtc periodic

The max_user_freq member is not really meant for RTC drivers to modify, so
update the rtc documentation so drivers writers know what is expected of
them when handling periodic events.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Acked-by: Alessandro Zummo <a.zummo@towertech.it>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 4 additions and 3 deletions Side-by-side Diff

Documentation/rtc.txt
... ... @@ -180,9 +180,10 @@
180 180 * RTC_IRQP_SET, RTC_IRQP_READ: the irq_set_freq function will be called
181 181 to set the frequency while the framework will handle the read for you
182 182 since the frequency is stored in the irq_freq member of the rtc_device
183   - structure. Also make sure you set the max_user_freq member in your
184   - initialization routines so the framework can sanity check the user
185   - input for you.
  183 + structure. Your driver needs to initialize the irq_freq member during
  184 + init. Make sure you check the requested frequency is in range of your
  185 + hardware in the irq_set_freq function. If you cannot actually change
  186 + the frequency, just return -ENOTTY.
186 187  
187 188 If all else fails, check out the rtc-test.c driver!
188 189