lkml.org 
[lkml]   [2017]   [Oct]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Date
    Subject[PATCH 3.16 094/192] rtc: rtc-nuc900: fix loop timeout test
    3.16.49-rc1 review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Dan Carpenter <dan.carpenter@oracle.com>

    commit d0a67c372df410b579197ea818596001fe20070d upstream.

    We should change this post-op to a pre-op because we want the loop to
    exit with "timeout" set to zero.

    Fixes: 0a89b55364e0 ("nuc900/rtc: change the waiting for device ready implement")
    Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
    Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
    Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
    ---
    drivers/rtc/rtc-nuc900.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    --- a/drivers/rtc/rtc-nuc900.c
    +++ b/drivers/rtc/rtc-nuc900.c
    @@ -93,7 +93,7 @@ static int *check_rtc_access_enable(stru
    __raw_writel(AERPOWERON, nuc900_rtc->rtc_reg + REG_RTC_AER);

    while (!(__raw_readl(nuc900_rtc->rtc_reg + REG_RTC_AER) & AERRWENB)
    - && timeout--)
    + && --timeout)
    mdelay(1);

    if (!timeout)
    \
     
     \ /
      Last update: 2017-10-09 14:50    [W:4.892 / U:0.196 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site