lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 22 Jan 2019 18:29:31 +0200
From:   Matti Vaittinen <matti.vaittinen@...rohmeurope.com>
To:     Guenter Roeck <linux@...ck-us.net>
Cc:     mazziesaccount@...il.com, lee.jones@...aro.org, robh+dt@...nel.org,
        mark.rutland@....com, lgirdwood@...il.com, broonie@...nel.org,
        gregkh@...uxfoundation.org, rafael@...nel.org,
        mturquette@...libre.com, sboyd@...nel.org,
        linus.walleij@...aro.org, bgolaszewski@...libre.com,
        sre@...nel.org, a.zummo@...ertech.it,
        alexandre.belloni@...tlin.com, wim@...ux-watchdog.org,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-clk@...r.kernel.org, linux-gpio@...r.kernel.org,
        linux-pm@...r.kernel.org, linux-rtc@...r.kernel.org,
        linux-watchdog@...r.kernel.org, mikko.mutanen@...rohmeurope.com,
        heikki.haikola@...rohmeurope.com
Subject: Re: [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 ~~~

Powered by blists - more mailing lists