lkml.org 
[lkml]   [2019]   [Jan]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH v1 11/13] rtc: bd70528: Initial support for ROHM bd70528 RTC
On Tue, Jan 22, 2019 at 06:48:21AM -0800, Guenter Roeck wrote:
> On 1/22/19 1:47 AM, Matti Vaittinen wrote:
> > +
> > +static int bd70528_set_rtc_based_timers(struct bd70528 *bd70528, int new_state,
> > + int *old_state)
>
> Passed parameter is an int, not int *. I'd be quite surprised if this compiles
> without warning.
>
> > +static int bd70528_re_enable_rtc_based_timers(struct bd70528 *bd70528,
> > + int old_state)
// snip
> > + return bd70528_set_rtc_based_timers(bd70528, old_state, NULL);

and

> > +static int bd70528_disable_rtc_based_timers(struct bd70528 *bd70528,
> > + int *old_state)
// snip
> > + return bd70528_set_rtc_based_timers(bd70528, 0, old_state);

I'm not quite sure I understand what you mean by that. Second parameter is int,
third one is is int *.

> > +static int bd70528_re_enable_rtc_based_timers(struct bd70528 *bd70528,
> > + int old_state)
> > +{
> > + if (bd70528->rtc_timer_lock)
> > + mutex_unlock(bd70528->rtc_timer_lock);
> > +
> Unlock before calling bd70528_set_rtc_based_timers is odd, especially since it
> is called after locking below.
>

Yet another brainfart. Thanks for pointing this out! Will be fixed as
well.

Br,
Matti Vaittinen

--
Matti Vaittinen
ROHM Semiconductors

~~~ "I don't think so," said Rene Descartes. Just then, he vanished ~~~

\
 
 \ /
  Last update: 2019-01-22 17:30    [W:0.056 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site