1. 20 Oct, 2014 1 commit
  2. 24 Jan, 2014 1 commit
    • Stephen Warren's avatar
      rtc: max8907: weekday encoding fixes · 75ea799d
      Stephen Warren authored
      The current MAX8907 driver has two issues related to weekday value
      handling:
      
      1)
      
      The HW WEEKDAY register has range 0..6 rather than 1..7 as documented.
      Note that I validated the actual HW range by observing the HW register
      roll from 6->0 rather than 6->7->1 as would otherwise be expected.
      
      This matches Linux's tm_wday range of 0..6.
      
      When the CMOS RAM content is lost, the date returned from the device is
      2007-01-01 00:00:00, which is a Monday.  The WEEKDAY register reads 1 in
      this case.  This matches the numbering in Linux's tm_wday field.
      
      Hence we should write Linux's tm_wday value to the register without
      modifying it.  Hence, remove the +1/-1 calculations for WEEKDAY/tm_wday.
      
      2)
      
      There's no need to make alarms match on the WEEKDAY register, since the
      other fields together uniquely define the alarm date/time.  Ignoring the
      WEEKDAY value in the match isolates the driver from any incorrect value in
      the current time copy of the WEEKDAY register.
      
      Each change individually, or both together, solves an issue that I
      observed; "hwclock -r" would time out waiting for its alarm to fire if the
      CMOS RAM content had been lost, and hence the WEEKDAY register value
      mismatched what the driver expected it to be.  "hwclock -w" would solve
      this by over-writing the HW default WEEKDAY register value with what the
      driver expected.
      Signed-off-by: Stephen Warren's avatarStephen Warren <swarren@nvidia.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      75ea799d
  3. 03 Jul, 2013 1 commit
  4. 30 Apr, 2013 2 commits
  5. 22 Feb, 2013 1 commit
  6. 03 Jan, 2013 1 commit
    • Greg Kroah-Hartman's avatar
      Drivers: rtc: remove __dev* attributes. · 5a167f45
      Greg Kroah-Hartman authored
      CONFIG_HOTPLUG is going away as an option.  As a result, the __dev*
      markings need to be removed.
      
      This change removes the use of __devinit, __devexit_p, __devinitdata,
      __devinitconst, and __devexit from these drivers.
      
      Based on patches originally written by Bill Pemberton, but redone by me
      in order to handle some of the coding style issues better, by hand.
      
      Cc: Bill Pemberton <wfp5p@virginia.edu>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Cc: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: Mike Frysinger <vapier.adi@gmail.com>
      Cc: Wan ZongShun <mcuos.com@gmail.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5a167f45
  7. 05 Oct, 2012 1 commit
    • Stephen Warren's avatar
      rtc: add MAX8907 RTC driver · 94c01ab6
      Stephen Warren authored
      The MAX8907 is an I2C-based power-management IC containing voltage
      regulators, a reset controller, a real-time clock, and a touch-screen
      controller.
      
      The driver is based on an original by or fixed by:
      * Tom Cherry
      * Prashant Gaikwad
      * Joseph Yoon
      
      During upstreaming, I (swarren):
      * Converted to regmap.
      * Fixed handling of RTC_HOUR register containing 12.
      * Fixed handling of RTC_WEEKDAY register.
      * General cleanup.
      Signed-off-by: Stephen Warren's avatarStephen Warren <swarren@nvidia.com>
      Cc: Tom Cherry <tcherry@nvidia.com>
      Cc: Prashant Gaikwad <pgaikwad@nvidia.com>
      Cc: Joseph Yoon <tyoon@nvidia.com>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      94c01ab6