14 Aug, 2013

1 commit


01 Aug, 2013

1 commit


11 Jul, 2013

1 commit

  • Pull MFD update from Samuel Ortiz:
    "For the 3.11 merge we only have one new MFD driver for the Kontron
    PLD.

    But we also have:
    - Support for the TPS659038 PMIC from the palmas driver.
    - Intel's Coleto Creek and Avoton SoCs support from the lpc_ich
    driver.
    - RTL8411B support from the rtsx driver.
    - More DT support for the Arizona, max8998, twl4030-power and the
    ti_am335x_tsadc drivers.
    - The SSBI driver move under MFD.
    - A conversion to the devm_* API for most of the MFD drivers.
    - The twl4030-power got split from twl-core into its own module.
    - A major ti_am335x_adc cleanup, leading to a proper DT support.
    - Our regular arizona and wm* updates and cleanups from the Wolfson
    folks.
    - A better error handling and initialization, and a regulator
    subdevice addition for the 88pm80x driver.
    - A bulk platform_set_drvdata() call removal that's no longer need
    since commit 0998d0631001 ("device-core: Ensure drvdata = NULL when
    no driver is bound")

    * tag 'mfd-3.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-next: (102 commits)
    mfd: sec: Provide max_register to regmap
    mfd: wm8994: Remove duplicate check for active JACKDET
    MAINTAINERS: Add include directory to MFD file patterns
    mfd: sec: Remove fields not used since regmap conversion
    watchdog: Kontron PLD watchdog timer driver
    mfd: max8998: Add support for Device Tree
    regulator: max8998: Use arrays for specifying voltages in platform data
    mfd: max8998: Add irq domain support
    regulator: palmas: Add TPS659038 support
    mfd: Kontron PLD mfd driver
    mfd: palmas: Add TPS659038 PMIC support
    mfd: palmas: Add SMPS10_BOOST feature
    mfd: palmas: Check if irq is valid
    mfd: lpc_ich: iTCO_wdt patch for Intel Coleto Creek DeviceIDs
    mfd: twl-core: Change TWL6025 references to TWL6032
    mfd: davinci_voicecodec: Fix build breakage
    mfd: vexpress: Make the driver optional for arm and arm64
    mfd: htc-egpio: Use devm_ioremap_nocache() instead of ioremap_nocache()
    mfd: davinci_voicecodec: Convert to use devm_* APIs
    mfd: twl4030-power: Fix relocking on error
    ...

    Linus Torvalds
     

10 Jul, 2013

1 commit


04 Jul, 2013

36 commits

  • On CSR SiRFprimaII/atlasVI, there is a programmable 16-bit divider
    (RTC_DIV) that divides the input 32.768KHz clock to the frequency that
    users need (E.g. 1 Hz). The divided real-time clock will be used to
    drive a 32-bit counter (RTC_COUNTER) that provides users with the actual
    time.

    In each cycle of the divided real-time clock, there is a Hertz interrupt
    generated to the RISC. Users can also configure an alarm (RTC_ALARM).
    When RTC_COUNTER matches the alarm, there will be an alarm interrupt
    generated to the RISC.

    The system RTC can generate an alarm wake-up signal to notify the power
    controller to wake up from power saving mode.

    Signed-off-by: Xianglong Du
    Signed-off-by: Barry Song
    Cc: Jingoo Han
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Xianglong Du
     
  • Use module_platform_driver_probe() macro which makes the code smaller and
    simpler.

    Signed-off-by: Fabio Porcedda
    Cc: Alessandro Zummo
    Cc: Jingoo Han
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Fabio Porcedda
     
  • rtc-omap driver modules is used both by OMAP1/2, Davinci SoC platforms.

    However, rtc wake support on OMAP1 is broken. Hence the
    device_init_wakeup() was removed from rtc-omap driver and moved to
    platform board files that supported it (DA850/OMAP-L138). [1]

    However, recently [2] it was suggested that driver should always do a
    device_init_wakeup(dev, true). Platforms that don't want/need
    wakeup support can disable it from userspace via:

    echo disabled > /sys/devices/.../power/wakeup

    Also, with the new DT boot-up, board file doesn't exist and hence there
    is no way to have device wakeup support rtc.

    The fix for above issues, is to hard code device_init_wakeup() inside
    driver and let platforms that don't need this, handle it through the
    sysfs power entry.

    [1]
    https://patchwork.kernel.org/patch/136731/

    [2]
    http://www.mail-archive.com/davinci-linux-open-source@linux.
    davincidsp.com/msg26077.html

    Signed-off-by: Hebbar Gururaja
    Cc: Alessandro Zummo
    Acked-by: Kevin Hilman
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Hebbar Gururaja
     
  • Added support for NXP PCF2127 RTC (i2c).

    [akpm@linux-foundation.org: fix typo, fix warnings]
    Signed-off-by: Renaud Cerrato
    Cc: Jingoo Han
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Renaud Cerrato
     
  • Enable dev as wakeup device before calling rtc_device_register(), so that
    it can create the "wakealarm" sysfs.

    Signed-off-by: Wei Ni
    Acked-by: Laxman Dewangan
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Wei Ni
     
  • Convert drivers/rtc/class to use dev_pm_ops for power management and
    remove Legacy PM ops hooks. With this change, rtc class registers
    suspend/resume callbacks via class->pm (dev_pm_ops) instead of Legacy
    class->suspend/resume. When __device_suspend() runs call-backs, it will
    find class->pm ops for the rtc class.

    Signed-off-by: Shuah Khan
    Signed-off-by: Jingoo Han
    Cc: Shuah Khan
    Cc: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Shuah Khan
     
  • The usage of strict_strtoul() is not preferred, because strict_strtoul()
    is obsolete. Thus, kstrtoul() should be used.

    Signed-off-by: Jingoo Han
    Reviewed-by: Andy Shevchenko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jingoo Han
     
  • If rtc->irq_task is non-NULL and task is NULL, they always
    rtc_irq_set_freq(), whenever err is set to -EBUSY it will then immediately
    be set to -EACCES, misleading the caller as to the underlying problem.

    Signed-off-by: Chris Brand
    Acked-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Chris Brand
     
  • Use module_platform_driver() to register the platform driver.

    Signed-off-by: Peter Ujfalusi
    Acked-by: Kevin Hilman
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Peter Ujfalusi
     
  • Initialize the rtc_reg_map in platform_driver's probe function instead at
    module_init time. This way we can make sure that the twl-core has been
    already probed and initialized (twl_priv->twl_id is valid) since the
    platform device for the RTC driver will be created by the twl-core after
    it finished its init.

    Reported-by: Christoph Fritz
    Signed-off-by: Peter Ujfalusi
    Tested-by: Kevin Hilman
    Tested-by: Grygorii Strashko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Peter Ujfalusi
     
  • The bios may clear the rtc control register when resuming the system. Since the
    cmos interrupt handler may now be run before the rtc_cmos is resumed, this can
    cause the interrupt handler to ignore an alarm since the alarm bit is not set in
    the rtc control register. To work around this, check if the rtc_cmos is
    suspended and use the stored value for the rtc control register.

    Signed-off-by: Derek Basehore
    Reviewed-by: Sameer Nanda
    Cc: Alessandro Zummo
    Cc: Jingoo Han
    Cc: Steven Rostedt
    Cc: John Stultz
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Derek Basehore
     
  • Currently, the RTC IRQ is never wakeup-enabled so is not capable of
    bringing the system out of suspend.

    On OMAP platforms, we have gotten by without this because the TWL RTC is
    on an I2C-connected chip which is capable of waking up the OMAP via the IO
    ring when the OMAP is in low-power states.

    However, if the OMAP suspends without hitting the low-power states (and
    the IO ring is not enabled), RTC wakeups will not work because the IRQ is
    not wakeup enabled.

    To fix, ensure the RTC IRQ is wakeup enabled whenever the RTC alarm is
    set.

    Signed-off-by: Kevin Hilman
    Cc: Alessandro Zummo
    Cc: Tony Lindgren
    Cc: Grygorii Strashko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kevin Hilman
     
  • Use of PTR_RET() simplifies the code.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • Use of PTR_RET() simplifies the code.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • Use of PTR_RET() simplifies the code.

    Signed-off-by: Sachin Kamat
    Cc: Thomas Bogendoerfer
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • Use of PTR_RET() simplifies the code.

    Signed-off-by: Sachin Kamat
    Cc: Roman Fietze
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • Use of PTR_RET() simplifies the code.

    Signed-off-by: Sachin Kamat
    Cc: David Dajun Chen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • Use the wrapper functions for getting and setting the driver data using
    platform_device instead of using dev_{get,set}_drvdata() with &pdev->dev,
    so we can directly pass a struct platform_device.

    Signed-off-by: Jingoo Han
    Cc: Grant Likely
    Cc: Rob Herring
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jingoo Han
     
  • This chip has a control register and can prevent altering saved clock.
    Without this patch we could have:

    (arm)root@pac14:~# date
    Tue May 21 03:08:27 MSK 2013
    (arm)root@pac14:~# /etc/init.d/hwclock.sh show
    Tue May 21 11:13:58 2013 -0.067322 seconds
    (arm)root@pac14:~# /etc/init.d/hwclock.sh stop
    [info] Saving the system clock.
    [info] Hardware Clock updated to Tue May 21 03:09:01 MSK 2013.
    (arm)root@pac14:~# /etc/init.d/hwclock.sh show
    Tue May 21 11:14:15 2013 -0.624272 seconds

    The patch enables write access to rtc before the driver tries to write
    time and re-disables when time data is written.

    Signed-off-by: Sergey Yanovich
    Acked-by: Marc Zyngier
    Cc: Alessandro Zummo
    Cc: Sachin Kamat
    Cc: Jingoo Han
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sergey Yanovich
     
  • Android expects the RTC to have second resolution. On ab8540 cut2 RTC
    block has a new register which allows setting seconds for wakeup alarms.

    Existing registers (minutes hi, mid and low) have seen their offsets
    changed. Here is the new mapping:
    * AlarmSec (A) 0x22
    * AlarmMinLow (M) from 0x8 to 0x23
    * AlarmMinMid (M) from 0x9 to 0x24
    * AlarmMinHigh (M) from 0xA to 0x25

    Signed-off-by: Julien Delacou
    Signed-off-by: Alexandre Torgue
    Acked-by: Lee Jones
    Acked-by: Linus Walleij
    Cc: Samuel Ortiz
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alexandre Torgue
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Acked-by: Mark Brown
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Laxman Dewangan
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Martyn Welch
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Acked-by: Atsushi Nemoto
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Torben Hohn
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Gregory Hermant
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Nobuhiro Iwamatsu
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Acked-by: Geoff Levand
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Acked-by: Thierry Reding
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat
     
  • After the switch to devm_* functions and the removal of
    rtc_device_unregister(), the 'remove' function does not do anything.
    Delete it.

    Signed-off-by: Sachin Kamat
    Cc: Chiwoong Byun
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Sachin Kamat