linux-mips
[Top] [All Lists]

Re: [PATCH 10/14] lemote: rtc driver binary mode support

To: yanhua <yanh@lemote.com>
Subject: Re: [PATCH 10/14] lemote: rtc driver binary mode support
From: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Date: Thu, 09 Apr 2009 15:55:48 +0400
Cc: linux-mips@linux-mips.org, Ralf Baechle <ralf@linux-mips.org>, 彭亮锦 <penglj@lemote.com>, "zhangfx@lemote.com" <zhangfx@lemote.com>
In-reply-to: <49DD8238.7060609@lemote.com>
Organization: MontaVista Software Inc.
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <49DD8238.7060609@lemote.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mozilla/5.0 (X11; U; Linux i686; rv:1.7.2) Gecko/20040803
yanhua wrote:

> The original driver will exit when detect rtc binary mode. In fact both
> the binary mode and bcd are supported

[...]

> diff --git a/drivers/rtc/rtc-cmos.c b/drivers/rtc/rtc-cmos.c
> index b6d35f5..85c327e 100644
> --- a/drivers/rtc/rtc-cmos.c
> +++ b/drivers/rtc/rtc-cmos.c
> @@ -757,7 +757,7 @@ cmos_do_probe(struct device *dev, struct resource
> *ports, int rtc_irq)
> * <asm-generic/rtc.h> doesn't know 12-hour mode either.
> */
> if (is_valid_irq(rtc_irq) &&
> - (!(rtc_control & RTC_24H) || (rtc_control & (RTC_DM_BINARY)))) {
> + (!(rtc_control & RTC_24H) /*|| (rtc_control & (RTC_DM_BINARY))*/)) {
> dev_dbg(dev, "only 24-hr BCD mode supported\n");

   Perhaps the message should be changed too then...

> retval = -ENXIO;
> goto cleanup1;

WBR, Sergei

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