[Top] [All Lists]

Re: [PATCH] remove mips_rtc_lock

To: Atsushi Nemoto <>
Subject: Re: [PATCH] remove mips_rtc_lock
From: Ralf Baechle <>
Date: Thu, 3 Nov 2005 11:05:53 +0000
In-reply-to: <>
Original-recipient: rfc822;
References: <>
User-agent: Mutt/
On Thu, Nov 03, 2005 at 01:02:40AM +0900, Atsushi Nemoto wrote:

> The mips_rtc_lock is no longer needed because RTC operations should be
> protected already by other mechanism. (rtc_lock, local_irq_save, etc.)
> Also, locking whole rtc_get_time/rtc_set_time should be avoided while
> some RTC routines might take very long time (a few seconds).
> Signed-off-by: Atsushi Nemoto <>

Applied.  Thanks alot for the janitor work.

And also the function names are clear as mud:

static inline unsigned int get_rtc_time(struct rtc_time *time)
        unsigned long nowtime;

        nowtime = rtc_get_time();
static inline int set_rtc_time(struct rtc_time *time)
        unsigned long nowtime;
        int ret;

        nowtime = mktime(time->tm_year+1900, time->tm_mon+1,
                        time->tm_mday, time->tm_hour, time->tm_min,
        ret = rtc_set_time(nowtime);

The difference between and get_rtc_time and rtc_get_time is less than
obvious.  Same for set_rtc_time and rtc_set_time ...


<Prev in Thread] Current Thread [Next in Thread>