13 Aug, 2019

1 commit

  • We don't need dev_err() messages when platform_get_irq() fails now that
    platform_get_irq() prints an error message itself when something goes
    wrong. Let's remove these prints with a simple semantic patch.

    //
    @@
    expression ret;
    struct platform_device *E;
    @@

    ret =
    (
    platform_get_irq(E, ...)
    |
    platform_get_irq_byname(E, ...)
    );

    if ( \( ret < 0 \| ret

    While we're here, remove braces on if statements that only have one
    statement (manually).

    Cc: Alessandro Zummo
    Cc: Alexandre Belloni
    Cc: linux-rtc@vger.kernel.org
    Cc: Greg Kroah-Hartman
    Signed-off-by: Stephen Boyd
    Link: https://lore.kernel.org/r/20190730181557.90391-40-swboyd@chromium.org
    Signed-off-by: Alexandre Belloni

    Stephen Boyd
     

18 Mar, 2019

1 commit


04 Mar, 2019

2 commits


04 May, 2018

1 commit

  • We should get drvdata from struct device directly. Going via
    platform_device is an unneeded step back and forth.

    Signed-off-by: Wolfram Sang
    Acked-by: Michal Simek (for zynqmp)
    Signed-off-by: Alexandre Belloni

    Wolfram Sang
     

01 Mar, 2018

1 commit


20 May, 2016

3 commits

  • We program RTC time using SET_TIME_WRITE register and read the RTC
    current time using CURRENT_TIME register. When we set the time by
    writing into SET_TIME_WRITE Register and immediately try to read the
    rtc time from CURRENT_TIME register, the previous old value is
    returned instead of the new loaded time. This is because RTC takes
    nearly 1 sec to update the new loaded value into the CURRENT_TIME
    register. This behaviour is expected in our RTC IP.

    This patch updates the driver to read the current time from SET_TIME_WRITE
    register instead of CURRENT_TIME when rtc time is requested within an 1sec
    period after setting the RTC time. Doing so will ensure the correct time is
    given to the user.

    Since there is a delay of 1sec in updating the CURRENT_TIME we are loading
    set time +1sec while programming the SET_TIME_WRITE register, doing this
    will give correct time without any delay when read from CURRENT_TIME.

    Signed-off-by: Anurag Kumar Vulisha
    Signed-off-by: Alexandre Belloni

    Anurag Kumar Vulisha
     
  • It is suggested to program CALIB_WRITE register with the calibration
    value before updating the SET_TIME_WRITE register, doing so will
    clear the Tick Counter and force the next second to be signaled
    exactly in 1 second.

    Signed-off-by: Anurag Kumar Vulisha
    Signed-off-by: Alexandre Belloni

    Anurag Kumar Vulisha
     
  • In order to conserve battery energy, during the PS operation,
    it is expected that the supply for the battery-powered domain
    to be switched from the battery (VCC_PSBATT) to (VCC_PSAUX) and
    automatically be switched back to battery when VCC_PSAUX voltage
    drops below a limit, doing so prevents the logic within
    the battery-powered domain from functioning incorrectly.

    Signed-off-by: Anurag Kumar Vulisha
    Signed-off-by: Alexandre Belloni

    Anurag Kumar Vulisha
     

06 Sep, 2015

1 commit