04 Aug, 2011

1 commit

  • As the comment explains, the intention of the code is to clear the
    OMAP_RTC_CTRL_MODE_12_24 bit, but instead it only clears the
    OMAP_RTC_CTRL_SPLIT and OMAP_RTC_CTRL_AUTO_COMP bits, which should be
    kept. OMAP_RTC_CTRL_DISABLE, OMAP_RTC_CTRL_SET_32_COUNTER,
    OMAP_RTC_CTRL_TEST, and OMAP_RTC_CTRL_ROUND_30S are also better off
    being cleared.

    Signed-off-by: Daniel Glöckner
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Daniel Glöckner
     

18 Apr, 2011

1 commit

  • In omap_rtc_probe error path, free_irq() was using NULL rather than the
    driver data as the data pointer so free_irq() wouldn't have matched.

    Signed-off-by: Axel Lin
    Cc: "George G. Davis"
    Cc: Alessandro Zummo
    Cc: rtc-linux@googlegroups.com
    Link: http://lkml.kernel.org/r/%3C1303005778.2889.2.camel%40phoenix%3E
    Signed-off-by: Thomas Gleixner

    Axel Lin
     

10 Mar, 2011

1 commit

  • With the generic RTC rework, the UIE mode irqs are handled
    in the generic layer, and only hardware specific ioctls
    get passed down to the rtc driver layer.

    So this patch removes the UIE mode ioctl handling in the rtc
    driver layer, which never get used.

    CC: Thomas Gleixner
    CC: Alessandro Zummo
    CC: Marcelo Roberto Jimenez
    CC: rtc-linux@googlegroups.com
    Signed-off-by: John Stultz

    John Stultz
     

04 Feb, 2011

1 commit

  • Some rtc drivers use the ioctl method instead of the alarm_irq_enable
    method for enabling alarm interupts. With the new virtualized RTC
    rework, its important for drivers to use the alarm_irq_enable instead.

    This patch converts the drivers that use the AIE ioctl method to
    use the alarm_irq_enable method. Other ioctl cmds are left untouched.

    I have not been able to test or even compile most of these drivers.
    Any help to make sure this change is correct would be appreciated!

    CC: Alessandro Zummo
    CC: Thomas Gleixner
    CC: Marcelo Roberto Jimenez
    Reported-by: Marcelo Roberto Jimenez
    Tested-by: Marcelo Roberto Jimenez
    Signed-off-by: John Stultz

    John Stultz
     

14 Jan, 2011

1 commit

  • request_mem_region() will call kzalloc to allocate memory for struct
    resource. release_resource() unregisters the resource but does not free
    the allocated memory, thus use release_mem_region() instead to fix the
    memory leak.

    Also add a missing iounmap() in omap_rtc_remove().

    Signed-off-by: Axel Lin
    Cc: Alessandro Zummo
    Cc: Sekhar Nori
    Cc: Kevin Hilman
    Cc: Tony Lindgren
    Acked-by: Mark A. Greer
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Axel Lin
     

28 Oct, 2010

1 commit

  • The rtc-omap driver currently hardcodes the RTC wakeup capability to be
    "not capable". While this seems to be true for existing OMAP1 boards
    which are not wired for this, the DA850/OMAP-L138 SoC, the RTC can always
    be wake up source from its "deep sleep" mode.

    This patch lets the wakeup capability be set from platform data and does
    not override the setting from the driver. For DA850/OMAP-L138, this is
    done from arch/arm/mach-davinci/devices-da8xx.c:da8xx_register_rtc()

    Note that this patch does not change the behavior on any existing OMAP1
    board since the platform device registration sets the wakeup capability to
    0 by default.

    Signed-off-by: Sekhar Nori
    Signed-off-by: Kevin Hilman
    Cc: Alessandro Zummo
    Cc: Wan ZongShun
    Cc: Tony Lindgren
    Cc: David Brownell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sekhar Nori
     

16 Dec, 2009

1 commit

  • The rtc-omap driver currently assumes that the rtc's registers are at a
    fixed address and already mapped into virtual memory space. Remove those
    assumptions so the same driver can be used for similar devices that reside
    at different physical addresses (e.g., TI's DA8xx/OMAP-L13x SoC's).

    Also allow the possibility for the timer and alarm interrupts to use the
    same IRQ.

    Signed-off-by: Mark A. Greer
    Acked-by: David Brownell
    Acked-by: Kevin Hilman
    Acked-by: Tony Lindgren
    Signed-off-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mark A. Greer
     

21 Sep, 2009

1 commit


25 Mar, 2009

1 commit


20 Oct, 2008

1 commit

  • Change drivers/rtc/ to use the new bcd2bin/bin2bcd functions instead of
    the obsolete BCD_TO_BIN/BIN_TO_BCD/BCD2BIN/BIN2BCD macros.

    Signed-off-by: Adrian Bunk
    Acked-by: Alessandro Zummo
    Cc: David Brownell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     

25 Jul, 2008

1 commit

  • Shrink the runtime footprint of the OMAP1 RTC driver a bunch by removing
    some old hacks and switching to platform_driver_probe().

    Signed-off-by: David Brownell
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     

22 May, 2008

1 commit

  • asm/mach/time.h is the ARM header file for setting up kernel ticker
    timekeeping (be that the old jiffy interrupt or the new clocksource.)
    RTC drivers have no business using this header file, and in fact do
    not require it.

    Build tested on at91sam9rl, omap and s3c2410 configurations.

    Acked-by: Alessandro Zummo
    Acked-by: Andrew Victor
    Signed-off-by: Russell King

    Russell King
     

11 Apr, 2008

1 commit

  • Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
    prefixed with "platform:". Add MODULE_ALIAS() to the hotpluggable RTC
    platform drivers, to re-enable module auto loading.

    [dbrownell@users.sourceforge.net: more drivers, minor fix]
    Signed-off-by: Kay Sievers
    Signed-off-by: David Brownell
    Cc: Greg KH
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kay Sievers
     

17 May, 2007

1 commit


09 May, 2007

4 commits

  • This fixes a common glitch in how RTC drivers handle two "set alarm" modes,
    by getting rid of the surprising/hidden one that was rarely implemented
    correctly (and which could expose nonportable hardware-specific behavior).

    The glitch comes from the /dev/rtcX logic implementing the legacy
    RTC_ALM_SET (limited to 24 hours, needing RTC_AIE_ON) ioctl on top of the
    RTC driver call providing access to the newer RTC_WKALM_SET (without those
    limitations) by initializing the day/month/year fields to be invalid ...
    that second mode.

    Now, since few RTC drivers check those fields, and most hardware misbehaves
    when faced with invalid date fields, many RTC drivers will set bogus alarm
    times on those RTC_ALM_SET code paths. (Several in-tree drivers have that
    issue, and I also noticed it with code reviews on several new RTC drivers.)

    This patch ensures that RTC drivers never see such invalid alarm fields, by
    moving some logic out of rtc-omap into the RTC_ALM_SET code and adding an
    explicit check (which will prevent the issue on other code paths).

    Signed-off-by: David Brownell
    Cc: Scott Wood
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     
  • RTC class suspend/resume support, re-initializing the system clock on resume
    from the clock used to initialize it at boot time.

    - The reinit-on-resume is hooked to the existing RTC_HCTOSYS config
    option, on the grounds that a clock good enough for init must also
    be good enough for re-init.

    - Inlining a version of the code used by ARM, to save and restore the
    delta between a selected RTC and the current system wall-clock time.

    - Removes calls to that ARM code from AT91, OMAP1, and S3C RTCs. This
    means that systems using those RTCs across suspend/resume will likely
    want to change their kernel configs to enable RTC_HCTOSYS.

    If HCTOSYS isn't using a second RTC (with battery?), this changes the
    system's initial date from Jan 1970 to the epoch this hardware uses:
    1998 for AT91, 2000 for OMAP1 (assuming no split power mode), etc.

    This goes on top of the patch series removing "struct class_device" usage
    from the RTC framework. That's all needed for class suspend()/resume().

    Signed-off-by: David Brownell
    Acked-by: Greg Kroah-Hartman
    Acked-By: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     
  • Finish converting the RTC framework so it no longer uses class_device.

    Signed-off-by: David Brownell
    Acked-by: Greg Kroah-Hartman
    Acked-By: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     
  • This patch removes class_device from the programming interface that the RTC
    framework exposes to the rest of the kernel. Now an rtc_device is passed,
    which is more type-safe and streamlines all the relevant code.

    Signed-off-by: David Brownell
    Acked-by: Greg Kroah-Hartman
    Acked-By: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     

15 Feb, 2007

1 commit

  • The obsolete SA_xxx interrupt flags have been used despite the scheduled
    removal. Fixup the remaining users.

    Signed-off-by: Thomas Gleixner
    Acked-by: Ingo Molnar
    Cc: "Luck, Tony"
    Cc: Roman Zippel
    Cc: Geert Uytterhoeven
    Cc: Jeff Garzik
    Cc: Wim Van Sebroeck
    Cc: Roland Dreier
    Cc: Alessandro Zummo
    Cc: James Bottomley
    Cc: Greg KH
    Cc: Dave Airlie
    Cc: James Simmons
    Cc: "Antonino A. Daplas"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Thomas Gleixner
     

14 Dec, 2006

1 commit

  • Fix a glitch in the procfs dumping of whether the alarm IRQ is enabled: use
    the traditional name (from drivers/char/rtc.c and many other places) of
    "alarm_IRQ", not "alrm_wakeup" (which didn't even match the efirtc code, which
    originated that reporting API).

    Also, update a few of the RTC drivers to stop providing that duplicate status,
    and/or to expose it properly when reporting the alarm state. We really don't
    want every RTC driver doing their own thing here...

    Signed-off-by: David Brownell
    Acked-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     

08 Dec, 2006

1 commit

  • This creates a new RTC-framework driver for the RTC/calendar module found
    in various OMAP1 chips. (OMAP2 and OMAP3 use external RTCs, like those in
    TI's multifunction PM companion chips.) It's been in the Linux-OMAP tree
    for several months now, and other trees before that, so it's quite stable.
    The most notable issue is that the OMAP IRQ code doesn't yet support the
    RTC IRQ as a wakeup event. Once that's fixed, a patch will be needed.

    Signed-off-by: David Brownell
    Acked-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell