RE: [rtc-linux] [PATCH] rtc: rtc-lpc32xx: Introduce RTC driver for the LPC32XX SoC (v3)

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Kevin Wells
Date: Friday, August 13, 2010 - 10:27 am

Hi Wolfram,

Thanks for continued testing and review of the driver.


No problem here..I'll change these.


I picked this specific approach because the type in the local rtc structure
is unsigned char (matching the struct rtc_wkalrm type) while the passed
parameter 'enabled' is unsigned long. I considered these..
	rtc->alarm_enabled = (unsigned char) enabled;
and
	rtc->alarm_enabled = !!enabled;

The direct assignment seemed the best approach to avoid some type of cast or
extra logic.


Hmm, this was a good find. If the key value isn't setup correctly, the
boot ROM will clear the RTC counter on power-on reset. The time isn't being
cleared on my board, so something is setting up the key elsewhere. Your
suggested fix is probably the right fix, but I'll review. Sorry - I won't
get updates for this available until next week.

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
RE: [rtc-linux] [PATCH] rtc: rtc-lpc32xx: Introduce RTC dr ..., Kevin Wells, (Fri Aug 13, 10:27 am)